2011-03-10 Andrey Kosyakov <caseq@chromium.org>
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-03-10  Andrey Kosyakov  <caseq@chromium.org>
2
3         Web Inspector: better names for HAR export commands
4         https://bugs.webkit.org/show_bug.cgi?id=56097
5
6         Rename Export to HAR to Copy entry/network log as HAR
7         Expose Copy as HAR unconditionally, remove related settings entry.
8
9         * English.lproj/localizedStrings.js:
10         * inspector/front-end/NetworkPanel.js:
11         (WebInspector.NetworkPanel.prototype._contextMenu):
12         * inspector/front-end/Settings.js:
13
14 2011-03-10  Qi Zhang  <qi.2.zhang@nokia.com>
15
16         Reviewed by Laszlo Gombos.
17
18         [Qt] Mobile Devices should include Model and Firmware Version in Webkit Generated User Agent String
19         https://bugs.webkit.org/show_bug.cgi?id=48636
20
21         Fix a typo in features.pri that turns on this feature on mobile
22         devices by default.
23
24         * features.pri:
25
26 2011-03-10  Alexander Pavlov  <apavlov@chromium.org>
27
28         Reviewed by Pavel Feldman.
29
30         Web Inspector: Invalid expected parameter list in CSSAgent.setSelectorText() callback (CSSStyleModel.js)
31         https://bugs.webkit.org/show_bug.cgi?id=56092
32
33         * inspector/front-end/CSSStyleModel.js:
34         (WebInspector.CSSStyleModel.prototype.setRuleSelector):
35
36 2011-03-10  Pavel Feldman  <pfeldman@chromium.org>
37
38         Not reviewed: rolling out r80478 and its follow ups for breaking
39         inspector and engadget.com.
40         https://bugs.webkit.org/show_bug.cgi?id=49401
41
42         * dom/Document.cpp:
43         (WebCore::Document::Document):
44         (WebCore::performTask):
45         (WebCore::Document::postTask):
46         * dom/Document.h:
47         * loader/FrameLoader.cpp:
48         (WebCore::FrameLoader::setDefersLoading):
49         * manual-tests/database-callback-deferred.html: Removed.
50         * page/PageGroupLoadDeferrer.cpp:
51         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
52         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
53
54 2011-03-10  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
55
56         Reviewed by Kenneth Rohde Christiansen.
57
58         Tiled backing store's delegated scroll request uses incorrect convention
59         https://bugs.webkit.org/show_bug.cgi?id=56011
60
61         Use a point instead of delta, when relaying the scroll request from
62         ScrollView::setScrollPosition.
63
64         * loader/EmptyClients.h:
65         (WebCore::EmptyChromeClient::delegatedScrollRequested):
66         * page/Chrome.cpp:
67         (WebCore::Chrome::delegatedScrollRequested):
68         * page/Chrome.h:
69         * page/ChromeClient.h:
70         * platform/HostWindow.h:
71         * platform/ScrollView.cpp:
72         (WebCore::ScrollView::setScrollPosition):
73
74 2011-03-10  Pavel Feldman  <pfeldman@chromium.org>
75
76         Reviewed by Yury Semikhatsky.
77
78         Web Inspector: brush up DOM agent API.
79         https://bugs.webkit.org/show_bug.cgi?id=56093
80
81         * inspector/Inspector.idl:
82         * inspector/InspectorDOMAgent.cpp:
83         (WebCore::InspectorDOMAgent::childNodes):
84         (WebCore::InspectorDOMAgent::setNodeName):
85         (WebCore::InspectorDOMAgent::outerHTML):
86         (WebCore::InspectorDOMAgent::setNodeValue):
87         * inspector/InspectorDOMAgent.h:
88         * inspector/front-end/DOMAgent.js:
89         (WebInspector.DOMNode):
90         (WebInspector.DOMNode.prototype.hasAttributes):
91         (WebInspector.DOMNode.prototype.nodeType):
92         (WebInspector.DOMNode.prototype.nodeName):
93         (WebInspector.DOMNode.prototype.setNodeName):
94         (WebInspector.DOMNode.prototype.localName):
95         (WebInspector.DOMNode.prototype.nodeValue):
96         (WebInspector.DOMNode.prototype.setNodeValue):
97         (WebInspector.DOMNode.prototype.setAttribute):
98         (WebInspector.DOMNode.prototype.attributes):
99         (WebInspector.DOMNode.prototype.removeAttribute):
100         (WebInspector.DOMNode.prototype.childNodes.mycallback):
101         (WebInspector.DOMNode.prototype.childNodes):
102         (WebInspector.DOMNode.prototype.outerHTML):
103         (WebInspector.DOMNode.prototype.setOuterHTML):
104         (WebInspector.DOMNode.prototype.removeNode):
105         (WebInspector.DOMNode.prototype.copyNode):
106         (WebInspector.DOMNode.prototype.path):
107         (WebInspector.DOMNode.prototype._setAttributesPayload):
108         (WebInspector.DOMNode.prototype._addAttribute):
109         (WebInspector.DOMAgent.prototype._characterDataModified):
110         * inspector/front-end/ElementsPanel.js:
111         (WebInspector.ElementsPanel.prototype.updateBreadcrumb):
112         (WebInspector.ElementsPanel.prototype.decorateNodeLabel):
113         (WebInspector.ElementsPanel.prototype.handleCopyEvent):
114         * inspector/front-end/ElementsTreeOutline.js:
115         (WebInspector.ElementsTreeOutline.prototype.findTreeElement):
116         (WebInspector.ElementsTreeElement):
117         (WebInspector.ElementsTreeElement.prototype.updateChildren):
118         (WebInspector.ElementsTreeElement.prototype._updateChildren):
119         (WebInspector.ElementsTreeElement.prototype._startEditingTarget):
120         (WebInspector.ElementsTreeElement.prototype._startEditing):
121         (WebInspector.ElementsTreeElement.prototype._attributeEditingCommitted):
122         (WebInspector.ElementsTreeElement.prototype._tagNameEditingCommitted.moveToNextAttributeIfNeeded):
123         (WebInspector.ElementsTreeElement.prototype._tagNameEditingCommitted):
124         (WebInspector.ElementsTreeElement.prototype._textNodeEditingCommitted):
125         (WebInspector.ElementsTreeElement.prototype._attributeHTML):
126         ():
127         * inspector/front-end/EventListenersSidebarPane.js:
128         ():
129         * inspector/front-end/MetricsSidebarPane.js:
130         * inspector/front-end/StylesSidebarPane.js:
131         * inspector/front-end/utilities.js:
132
133 2011-03-09  Alexander Pavlov  <apavlov@chromium.org>
134
135         Reviewed by Pavel Feldman.
136
137         Web Inspector: [STYLES] Editing a property value adds a word for any property value that uses a paren
138         https://bugs.webkit.org/show_bug.cgi?id=56002
139
140         * inspector/front-end/StylesSidebarPane.js: Introduce an additional check.
141
142 2011-03-09  Pavel Podivilov  <podivilov@chromium.org>
143
144         Reviewed by Pavel Feldman.
145
146         Web Inspector: use DebuggerPresentation instead of DebuggerModel in source frame delegate.
147         https://bugs.webkit.org/show_bug.cgi?id=56034
148
149         * inspector/front-end/DebuggerPresentationModel.js:
150         (WebInspector.DebuggerPresentationModel.prototype.continueToLine):
151         (WebInspector.DebuggerPresentationModel.prototype.setBreakpoint):
152         (WebInspector.DebuggerPresentationModel.prototype.updateBreakpoint):
153         (WebInspector.DebuggerPresentationModel.prototype.findBreakpoint):
154         (WebInspector.DebuggerPresentationModel.prototype._sourceLocationToActualLocation):
155         * inspector/front-end/ScriptsPanel.js:
156         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
157         (WebInspector.SourceFrameDelegateForScriptsPanel):
158         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.setBreakpoint):
159         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.updateBreakpoint):
160         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.removeBreakpoint):
161         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.findBreakpoint):
162         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.continueToLine):
163         * inspector/front-end/SourceFrame.js:
164         (WebInspector.SourceFrame.prototype._contextMenu.else.editBreakpointCondition.didEditBreakpointCondition):
165         (WebInspector.SourceFrame.prototype._contextMenu.else.editBreakpointCondition):
166         (WebInspector.SourceFrame.prototype._contextMenu.else.setBreakpointEnabled):
167         (WebInspector.SourceFrame.prototype._contextMenu):
168         (WebInspector.SourceFrame.prototype._mouseDown):
169         (WebInspector.SourceFrameDelegate.prototype.removeBreakpoint):
170         (WebInspector.SourceFrameDelegate.prototype.updateBreakpoint):
171
172 2011-03-09  Alexander Pavlov  <apavlov@chromium.org>
173
174         Reviewed by Pavel Feldman.
175
176         Web Inspector: elements dom tree - word wrap toggle
177         https://bugs.webkit.org/show_bug.cgi?id=44311
178
179         A "Word Wrap" option is now shown in a context menu for the entire DOM tree content area
180         and persisted into application settings.
181
182         * English.lproj/localizedStrings.js:
183         * inspector/front-end/ElementsPanel.js:
184         (WebInspector.ElementsPanel.prototype._contextMenuEventFired):
185         (WebInspector.ElementsPanel.prototype._contextMenuEventFired.toggleWordWrap):
186         * inspector/front-end/ElementsTreeOutline.js:
187         (WebInspector.ElementsTreeOutline):
188         (WebInspector.ElementsTreeOutline.prototype._treeElementFromEvent):
189         (WebInspector.ElementsTreeOutline.prototype.populateContextMenu):
190         (WebInspector.ElementsTreeElement.prototype.onreveal):
191         * inspector/front-end/Settings.js:
192         (WebInspector.Settings):
193         * inspector/front-end/inspector.css:
194         (#elements-content.nowrap):
195         (#elements-content > ol):
196
197 2011-03-09  Pavel Podivilov  <podivilov@chromium.org>
198
199         Reviewed by Pavel Feldman.
200
201         Web Inspector: re-implement breakpoints sidebar pane based on debugger presentation model.
202         https://bugs.webkit.org/show_bug.cgi?id=55823
203
204         * inspector/front-end/BreakpointsSidebarPane.js:
205         (WebInspector.JavaScriptBreakpointsSidebarPane):
206         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.addBreakpoint.didLoadSnippet):
207         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.addBreakpoint):
208         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.removeBreakpoint):
209         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.highlightBreakpoint):
210         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.clearBreakpointHighlight):
211         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._createBreakpointItemId):
212         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointClicked):
213         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._breakpointCheckboxClicked):
214         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype._contextMenu):
215         (WebInspector.JavaScriptBreakpointsSidebarPane.prototype.reset):
216         * inspector/front-end/DebuggerPresentationModel.js:
217         (WebInspector.DebuggerPresentationModel):
218         (WebInspector.DebuggerPresentationModel.prototype._parsedScriptSource):
219         (WebInspector.DebuggerPresentationModel.prototype._failedToParseScriptSource):
220         (WebInspector.DebuggerPresentationModel.prototype._revealHiddenBreakpoints):
221         (WebInspector.DebuggerPresentationModel.prototype.breakpointsForSourceFileId):
222         (WebInspector.DebuggerPresentationModel.prototype.setBreakpointEnabled):
223         (WebInspector.DebuggerPresentationModel.prototype.removeBreakpoint):
224         (WebInspector.DebuggerPresentationModel.prototype._breakpointAdded):
225         (WebInspector.DebuggerPresentationModel.prototype.set selectedCallFrame):
226         (WebInspector.DebuggerPresentationModel.prototype._actualLocationToSourceLocation):
227         (WebInspector.DebuggerPresentationModel.prototype.reset):
228         * inspector/front-end/ScriptsPanel.js:
229         (WebInspector.ScriptsPanel):
230         (WebInspector.ScriptsPanel.prototype._breakpointAdded):
231         (WebInspector.ScriptsPanel.prototype._breakpointRemoved):
232         (WebInspector.ScriptsPanel.prototype._debuggerPaused):
233         (WebInspector.ScriptsPanel.prototype.reset):
234         (WebInspector.ScriptsPanel.prototype._clearInterface):
235
236 2011-03-10  Andrey Adaikin  <aandrey@google.com>
237
238         Reviewed by Pavel Feldman.
239
240         Web Inspector: Highlighter refactoring
241         https://bugs.webkit.org/show_bug.cgi?id=56015
242
243         * inspector/front-end/TextEditorHighlighter.js:
244         (WebInspector.TextEditorHighlighter):
245         (WebInspector.TextEditorHighlighter.prototype.set mimeType):
246         (WebInspector.TextEditorHighlighter.prototype.highlight):
247         (WebInspector.TextEditorHighlighter.prototype.updateHighlight):
248         (WebInspector.TextEditorHighlighter.prototype._highlightInChunks):
249         (WebInspector.TextEditorHighlighter.prototype._highlightLines):
250         (WebInspector.TextEditorHighlighter.prototype._selectHighlightState):
251         (WebInspector.TextEditorHighlighter.prototype._clearHighlightState):
252         * inspector/front-end/TextViewer.js:
253         (WebInspector.TextEditorMainPanel.prototype._buildChunks):
254         (WebInspector.TextEditorMainPanel.prototype._updateHighlightsForRange):
255
256 2011-03-05  Pavel Podivilov  <podivilov@chromium.org>
257
258         Reviewed by Pavel Feldman.
259
260         Web Inspector: move breakpoint column adjustment to debugger model.
261         https://bugs.webkit.org/show_bug.cgi?id=55821
262
263         Test: inspector/debugger/debug-inlined-scripts.html
264
265         * inspector/front-end/DebuggerModel.js:
266         (WebInspector.DebuggerModel.prototype.setBreakpoint.didSetBreakpoint):
267         (WebInspector.DebuggerModel.prototype.setBreakpoint):
268         * inspector/front-end/SourceFrameContent.js:
269         (WebInspector.SourceFrameContent.prototype.sourceFrameLineNumberToActualLocation):
270
271 2011-01-21  John Knottenbelt  <jknotten@chromium.org>
272
273         Reviewed by Dmitry Titov.
274
275         Detach Geolocation from Frame when Page destroyed.
276         https://bugs.webkit.org/show_bug.cgi?id=52877
277
278         On Page destruction, any outstanding Geolocation permission
279         requests should be cancelled, because the Geolocation can only
280         access the client indirectly via m_frame->page().
281
282         Page destruction is signalled by a call to the
283         Frame::pageDestroyed() method. This explictly calls
284         DOMWindow::resetGeolocation which ultimately calls Geolocation::reset.
285
286         Geolocation::reset() detaches from the GeolocationController,
287         cancels requests, watches and single shots, and sets the
288         permission state back to Unknown.
289
290         Frame::pageDestroyed() is also called by FrameLoader even though
291         the page is not destroyed. We should still cancel permission
292         requests, because the GeolocationClient will become inaccessible
293         to the Geolocation object after this call.
294
295         Frame::transferChildFrameToNewDocument also indirectly calls
296         Geolocation::reset when the frame is reparented between
297         pages. Ideally we would like the Geolocation's activities to
298         continue after reparenting, see bug
299         https://bugs.webkit.org/show_bug.cgi?id=55577
300
301         Since GeolocationController is owned by Page, and all Geolocation
302         objects will now unsubscribe from the GeolocationController on
303         pageDetached(), we no longer need to call stopUpdating() from the
304         GeolocationController's destructor. Instead we can simply assert
305         that there should be no no observers. See related bug
306         https://bugs.webkit.org/show_bug.cgi?id=52216 .
307
308         Introduced new method 'numberOfPendingPermissionRequests' on
309         GeolocationClientMock to count the number of outstanding pending
310         permission requests. This provides a reusable implementation for
311         client-based implementations of the LayoutTestController's
312         numberOfPendingGeolocationPermissionRequests method.
313
314         Test: fast/dom/Geolocation/page-reload-cancel-permission-requests.html
315
316         * page/DOMWindow.cpp:
317         (WebCore::DOMWindow::resetGeolocation):
318         * page/DOMWindow.h:
319         * page/Frame.cpp:
320         (WebCore::Frame::pageDestroyed):
321         (WebCore::Frame::transferChildFrameToNewDocument):
322         * page/Geolocation.cpp:
323         (WebCore::Geolocation::~Geolocation):
324         (WebCore::Geolocation::page):
325         (WebCore::Geolocation::reset):
326         (WebCore::Geolocation::disconnectFrame):
327         (WebCore::Geolocation::lastPosition):
328         (WebCore::Geolocation::requestPermission):
329         (WebCore::Geolocation::startUpdating):
330         (WebCore::Geolocation::stopUpdating):
331         * page/Geolocation.h:
332         * page/GeolocationController.cpp:
333         (WebCore::GeolocationController::~GeolocationController):
334         * page/Navigator.cpp:
335         (WebCore::Navigator::resetGeolocation):
336         * page/Navigator.h:
337         * platform/mock/GeolocationClientMock.cpp:
338         (WebCore::GeolocationClientMock::numberOfPendingPermissionRequests):
339         * platform/mock/GeolocationClientMock.h:
340
341 2011-03-10  Ojan Vafai  <ojan@chromium.org>
342
343         Reviewed by Darin Adler.
344
345         Able to move nodes across documents
346         https://bugs.webkit.org/show_bug.cgi?id=19524
347
348         Makes cross-document appendChild, insertBefore, Range.insertNode and Range.surroundContents work.
349         This matches Gecko and the new Dom Core spec. There are a number of Range methods where we don't 
350         match Gecko or the spec that will need to be updated in a following patch.
351
352         Test: fast/dom/move-nodes-across-documents.html
353
354         * dom/Element.cpp:
355         (WebCore::Element::removeAttributeNode):
356         * dom/NamedNodeMap.cpp:
357         (WebCore::NamedNodeMap::setNamedItem):
358         * dom/Node.cpp:
359         (WebCore::Node::setDocumentRecursively):
360         (WebCore::checkAcceptChild):
361         (WebCore::Node::checkReplaceChild):
362         * dom/Range.cpp:
363         (WebCore::Range::insertNode):
364         (WebCore::Range::surroundContents):
365
366 2011-03-09  Antti Koivisto  <antti@apple.com>
367
368         Not reviewed.
369
370         Reverting crash catching code, the bug being hunted was fixed by
371         http://trac.webkit.org/changeset/80686
372
373         * loader/cache/CachedResourceLoader.cpp:
374         (WebCore::CachedResourceLoader::CachedResourceLoader):
375         (WebCore::CachedResourceLoader::~CachedResourceLoader):
376         (WebCore::CachedResourceLoader::requestImage):
377         (WebCore::CachedResourceLoader::requestUserCSSStyleSheet):
378         (WebCore::CachedResourceLoader::requestResource):
379         (WebCore::CachedResourceLoader::setAutoLoadImages):
380         (WebCore::CachedResourceLoader::load):
381         (WebCore::CachedResourceLoader::loadDone):
382         (WebCore::CachedResourceLoader::preload):
383         (WebCore::CachedResourceLoader::requestPreload):
384         * loader/cache/CachedResourceLoader.h:
385
386 2011-03-09  Peter Kasting  <pkasting@google.com>
387
388         Unreviewed, build fix.
389
390         * StringsNotToBeLocalized.txt: Add function names I forgot.
391         * platform/win/SystemInfo.cpp: #if out some uncalled functions on WinCE,
392           since they don't compile anyway.  Use ZeroMemory() instead of "= {0}"
393           since Qt is stupid and (sometimes?!) warns about it.
394         (WebCore::windowsVersion):
395         (WebCore::processorArchitecture):
396
397 2011-03-09  Peter Kasting  <pkasting@google.com>
398
399         Reviewed by Ryosuke Niwa.
400
401         Add UA string tags for Windows 64.
402         https://bugs.webkit.org/show_bug.cgi?id=55226
403
404         * StringsNotToBeLocalized.txt:
405         * platform/win/SystemInfo.cpp:
406         (WebCore::osVersionForUAString):
407         (WebCore::isWOW64):
408         (WebCore::processorArchitecture):
409         (WebCore::architectureTokenForUAString):
410         (WebCore::windowsVersionForUAString):
411
412 2011-03-09  Peter Kasting  <pkasting@google.com>
413
414         Unreviewed, attempted build fix.
415
416         * WebCore.pri: Try to update include path for Qt Windows build.
417
418 2011-03-09  Peter Kasting  <pkasting@google.com>
419
420         Unreviewed, build fix.
421
422         * platform/win/SystemInfo.cpp:
423         (WebCore::windowsVersionForUAString): Fix const conversion warning on Qt.
424
425 2011-03-09  Peter Kasting  <pkasting@google.com>
426
427         Reviewed by Mihai Parparita.
428
429         Unify Windows version checks.
430         https://bugs.webkit.org/show_bug.cgi?id=55979
431
432         * GNUmakefile.am: Fix spaces -> tabs.
433         * StringsNotToBeLocalized.txt:
434         * WebCore.pro: Add SystemInfo.* to Qt build.
435         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
436         (WebCore::ScrollbarThemeChromiumWin::invalidateOnMouseEnterExit):
437         (WebCore::ScrollbarThemeChromiumWin::getThemeState):
438         (WebCore::ScrollbarThemeChromiumWin::getThemeArrowState):
439         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
440         (WebCore::fillBMPGlyphs):
441         * platform/win/CursorWin.cpp:
442         (WebCore::createSharedCursor):
443         * platform/win/ScrollbarThemeWin.cpp:
444         (WebCore::ScrollbarThemeWin::ScrollbarThemeWin):
445         * platform/win/SystemInfo.cpp: Add full-fledged version check and UA string helper function.
446         (WebCore::windowsVersion):
447         (WebCore::windowsVersionForUAString):
448         * platform/win/SystemInfo.h: Add full-fledged version check and UA string helper function.
449         * rendering/RenderThemeChromiumWin.cpp:
450         (WebCore::getNonClientMetrics):
451         * rendering/RenderThemeWin.cpp:
452         (WebCore::RenderThemeWin::getThemeData):
453         (WebCore::RenderThemeWin::paintMenuList):
454         (WebCore::RenderThemeWin::paintMenuListButton):
455
456 2011-03-09  Mihai Parparita  <mihaip@chromium.org>
457
458         Reviewed by Tony Gentilcore.
459
460         REGRESSION (r74807): memory corruption after CachedResourceLoader refactoring
461         https://bugs.webkit.org/show_bug.cgi?id=53045
462         
463         Copy the URL out of the CachedResource that is being revalidated, so
464         that we can still use it (in m_validatedURLs) after removing the
465         resource from the memory cache, which may delete it.
466
467         No new tests, since I was not able to trigger this locally (in a layout
468         test or otherwise).
469
470         * loader/cache/CachedResourceLoader.cpp:
471         (WebCore::CachedResourceLoader::revalidateResource):
472
473 2011-03-09  Chris Fleizach  <cfleizach@apple.com>
474
475         Reviewed by Beth Dakin.
476
477         VO reporting incorrect list count for http://www.macworld.com/news.html
478         https://bugs.webkit.org/show_bug.cgi?id=56064
479
480         <li> tags should not be ignored, because they provide valuable information
481         to screen readers.
482
483         Test: platform/mac/accessibility/list-items-ignored.html
484
485         * accessibility/AccessibilityRenderObject.cpp:
486         (WebCore::AccessibilityRenderObject::accessibilityIsIgnored):
487
488 2011-03-09  Dan Bernstein  <mitz@apple.com>
489
490         Reviewed by Dave Hyatt.
491
492         <rdar://problem/8733254> Float disappears after incremental layout
493         Fixed the original bug and a copule more issues noticed while doing so.
494
495         Tests: fast/dynamic/dirty-float-in-clean-line.html
496                fast/dynamic/float-at-line-break.html
497                fast/dynamic/float-from-empty-line.html
498
499         * rendering/RenderBlock.h:
500         * rendering/RenderBlockLineLayout.cpp:
501         (WebCore::RenderBlock::layoutInlineChildren): If findNextLineBreak() returned an empty line,
502         update the line break info of the last line with the new line break position. This is tested
503         by float-from-empty-line.html.
504         (WebCore::RenderBlock::checkFloatsInCleanLine): Factored out code from determineStartPosition()
505         into this new function.
506         (WebCore::RenderBlock::determineStartPosition): Call checkFloatsInCleanLine().
507         (WebCore::RenderBlock::determineEndPosition): When iterating over lines, check clean lines with
508         floats, as they may yet become dirty because of the floats. This is tested by
509         dirty-float-in-clean-line.html.
510         (WebCore::RenderBlock::findNextLineBreak): If a float fits on the line, and the current line
511         break is at the float, advance it to after the float. Otherwise, if the line gets dirty and the
512         next one does not, the float will not make it into any line. This is tested by
513         float-at-line-break.html.
514
515 2011-03-09  Ryosuke Niwa  <rniwa@webkit.org>
516
517         Reviewed by Kent Tamura.
518
519         selectionStart reports wrong caret position when the last characters are newlines
520         https://bugs.webkit.org/show_bug.cgi?id=56061
521
522         The bug was caused by SelectionController::setSelection's not calling
523         notifyRendererOfSelectionChange when old selection was equal to new selection.
524
525         Because InsertLineBreakCommand inserts a text node with a single LF before the caret,
526         this condition holds after the command is executed. However, the values of
527         selectionStart and selectionEnd still need to be updated in this case because
528         the offsets counted from the beginning of textarea have been increased by 1.
529
530         * editing/SelectionController.cpp:
531         (WebCore::SelectionController::setSelection): Call notifyRendererOfSelectionChange
532         when m_selection = s.
533         * manual-tests/selection-start-after-inserting-line-break-in-textarea.html: Added.
534
535 2011-03-09  Andy Estes  <aestes@apple.com>
536
537         Reviewed by Adam Barth.
538
539         Bad cast in HTMLTreeBuilder::processStartTag
540         https://bugs.webkit.org/show_bug.cgi?id=55955
541
542         Test: fast/parser/self-closing-foreign-content.html
543
544         When the parser encounters an svg or mathml root element, it places the
545         insertion mode into InForeignContentMode. However, if the root element
546         is self-closing (e.g. <svg />) then the element is never placed on the
547         open elements stack. This leaves the parser in an inconsistent state
548         where it is in InForeignContentMode but no foreign content is in the
549         open element stack.
550
551         * html/parser/HTMLTreeBuilder.cpp:
552         (WebCore::HTMLTreeBuilder::processStartTagForInBody): If a self-closing
553         foreign element is inserted into the tree, do not set the insertion
554         mode to InForeignContentMode.
555
556 2011-03-09  Gavin Barraclough  <barraclough@apple.com>
557
558         Qt build fix.
559
560         * bridge/qt/qt_runtime.cpp:
561         (JSC::Bindings::convertQVariantToValue):
562
563 2011-03-09  Andy Estes  <aestes@apple.com>
564
565         Reviewed by Adam Barth.
566
567         REGRESSION (r80320): Assertion failure when processing mis-nested foreign content.
568         https://bugs.webkit.org/show_bug.cgi?id=55982
569
570         Test: fast/parser/fragment-foreign-content-misnested.html
571         
572         It is a parse error to encounter certain start tags while the parser's
573         insertion mode is InForeignContentMode (e.g. <br>). In these cases, we
574         are to pop open elements off the HTMLElementStack until a foreign
575         content scope marker is encountered. Before the change in r80320 to not
576         insert a fake HTML element during fragment parsing, said fake HTML
577         element counted as a foreign content scope marker.
578         
579         With r80320, no fake HTML element is inserted and the stack is popped
580         until empty in cases where no other element claims to be a foreign
581         content scope marker. Fix this by treating the DocumentFragment as a
582         foreign content scope marker.
583
584         * html/parser/HTMLElementStack.cpp:
585         (WebCore::HTMLNames::isForeignContentScopeMarker): Take a
586         ContainerNode* instead of a Element*.
587         (WebCore::HTMLElementStack::popUntilForeignContentScopeMarker): Pass
588         topNode() to isForeignContentScopeMarker() instead of top().
589
590 2011-03-09  Gavin Barraclough  <barraclough@apple.com>
591
592         Reviewed by Darin Adler.
593
594         Bug 56041 - RexExp constructor should only accept flags "gim"
595         We also should be passing the flags around as a bitfield rather than a string,
596         and should not have redundant, incompatible code for converting the string to a bitfield!
597
598         * bindings/js/SerializedScriptValue.cpp:
599         (WebCore::CloneDeserializer::readTerminal):
600             - Need to parse flags string back to enum.
601
602 2011-03-09  James Robinson  <jamesr@chromium.org>
603
604         Reviewed by Kenneth Russell.
605
606         [chromium]: Regression - Explicitly copy compositing properties from LayerChromium to CCLayerImpl
607         https://bugs.webkit.org/show_bug.cgi?id=56021
608
609         Initializes the m_doubleSided flag of LayerChromiums to the default
610         value of true so the back sides of layers without
611         backface-visibility:hidden are rendered.
612
613         Test: compositing/backface-visibility.html
614
615         * platform/graphics/chromium/LayerChromium.cpp:
616         (WebCore::LayerChromium::LayerChromium):
617
618 2011-03-09  David Hyatt  <hyatt@apple.com>
619
620         Reviewed by Dan Bernstein.
621
622         <rdar://problem/9110316> REGRESSION: 'ex' unit broken for vertical text
623
624         Fall back to the verticalRightOrientation data when obtaining the x-height for vertically oriented
625         text. That way we use the same metrics as for horizontal.
626
627         This fixes regressions in fast/lists and fast/overflow vertical text tests.
628
629         * platform/graphics/mac/SimpleFontDataMac.mm:
630         (WebCore::SimpleFontData::platformInit):
631         (WebCore::SimpleFontData::platformBoundsForGlyph):
632
633 2011-03-09  Ryosuke Niwa  <rniwa@webkit.org>
634
635         Reviewed by Tony Chang.
636
637         REGRESSION: crash in nextLinePosition when extending selection forward by line in an empty document
638         https://bugs.webkit.org/show_bug.cgi?id=56004
639
640         The crash was caused by the false assumption that rootEditableElement() or documentElement()
641         always return non-null pointer. Fixed the bug by adding an early exit.
642
643         Test: editing/selection/extend-by-line-in-empty-document.html
644
645         * editing/visible_units.cpp:
646         (WebCore::previousLinePosition):
647         (WebCore::nextLinePosition):
648
649 2011-03-09  Pavel Podivilov  <podivilov@chromium.org>
650
651         Reviewed by Pavel Feldman.
652
653         Web Inspector: it should be possible to copy stack trace from call stack sidebar pane.
654         https://bugs.webkit.org/show_bug.cgi?id=56024
655
656         * English.lproj/localizedStrings.js:
657         * inspector/front-end/CallStackSidebarPane.js:
658         (WebInspector.CallStackSidebarPane):
659         (WebInspector.CallStackSidebarPane.prototype.update):
660         (WebInspector.CallStackSidebarPane.prototype._contextMenu):
661
662 2011-03-09  David Hyatt  <hyatt@apple.com>
663
664         Reviewed by Darin Adler.
665
666         Patch FontPlatformDataLinux to properly initialize and copy orientation/text-orientation in all
667         places.  Make sure text-orientation is specified in the lookups/creation in FontCustomPlatformData
668         and FontCache.
669
670         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
671         (WebCore::FontPlatformData::FontPlatformData):
672         * platform/graphics/chromium/FontPlatformDataLinux.h:
673         (WebCore::FontPlatformData::FontPlatformData):
674
675 2011-03-09  Steve Block  <steveblock@google.com>
676
677         Reviewed by Jeremy Orlow.
678
679         JavaNPObject should not use JNI directly
680         https://bugs.webkit.org/show_bug.cgi?id=56009
681
682         We move the JNI code to access a Java object's fields into
683         a new JavaInstance::getField() method.
684
685         No new tests, refactoring only.
686
687         * bridge/jni/v8/JavaInstanceV8.cpp:
688         (JavaInstance::getField):
689         * bridge/jni/v8/JavaInstanceV8.h:
690         * bridge/jni/v8/JavaNPObjectV8.cpp:
691         (JSC::Bindings::JavaNPObjectGetProperty):
692
693 2011-03-09  Steve Block  <steveblock@google.com>
694
695         Reviewed by Jeremy Orlow.
696
697         NPAPI - jvalue conversion should not be in JavaInstance
698         https://bugs.webkit.org/show_bug.cgi?id=55967
699
700         No new tests, refactoring only.
701
702         * bridge/jni/v8/JavaInstanceV8.cpp:
703         (JavaInstance::invokeMethod):
704         * bridge/jni/v8/JavaInstanceV8.h:
705         * bridge/jni/v8/JavaNPObjectV8.cpp:
706         (JSC::Bindings::JavaNPObjectInvoke):
707
708 2011-03-09  Jessie Berlin  <jberlin@apple.com>
709
710         Reviewed by Adam Roben.
711
712         Use the Cookie Storage from the Private Browsing Storage Session directly
713         https://bugs.webkit.org/show_bug.cgi?id=55986
714
715         * WebCore.exp.in:
716         * platform/mac/WebCoreSystemInterface.h:
717         * platform/mac/WebCoreSystemInterface.mm:
718
719         * platform/network/mac/CookieStorageMac.mm:
720         (WebCore::setCookieStoragePrivateBrowsingEnabled):
721         Just copy the cookie storage from the private browsing storage session.
722         * platform/network/cf/CookieStorageCFNet.cpp:
723         (WebCore::setCookieStoragePrivateBrowsingEnabled):
724         Ditto.
725
726 2011-03-09  Andrey Kosyakov  <caseq@chromium.org>
727
728         Unreviewed. Fixed a crash in InspectorInstrumentation::didReceiveResponse() when loader is null (broken in r80639)
729
730         * inspector/InspectorInstrumentation.cpp:
731         (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
732
733 2011-03-09  Yury Semikhatsky  <yurys@chromium.org>
734
735         Reviewed by Pavel Feldman.
736
737         Web Inspector: pass explicit agent references to InspectorBackendDispatcher
738         https://bugs.webkit.org/show_bug.cgi?id=55820
739
740         * inspector/CodeGeneratorInspector.pm:
741         * inspector/InspectorController.cpp:
742         (WebCore::InspectorController::InspectorController):
743         (WebCore::InspectorController::connectFrontend):
744         (WebCore::InspectorController::disconnectFrontend):
745         (WebCore::InspectorController::dispatchMessageFromFrontend):
746
747 2011-03-09  Andrey Kosyakov  <caseq@chromium.org>
748
749         Reviewed by Pavel Feldman.
750
751         Web Inspector: resource errors are not reported before front-end is opened
752         https://bugs.webkit.org/show_bug.cgi?id=55939
753
754         * inspector/InspectorInstrumentation.cpp:
755         (WebCore::InspectorInstrumentation::didReceiveResourceResponseImpl):
756         * inspector/InspectorInstrumentation.h:
757         (WebCore::InspectorInstrumentation::didReceiveResourceResponse):
758         (WebCore::InspectorInstrumentation::didFailLoading):
759
760 2011-03-08  Hans Wennborg  <hans@chromium.org>
761
762         Reviewed by Jeremy Orlow.
763
764         IndexedDB: Add BackingStoreType parameter to IDBFactoryBackendInterface::open
765         https://bugs.webkit.org/show_bug.cgi?id=55948
766
767         Add a parameter that allows for selection of alternative backing store
768         implementations.
769
770         No new tests: no new functionality.
771
772         * storage/IDBFactory.cpp:
773         (WebCore::IDBFactory::open):
774         * storage/IDBFactoryBackendImpl.cpp:
775         (WebCore::IDBFactoryBackendImpl::open):
776         * storage/IDBFactoryBackendImpl.h:
777         * storage/IDBFactoryBackendInterface.h:
778
779 2011-03-08  Steve Block  <steveblock@google.com>
780
781         Reviewed by Jeremy Orlow.
782
783         Factor out JNI method call to be used by both JSC and V8
784         https://bugs.webkit.org/show_bug.cgi?id=55966
785
786         No new tests, refactoring only.
787
788         * bridge/jni/JNIUtility.cpp:
789         (JSC::Bindings::callJNIMethod):
790         * bridge/jni/JNIUtility.h:
791         * bridge/jni/jsc/JavaInstanceJSC.cpp:
792         (JavaInstance::invokeMethod):
793         * bridge/jni/v8/JavaInstanceV8.cpp:
794         (JavaInstance::invokeMethod):
795
796 2011-03-09  Andrey Adaikin  <aandrey@google.com>
797
798         Reviewed by Pavel Feldman.
799
800         Web Inspector: [Text editor] Regression in handling DOMNodeInserted/DOMNodeRemoved events
801         https://bugs.webkit.org/show_bug.cgi?id=55818
802
803         * inspector/front-end/TextViewer.js:
804         (WebInspector.TextEditorMainPanel.prototype._handleDOMUpdates):
805
806 2011-03-09  Ilya Tikhonovsky  <loislo@chromium.org>
807
808         Reviewed by Yury Semikhatsky.
809
810         Web Inspector: Web Inspector: we don't need to transfer objectId and hasChildren for primitive values.
811         https://bugs.webkit.org/show_bug.cgi?id=55998
812
813         * inspector/InjectedScriptSource.js:
814
815 2011-03-09  Pavel Feldman  <pfeldman@chromium.org>
816
817         Reviewed by Yury Semikhatsky.
818
819         Web Inspector: watch expressions should show string values in quotes.
820         https://bugs.webkit.org/show_bug.cgi?id=55846
821
822         * inspector/InjectedScriptSource.js:
823         * inspector/front-end/ObjectPropertiesSection.js:
824         (WebInspector.ObjectPropertyTreeElement.prototype.update):
825         * inspector/front-end/RemoteObject.js:
826         (WebInspector.LocalJSONObject.prototype.get description):
827         * inspector/front-end/WatchExpressionsSidebarPane.js:
828         (WebInspector.WatchExpressionsSection.prototype.update):
829         * inspector/front-end/inspector.css:
830         (.console-formatted-string, .console-formatted-regexp):
831
832 2011-03-09  Pavel Feldman  <pfeldman@chromium.org>
833
834         Reviewed by Yury Semikhatsky.
835
836         Web Inspector: "length" getter is invoked upon console object formatting.
837         https://bugs.webkit.org/show_bug.cgi?id=55220
838
839         * inspector/InjectedScriptSource.js:
840
841 2011-03-08  Ilya Tikhonovsky  <loislo@chromium.org>
842
843         Reviewed by Pavel Feldman.
844
845         Web Inspector: remove groupName from objectId.
846         https://bugs.webkit.org/show_bug.cgi?id=55825
847
848         * inspector/InjectedScriptSource.js:
849
850 2011-03-08  Xiaomei Ji  <xji@chromium.org>
851
852         Reviewed by David Hyatt.
853
854         Fix Regression: Content not drawn when scrolling horizontally in an RTL page.
855         https://bugs.webkit.org/show_bug.cgi?id=55077.
856
857         Inside ScrollView::calculateOverhangAreasForPainting(), when scroll position
858         is negative, should include the position value into overhang rectangle's 
859         starting position. 
860
861         Tests: fast/dom/scroll-reveal-left-overflow.html
862                fast/dom/scroll-reveal-top-overflow.html
863
864         * platform/ScrollView.cpp:
865         (WebCore::ScrollView::calculateOverhangAreasForPainting):
866
867 2011-03-08  Daniel Bates  <dbates@rim.com>
868
869         Reviewed by Darin Adler.
870
871         Add templatized CSSMutableStyleDeclaration::get{ShorthandValue, CommonValue, LayeredShorthandValue}()
872         https://bugs.webkit.org/show_bug.cgi?id=55351
873
874         By using some template magic CSSMutableStyleDeclaration::get{ShorthandValue, CommonValue, LayeredShorthandValue}()
875         can be called on an array A without the caller explicitly specifying the size of A.
876
877         No functionality was changed. So no new tests.
878
879         * css/CSSMutableStyleDeclaration.cpp:
880         (WebCore::CSSMutableStyleDeclaration::getPropertyValue): Modified to call templatized variants of
881         CSSMutableStyleDeclaration::get{ShorthandValue, CommonValue, LayeredShorthandValue}().
882         (WebCore::CSSMutableStyleDeclaration::getLayeredShorthandValue): Renamed second argument from "number" to "size"
883         to better reflect its purpose - to be the size of the passed array.
884         (WebCore::CSSMutableStyleDeclaration::getShorthandValue): Ditto.
885         (WebCore::CSSMutableStyleDeclaration::getCommonValue): Ditto.
886         (WebCore::CSSMutableStyleDeclaration::cssText): Modified to call templatized variant of CSSMutableStyleDeclaration::getShorthandValue().
887         * css/CSSMutableStyleDeclaration.h:
888         (WebCore::CSSMutableStyleDeclaration::getShorthandValue): Added templatized function that can determine
889         the size of a passed array. Changed type of second argument to size_t since it represents the size of
890         an array.
891         (WebCore::CSSMutableStyleDeclaration::getCommonValue): Ditto.
892         (WebCore::CSSMutableStyleDeclaration::getLayeredShorthandValue): Ditto.
893
894 2011-03-08  Enrica Casucci  <enrica@apple.com>
895
896         Reviewed by Darin Adler.
897         
898         REGRESSION: Copied content loses formatting on paste to external apps.
899         https://bugs.webkit.org/show_bug.cgi?id=47615
900         <rdar://problem/9001214>
901         
902         This is a resubmission of a patch that was landed a while ago then rolled
903         back because of a build failure on SnowLeopard and Leopard on the 32-bit builds.
904
905         This patch adds a way for WebKit2 to create NSAttributedStrings from
906         a DOM range without using the AppKit api initWithDOMRange that internally
907         needs to access the WebView. The NSAttributedString is needed to create
908         RTF formats in the pasteboard.
909         This is to be considered a first step, since in the future we want to have
910         an implementation based on the TextIterator.
911         * WebCore.xcodeproj/project.pbxproj:
912         * platform/mac/HTMLConverter.h: Added.
913         * platform/mac/HTMLConverter.mm: Added.
914         * platform/mac/PasteboardMac.mm:
915         (WebCore::Pasteboard::writeSelection):
916
917 2011-03-08  James Robinson  <jamesr@chromium.org>
918
919         Reviewed by Kenneth Russell.
920
921         [chromium] Explicitly copy compositing properties from LayerChromium to CCLayerImpl
922         https://bugs.webkit.org/show_bug.cgi?id=55900
923
924         This adds an explicit step to synchronize properties from
925         LayerChromiums to their corresponding CCLayerImpls.
926
927         * platform/graphics/chromium/LayerChromium.cpp:
928         (WebCore::LayerChromium::setBounds):
929         * platform/graphics/chromium/LayerChromium.h:
930         (WebCore::LayerChromium::bounds):
931         (WebCore::LayerChromium::doubleSided):
932         (WebCore::LayerChromium::setDoubleSided):
933         * platform/graphics/chromium/LayerRendererChromium.cpp:
934         (WebCore::LayerRendererChromium::updatePropertiesAndRenderSurfaces):
935         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
936         (WebCore::CCLayerImpl::CCLayerImpl):
937         (WebCore::CCLayerImpl::updateFromLayer):
938         (WebCore::CCLayerImpl::descendantsDrawsContent):
939         * platform/graphics/chromium/cc/CCLayerImpl.h:
940         (WebCore::CCLayerImpl::anchorPoint):
941         (WebCore::CCLayerImpl::anchorPointZ):
942         (WebCore::CCLayerImpl::masksToBounds):
943         (WebCore::CCLayerImpl::opacity):
944         (WebCore::CCLayerImpl::position):
945         (WebCore::CCLayerImpl::preserves3D):
946         (WebCore::CCLayerImpl::sublayerTransform):
947         (WebCore::CCLayerImpl::transform):
948
949 2011-03-08  James Robinson  <jamesr@chromium.org>
950
951         Chromium compile fix.
952
953         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
954         (WebCore::SimpleFontData::platformInit):
955
956 2011-03-08  Peter Kasting  <pkasting@google.com>
957
958         Reviewed by James Robinson.
959
960         Unify Windows version checks, part 1.
961         https://bugs.webkit.org/show_bug.cgi?id=55979
962
963         Make everyone (I hope) pull in SystemInfo.cpp.  Eliminate the
964         now-unnecessary WindowsVersion.cpp from Chromium.
965
966         * GNUmakefile.am:
967         * WebCore.gyp/WebCore.gyp:
968         * WebCore.gypi:
969         * platform/chromium/ScrollbarThemeChromiumWin.cpp:
970         (WebCore::ScrollbarThemeChromiumWin::invalidateOnMouseEnterExit):
971         (WebCore::ScrollbarThemeChromiumWin::getThemeState):
972         (WebCore::ScrollbarThemeChromiumWin::getThemeArrowState):
973         * platform/chromium/WindowsVersion.cpp: Removed.
974         * platform/chromium/WindowsVersion.h: Removed.
975         * platform/graphics/chromium/GlyphPageTreeNodeChromiumWin.cpp:
976         (WebCore::fillBMPGlyphs):
977         * rendering/RenderThemeChromiumWin.cpp:
978         (WebCore::getNonClientMetrics):
979
980 2011-03-08  Ryosuke Niwa  <rniwa@webkit.org>
981
982         Chromium Linux build fix attempt after r80582.
983
984         * platform/graphics/chromium/FontLinux.cpp:
985         (WebCore::Font::drawGlyphs):
986         * platform/graphics/chromium/SimpleFontDataLinux.cpp:
987         (WebCore::SimpleFontData::platformInit):
988         * platform/graphics/skia/GlyphPageTreeNodeSkia.cpp:
989         (WebCore::GlyphPage::fill):
990
991 2011-03-08  Ryosuke Niwa  <rniwa@webkit.org>
992
993         Mac build fix attempt for r80582.
994
995         * platform/graphics/mac/ComplexTextControllerATSUI.cpp:
996         (WebCore::disableLigatures):
997
998 2011-03-08  Ryosuke Niwa  <rniwa@webkit.org>
999
1000         Reviewed by Kent Tamura.
1001
1002         Remove calls to deprecatedEditingOffset in SelectionController and VisibleSelection
1003         https://bugs.webkit.org/show_bug.cgi?id=54937
1004
1005         * editing/SelectionController.cpp:
1006         (WebCore::SelectionController::setSelection): Calls anchorNode() instead of deprecatedNode() to obtain
1007         the document. Also restrained the lifetime of document variable.
1008         (WebCore::removingNodeRemovesPosition): Compare the node with anchorNode() instead of deprecatedNode()
1009         to determine whether or not position becomes null after removing a node.
1010         (WebCore::SelectionController::directionOfEnclosingBlock): The enclosing block is always a container
1011         so call containerNode() instead of deprecatedNode().
1012         (WebCore::SelectionController::debugRenderer): Call containerNode() and computeOffsetInContainer()
1013         instead of deprecatedNode() and deprecatedEditingOffset() respectively.
1014         (WebCore::SelectionController::isInPasswordField): Look for the shadow root from containerNode()
1015         instead of deprecatedNode to determine whether or not selection inside a password field. Also assert
1016         that the specified position is not before or after the shadow root as it violates our assumption.
1017         * editing/VisibleSelection.cpp:
1018         (WebCore::makeSearchRange): Call containerNode() and offsetInContainerNode() instead of deprecatedNode()
1019         and deprecatedEditingOffset() respectively because start is always parent anchored and therefore
1020         guaranteed to be an offset inside an anchor node.
1021         (WebCore::VisibleSelection::adjustSelectionToAvoidCrossingEditingBoundaries): Call containerNode()
1022         instead of deprecatedNode() to look for the lowest editable ancestor because position before or after
1023         an editable element isn't editable.
1024         * page/DOMSelection.cpp: Call containerNode() and offsetInContainerNode() instead of deprecatedNode()
1025         and deprecatedEditingOffset() respectively in the following functions because they are exposed to
1026         DOM, which doesn't have before/after concept.
1027         (WebCore::DOMSelection::anchorNode):
1028         (WebCore::DOMSelection::anchorOffset):
1029         (WebCore::DOMSelection::focusNode):
1030         (WebCore::DOMSelection::focusOffset):
1031         (WebCore::DOMSelection::baseNode):
1032         (WebCore::DOMSelection::baseOffset):
1033         (WebCore::DOMSelection::extentNode):
1034         (WebCore::DOMSelection::extentOffset):
1035
1036 2011-03-08  Brent Fulgham  <bfulgham@webkit.org>
1037
1038         Reviewed by Adam Roben.
1039
1040         Correct uninitialized variable in PolicyCallback found while
1041         running WebKit in BoundsChecker.
1042         https://bugs.webkit.org/show_bug.cgi?id=45199.
1043
1044         * loader/PolicyCallback.cpp:
1045         (WebCore::PolicyCallback::PolicyCallback): Initialize
1046         m_argument.
1047
1048 2011-03-08  Brent Fulgham  <bfulgham@webkit.org>
1049
1050         More build bustage fix.
1051
1052         * platform/graphics/win/cairo/FontPlatformData.h:
1053         (WebCore::FontPlatformData::setOrientation): Duplicate accessor
1054         in WinCairo-local header.  This is such a mess!
1055
1056 2011-03-08  David Hyatt  <hyatt@apple.com>
1057
1058         Fix build bustage.  Hide orientation setting behind a setter and stub it out in all
1059         FontPlatformData classes.  (This class really needs to move to a common header with ifdefs.)
1060
1061         * platform/graphics/SimpleFontData.cpp:
1062         (WebCore::SimpleFontData::verticalRightOrientationFontData):
1063         * platform/graphics/cg/FontPlatformData.h:
1064         (WebCore::FontPlatformData::setOrientation):
1065         * platform/graphics/chromium/FontPlatformDataChromiumWin.h:
1066         (WebCore::FontPlatformData::setOrientation):
1067         * platform/graphics/chromium/FontPlatformDataLinux.h:
1068         (WebCore::FontPlatformData::setOrientation):
1069         * platform/graphics/cocoa/FontPlatformData.h:
1070         (WebCore::FontPlatformData::setOrientation):
1071         * platform/graphics/freetype/FontPlatformData.h:
1072         (WebCore::FontPlatformData::setOrientation):
1073         * platform/graphics/qt/FontPlatformData.h:
1074         (WebCore::FontPlatformData::setOrientation):
1075         * platform/graphics/wince/FontPlatformData.h:
1076         (WebCore::FontPlatformData::setOrientation):
1077         * platform/graphics/wx/FontPlatformData.h:
1078         (WebCore::FontPlatformData::setOrientation):
1079
1080 2011-03-08  Joe Wild  <joseph.wild@nokia.com>
1081
1082         Reviewed by Csaba Osztrogon√°c.
1083
1084         [Qt] Missing SVG variables
1085         https://bugs.webkit.org/show_bug.cgi?id=32941
1086
1087         Basically, this patch just modifies features.pri to the Qt build to
1088         pass on the ENABLE_SVG_* flags to the IDL binding generator.
1089
1090         Also I had remove global-construtors.html from the skip list and
1091         updated the associated expected results files.
1092
1093         * features.pri:
1094         * page/DOMWindow.idl:
1095
1096 2011-03-08  Alok priyadarshi  <alokp@chromium.org>
1097
1098         Reviewed by Dimitri Glazkov.
1099
1100         Plugins needs a way to trigger style recalc
1101         https://bugs.webkit.org/show_bug.cgi?id=55242
1102
1103         No test needed. A simple get function is added.
1104
1105         * platform/graphics/chromium/PluginLayerChromium.h:
1106         (WebCore::PluginLayerChromium::getTextureId):
1107
1108 2011-03-08  David Hyatt  <hyatt@apple.com>
1109
1110         Reviewed by Dan Bernstein.
1111
1112         https://bugs.webkit.org/show_bug.cgi?id=48540, support the text-orientation CSS property.
1113         
1114         This patch adds support for two values of the text-orientation property (the ones that actually matter): vertical-right and upright.
1115         The TextOrientation is part of the FontDescription and used to look up fonts (similar to FontOrientation).
1116         
1117         Orientation of non-CJK characters is done using fallback font data of the appropriate orientation type, e.g., verticalRightOrientation and
1118         uprightOrientation fallback font data.  Vertical right is just implemented as a normal horizontal font.  Upright is implemented as a
1119         vertically oriented font that rotates all glyphs.
1120         
1121         The main complication implementing text-orientation is that fonts have "baked-in" vertical glyphs for letters that are hardcoded to
1122         a vertical right facing.  This means that you can use those special vertical glyphs for vertical-right orientation without having to 
1123         fall back, but then for upright orientation you have to ignore them and still fall back.  As you can see from the test case, this doesn't
1124         work very well, but hopefully it won't be all that common.  Limitations of CoreText prevent this case from rendering properly in either the
1125         simple or complex code paths, although the simple code path at least gets close.
1126
1127         Added fast/blockflow/text-orientation-basic.html
1128
1129         * WebCore.exp.in:
1130         * WebCore.xcodeproj/project.pbxproj:
1131         * css/CSSComputedStyleDeclaration.cpp:
1132         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
1133         * css/CSSFontFaceSource.cpp:
1134         (WebCore::CSSFontFaceSource::getFontData):
1135         * css/CSSParser.cpp:
1136         (WebCore::CSSParser::parseValue):
1137         * css/CSSPrimitiveValueMappings.h:
1138         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1139         (WebCore::CSSPrimitiveValue::operator TextOrientation):
1140         * css/CSSPropertyNames.in:
1141         * css/CSSStyleSelector.cpp:
1142         (WebCore::CSSStyleSelector::applyDeclarations):
1143         (WebCore::CSSStyleSelector::applyProperty):
1144         * css/CSSValueKeywords.in:
1145         * loader/cache/CachedFont.cpp:
1146         (WebCore::CachedFont::platformDataFromCustomData):
1147         * loader/cache/CachedFont.h:
1148         * platform/graphics/FontCache.cpp:
1149         (WebCore::FontPlatformDataCacheKey::FontPlatformDataCacheKey):
1150         (WebCore::FontPlatformDataCacheKey::operator==):
1151         (WebCore::computeHash):
1152         (WebCore::FontCache::getCachedFontPlatformData):
1153         * platform/graphics/FontDescription.h:
1154         (WebCore::FontDescription::FontDescription):
1155         (WebCore::FontDescription::textOrientation):
1156         (WebCore::FontDescription::setTextOrientation):
1157         (WebCore::FontDescription::operator==):
1158         * platform/graphics/FontFastPath.cpp:
1159         (WebCore::Font::glyphDataForCharacter):
1160         (WebCore::offsetToMiddleOfGlyph):
1161         * platform/graphics/SimpleFontData.cpp:
1162         (WebCore::SimpleFontData::SimpleFontData):
1163         (WebCore::SimpleFontData::verticalRightOrientationFontData):
1164         (WebCore::SimpleFontData::uprightOrientationFontData):
1165         (WebCore::SimpleFontData::brokenIdeographFontData):
1166         (WebCore::SimpleFontData::DerivedFontData::~DerivedFontData):
1167         * platform/graphics/SimpleFontData.h:
1168         (WebCore::SimpleFontData::hasVerticalGlyphs):
1169         (WebCore::SimpleFontData::isTextOrientationFallback):
1170         * platform/graphics/cairo/FontCustomPlatformData.h:
1171         * platform/graphics/cocoa/FontPlatformData.h:
1172         (WebCore::FontPlatformData::FontPlatformData):
1173         (WebCore::FontPlatformData::textOrientation):
1174         (WebCore::FontPlatformData::hash):
1175         (WebCore::FontPlatformData::operator==):
1176         * platform/graphics/cocoa/FontPlatformDataCocoa.mm:
1177         (WebCore::FontPlatformData::FontPlatformData):
1178         (WebCore::FontPlatformData::operator=):
1179         * platform/graphics/freetype/FontCustomPlatformDataFreeType.cpp:
1180         (WebCore::FontCustomPlatformData::fontPlatformData):
1181         * platform/graphics/haiku/FontCustomPlatformData.cpp:
1182         (WebCore::FontCustomPlatformData::fontPlatformData):
1183         * platform/graphics/haiku/FontCustomPlatformData.h:
1184         * platform/graphics/mac/ComplexTextControllerCoreText.cpp:
1185         (WebCore::ComplexTextController::collectComplexTextRunsForCharactersCoreText):
1186         * platform/graphics/mac/FontCacheMac.mm:
1187         (WebCore::FontCache::createFontPlatformData):
1188         * platform/graphics/mac/FontCustomPlatformData.cpp:
1189         (WebCore::FontCustomPlatformData::fontPlatformData):
1190         * platform/graphics/mac/FontCustomPlatformData.h:
1191         * platform/graphics/mac/FontMac.mm:
1192         (WebCore::showGlyphsWithAdvances):
1193         (WebCore::Font::drawGlyphs):
1194         * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
1195         (WebCore::shouldUseCoreText):
1196         (WebCore::GlyphPage::fill):
1197         * platform/graphics/mac/SimpleFontDataCoreText.cpp:
1198         (WebCore::SimpleFontData::getCFStringAttributes):
1199         * platform/graphics/mac/SimpleFontDataMac.mm:
1200         (WebCore::SimpleFontData::platformInit):
1201         (WebCore::SimpleFontData::platformBoundsForGlyph):
1202         (WebCore::SimpleFontData::platformWidthForGlyph):
1203         * platform/graphics/pango/FontCustomPlatformDataPango.cpp:
1204         (WebCore::FontCustomPlatformData::fontPlatformData):
1205         * platform/graphics/qt/FontCustomPlatformData.h:
1206         * platform/graphics/qt/FontCustomPlatformDataQt.cpp:
1207         (WebCore::FontCustomPlatformData::fontPlatformData):
1208         * platform/graphics/skia/FontCustomPlatformData.cpp:
1209         (WebCore::FontCustomPlatformData::fontPlatformData):
1210         * platform/graphics/skia/FontCustomPlatformData.h:
1211         * platform/graphics/win/FontCustomPlatformData.cpp:
1212         (WebCore::FontCustomPlatformData::fontPlatformData):
1213         * platform/graphics/win/FontCustomPlatformData.h:
1214         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
1215         (WebCore::FontCustomPlatformData::fontPlatformData):
1216         * platform/graphics/win/FontCustomPlatformDataCairo.h:
1217         * platform/graphics/wince/FontCustomPlatformData.cpp:
1218         (WebCore::FontCustomPlatformData::fontPlatformData):
1219         * platform/graphics/wince/FontCustomPlatformData.h:
1220         * platform/text/TextOrientation.h: Added.
1221         * rendering/InlineFlowBox.cpp:
1222         (WebCore::InlineFlowBox::requiresIdeographicBaseline):
1223         * rendering/style/RenderStyle.h:
1224         (WebCore::InheritedFlags::initialTextOrientation):
1225
1226 2011-03-08  Ryosuke Niwa  <rniwa@webkit.org>
1227
1228         Reviewed by Darin Adler.
1229
1230         addInlineStyleIfNeeded should take EditingStyle
1231         https://bugs.webkit.org/show_bug.cgi?id=55950
1232
1233         Deployed EditingStyle in addInlineStyleIfNeeded, StyleChange::StyleChange, and StyleChange::init.
1234         Also extracted EditingStyle::styleIsPresentInComputedStyleOfNode from removeStyleFromRunBeforeApplyingStyle.
1235
1236         * editing/ApplyStyleCommand.cpp:
1237         (WebCore::StyleChange::StyleChange): Takes EditingStyle instead of CSSStyleDeclaration.
1238         (WebCore::StyleChange::init): Ditto.
1239         (WebCore::ApplyStyleCommand::applyBlockStyle): Instantiates StyleChange.
1240         (WebCore::ApplyStyleCommand::applyInlineStyleToNodeRange): Calls addInlineStyleIfNeeded.
1241         (WebCore::ApplyStyleCommand::removeStyleFromRunBeforeApplyingStyle): Calls styleIsPresentInComputedStyleOfNode.
1242         (WebCore::ApplyStyleCommand::removeInlineStyleFromElement): Calls EditingStyle::mergeInlineStyleOfElement
1243         instead of manually merging styles.
1244         (WebCore::ApplyStyleCommand::applyInlineStyleToPushDown): Calls addInlineStyleIfNeeded.
1245         (WebCore::ApplyStyleCommand::addInlineStyleIfNeeded): Takes EditingStyle instead of CSSMutableStyleDeclaration.
1246         * editing/ApplyStyleCommand.h:
1247         * editing/CompositeEditCommand.h:
1248         * editing/EditingStyle.cpp:
1249         (WebCore::EditingStyle::styleIsPresentInComputedStyleOfNode): Extracted from removeStyleFromRunBeforeApplyingStyle.
1250         * editing/EditingStyle.h:
1251
1252 2011-03-08  Nico Weber  <thakis@chromium.org>
1253
1254         Reviewed by James Robinson.
1255
1256         Crash on big blur radius with canvas
1257         https://bugs.webkit.org/show_bug.cgi?id=55951
1258
1259         Move the clamping code out of an if branch, so that it happens in the
1260         canvas case as well.
1261
1262         Test: fast/canvas/shadow-huge-blur.html
1263
1264         * platform/graphics/cg/GraphicsContextCG.cpp:
1265         (WebCore::GraphicsContext::setPlatformShadow):
1266
1267 2011-03-08  Chris Fleizach  <cfleizach@apple.com>
1268
1269         Reviewed by Sam Weinig.
1270
1271         WK2: Cannot set focus on an element when focus is outside of WKView
1272         https://bugs.webkit.org/show_bug.cgi?id=55281
1273     
1274         In WK2, focus cannot be set from the WebProcess side because there's no platformWidget().
1275         Instead, the focus/unfocus messages need to be sent to the UIProcess side.
1276
1277         * platform/mac/WidgetMac.mm:
1278         (WebCore::Widget::setFocus):
1279
1280 2011-03-08  Sam Weinig  <sam@webkit.org>
1281
1282         Reviewed by Anders Carlsson.
1283
1284         Overflow: scroll areas should not paint white in scroll corner if the 
1285         scrollbars are overlay.
1286         <rdar://problem/9082871>
1287
1288         * rendering/RenderLayer.cpp:
1289         (WebCore::RenderLayer::paintScrollCorner):
1290         Don't paint the scroll corner white if we have overlay scrollbars.
1291
1292 2011-03-08  Chris Marrin  <cmarrin@apple.com>
1293
1294         Reviewed by Darin Adler.
1295
1296         The first time animations are committed they have a bad start time
1297         https://bugs.webkit.org/show_bug.cgi?id=55947
1298
1299         Do a check for a returned lastCommitTime of <=0 and replace it
1300         with the mediaTime.
1301
1302
1303         * platform/graphics/ca/win/CACFLayerTreeHost.cpp:
1304         (WebCore::CACFLayerTreeHost::notifyAnimationsStarted):
1305
1306 2011-03-08  James Kozianski  <koz@chromium.org>
1307
1308         Reviewed by David Levin.
1309
1310         Expose isValidProtocol() in KURL.h.
1311         https://bugs.webkit.org/show_bug.cgi?id=54594
1312
1313         This is needed to validate protocols used in calls to
1314         navigator.registerProtocolHandler().
1315
1316         * platform/KURL.cpp:
1317         * platform/KURL.h:
1318         * platform/KURLGoogle.cpp:
1319         (WebCore::isValidProtocol):
1320
1321 2011-03-08  Adam Roben  <aroben@apple.com>
1322
1323         Set svn:mime-type to text/css for all Inspector CSS files
1324
1325         This will cause them to be served with the correct MIME type from svn.webkit.org's web
1326         interface.
1327
1328         Rubber-stamped by Tim Hatcher.
1329
1330         * inspector/front-end/audits.css: Added property svn:mime-type.
1331         * inspector/front-end/goToLineDialog.css: Added property svn:mime-type.
1332         * inspector/front-end/heapProfiler.css: Added property svn:mime-type.
1333         * inspector/front-end/helpScreen.css: Added property svn:mime-type.
1334         * inspector/front-end/inspector.css: Added property svn:mime-type.
1335         * inspector/front-end/inspectorSyntaxHighlight.css: Added property svn:mime-type.
1336         * inspector/front-end/networkPanel.css: Added property svn:mime-type.
1337         * inspector/front-end/popover.css: Added property svn:mime-type.
1338         * inspector/front-end/textViewer.css: Added property svn:mime-type.
1339
1340 2011-03-08  Andrei Popescu  <andreip@google.com>
1341
1342         Reviewed by Steve Block.
1343
1344         IDBCallbacks::onsuccess(IDBIndex*) is unused and should be removed.
1345         https://bugs.webkit.org/show_bug.cgi?id=55938
1346
1347         The IndexedDatabase specification changed and IDBIndex objects are no
1348         longer created asynchronously. We therefore no longer need this method.
1349
1350         No new tests, just cleanup.
1351
1352         * storage/IDBCallbacks.h:
1353         * storage/IDBRequest.cpp:
1354         * storage/IDBRequest.h:
1355
1356 2011-03-08  Sheriff Bot  <webkit.review.bot@gmail.com>
1357
1358         Unreviewed, rolling out r80551.
1359         http://trac.webkit.org/changeset/80551
1360         https://bugs.webkit.org/show_bug.cgi?id=55933
1361
1362         It broke 285 tests on Qt bot (Requested by Ossy on #webkit).
1363
1364         * WebCore.pro:
1365         * platform/SharedBuffer.cpp:
1366         * platform/SharedBuffer.h:
1367         * platform/network/qt/QNetworkReplyHandler.cpp:
1368         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
1369         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1370         (WebCore::QNetworkReplyHandler::forwardData):
1371         (WebCore::QNetworkReplyHandler::start):
1372         * platform/network/qt/QNetworkReplyHandler.h:
1373         * platform/network/qt/ResourceHandleQt.cpp:
1374         (WebCore::ResourceHandle::supportsBufferedData):
1375         (WebCore::ResourceHandle::bufferedData):
1376         * platform/qt/QtByteBlock.cpp: Removed.
1377         * platform/qt/QtByteBlock.h: Removed.
1378         * platform/qt/SharedBufferQt.cpp:
1379
1380 2011-03-08  Andreas Kling  <kling@webkit.org>
1381
1382         Reviewed by Benjamin Poulain.
1383
1384         RenderObject: Pass complex type arguments as const-references.
1385
1386         * WebCore.exp.in:
1387         * rendering/RenderObject.h:
1388         * rendering/RenderObject.cpp:
1389         (WebCore::RenderObject::drawBoxSideFromPath):
1390         (WebCore::RenderObject::drawArcForBoxSide):
1391         (WebCore::RenderObject::localToAbsolute):
1392         (WebCore::RenderObject::absoluteToLocal):
1393
1394 2011-03-08  Andreas Kling  <kling@webkit.org>
1395
1396         Reviewed by Antonio Gomes.
1397
1398         Path: Make measurement functions const
1399         https://bugs.webkit.org/show_bug.cgi?id=55914
1400
1401         * platform/graphics/Path.cpp:
1402         (WebCore::Path::length):
1403         (WebCore::Path::pointAtLength):
1404         (WebCore::Path::normalAngleAtLength):
1405         * platform/graphics/Path.h:
1406         * platform/graphics/cairo/PathCairo.cpp:
1407         (WebCore::Path::strokeBoundingRect):
1408         * platform/graphics/cg/PathCG.cpp:
1409         (WebCore::Path::strokeBoundingRect):
1410         * platform/graphics/openvg/PathOpenVG.cpp:
1411         (WebCore::Path::strokeBoundingRect):
1412         (WebCore::Path::length):
1413         (WebCore::Path::pointAtLength):
1414         (WebCore::Path::normalAngleAtLength):
1415         * platform/graphics/qt/PathQt.cpp:
1416         (WebCore::Path::strokeBoundingRect):
1417         (WebCore::Path::length):
1418         (WebCore::Path::pointAtLength):
1419         (WebCore::Path::normalAngleAtLength):
1420         * platform/graphics/skia/PathSkia.cpp:
1421         (WebCore::Path::strokeBoundingRect):
1422         * platform/graphics/wince/PathWinCE.cpp:
1423         (WebCore::Path::strokeBoundingRect):
1424         * platform/graphics/wx/PathWx.cpp:
1425         (WebCore::Path::strokeBoundingRect):
1426
1427 2011-03-08  Carlos Garcia Campos  <cgarcia@igalia.com>
1428
1429         Reviewed by Martin Robinson.
1430
1431         [GTK] Do not set juntion sides on scrollbar stepper buttons
1432         https://bugs.webkit.org/show_bug.cgi?id=55868
1433
1434         Fixes rendering of steppers for themes using rounded stepper
1435         buttons on scrollbars like Adwaita.
1436
1437         * platform/gtk/ScrollbarThemeGtk3.cpp:
1438         (WebCore::ScrollbarThemeGtk::paintButton):
1439
1440 2011-03-08  Carlos Garcia Campos  <cgarcia@igalia.com>
1441
1442         Reviewed by Martin Robinson.
1443
1444         [GTK] Use doubles instead of integers for coordinates when rendering arrows
1445         https://bugs.webkit.org/show_bug.cgi?id=55866
1446
1447         To prevent off-by-one rounding errors.
1448
1449         * platform/gtk/RenderThemeGtk3.cpp:
1450         (WebCore::RenderThemeGtk::paintMenuList):
1451         * platform/gtk/ScrollbarThemeGtk3.cpp:
1452         (WebCore::ScrollbarThemeGtk::paintButton):
1453
1454 2011-03-08  Markus Goetz  <guruz@guruz.de>
1455
1456         Reviewed by Kenneth Rohde Christiansen.
1457
1458         [Qt] Use the QNetworkAccessManager zerocopy feature
1459         https://bugs.webkit.org/show_bug.cgi?id=50082
1460
1461         The feature will be introduced in Qt 4.8.
1462         This patch is backwards compatible with Qt 4.7.
1463
1464         * WebCore.pro:
1465         * platform/SharedBuffer.cpp:
1466         * platform/SharedBuffer.h:
1467         * platform/network/qt/QNetworkReplyHandler.cpp:
1468         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
1469         (WebCore::QNetworkReplyHandler::bufferedData):
1470         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
1471         (WebCore::QNetworkReplyHandler::downloadProgress):
1472         (WebCore::QNetworkReplyHandler::forwardData):
1473         (WebCore::QNetworkReplyHandler::start):
1474         * platform/network/qt/QNetworkReplyHandler.h:
1475         * platform/network/qt/ResourceHandleQt.cpp:
1476         (WebCore::ResourceHandle::supportsBufferedData):
1477         (WebCore::ResourceHandle::bufferedData):
1478         * platform/qt/SharedBufferQt.cpp:
1479         (WebCore::SharedBuffer::wrapQtByteBlock):
1480         (WebCore::SharedBuffer::hasPlatformData):
1481         (WebCore::SharedBuffer::platformData):
1482         (WebCore::SharedBuffer::platformDataSize):
1483         (WebCore::SharedBuffer::maybeTransferPlatformData):
1484         (WebCore::SharedBuffer::clearPlatformData):
1485
1486 2011-03-08  Alejandro G. Castro  <alex@igalia.com>
1487
1488         Reviewed by Martin Robinson.
1489
1490         [GTK] Fix compilation warnings after r80429
1491         https://bugs.webkit.org/show_bug.cgi?id=55864
1492
1493         * platform/gtk/WidgetGtk.cpp:
1494
1495 2011-03-08  Philippe Normand  <pnormand@igalia.com>
1496
1497         Unreviewed, GTK build fix after r80536
1498
1499         * GNUmakefile.am:
1500
1501 2011-03-08  Zan Dobersek  <zandobersek@gmail.com>
1502
1503         Reviewed by Martin Robinson.
1504
1505         [Gtk] toDataURL uses incorrect quality value when saving GdkPixbuf to buffer
1506         https://bugs.webkit.org/show_bug.cgi?id=55878
1507
1508         Multiply the quality parameter by 100 to put it in the range [0, 100] as needed
1509         when saving GdkPixbuf to a buffer.
1510
1511         * platform/graphics/gtk/ImageBufferGtk.cpp:
1512         (WebCore::ImageBuffer::toDataURL):
1513
1514 2011-03-07  Daniel Cheng  <dcheng@chromium.org>
1515
1516         Unreviewed.
1517
1518         Final build fix for r80536.
1519
1520         * DerivedSources.make:
1521
1522 2011-03-07  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1523
1524         Reviewed by Kent Tamura.
1525
1526         [EFL] Adjust functions of WebCore's efl port to WebKit coding style
1527         https://bugs.webkit.org/show_bug.cgi?id=55924
1528
1529         Adjust webkit style to PlatformKeyboardEventEfl, PlatformMouseEventEfl and WidgetEfl files.
1530
1531         * platform/efl/PlatformKeyboardEventEfl.cpp:
1532         (WebCore::PlatformKeyboardEvent::PlatformKeyboardEvent):
1533         * platform/efl/PlatformMouseEventEfl.cpp:
1534         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
1535         * platform/efl/WidgetEfl.cpp:
1536         (WebCore::Widget::frameRectsChanged):
1537         (WebCore::Widget::setEvasObject):
1538
1539 2011-03-07  Daniel Cheng  <dcheng@chromium.org>
1540
1541         Unreviewed.
1542
1543         More build fixes for r80536.
1544
1545         * CMakeLists.txt:
1546         * platform/chromium/ClipboardChromium.cpp:
1547         * platform/chromium/ClipboardChromium.h:
1548
1549 2011-03-07  Gyuyoung Kim  <gyuyoung.kim@samsung.com>
1550
1551         Reviewed by Antonio Gomes.
1552
1553         [EFL] Adjust functions of ScrollbarEfl.cpp to WebKit coding style
1554         https://bugs.webkit.org/show_bug.cgi?id=55917
1555
1556         Adjust webkit style to ScrollbarEfl files.
1557
1558         * platform/efl/ScrollbarEfl.cpp:
1559         (scrollbarEflEdjeMessage):
1560         (ScrollbarEfl::setParent):
1561         (ScrollbarEfl::updateThumbPositionAndProportion):
1562         (ScrollbarEfl::frameRectsChanged):
1563         (ScrollbarEfl::paint):
1564         * platform/efl/ScrollbarEfl.h:
1565
1566 2011-03-07  Daniel Cheng  <dcheng@chromium.org>
1567
1568         Unreviewed.
1569
1570         Build fix for Chromium after r80536.
1571
1572         * platform/chromium/DataTransferItemChromium.cpp:
1573         * platform/chromium/DataTransferItemsChromium.cpp:
1574
1575 2011-03-07  Daniel Cheng  <dcheng@chromium.org>
1576
1577         Unreviewed.
1578
1579         More build fixes for r80536.
1580
1581         * CMakeLists.txt:
1582         * platform/chromium/ClipboardChromium.cpp:
1583         * platform/chromium/ClipboardChromium.h:
1584
1585 2011-03-07  Daniel Cheng  <dcheng@chromium.org>
1586
1587         Reviewed by David Levin.
1588
1589         Add support for DataTransferItems
1590         https://bugs.webkit.org/show_bug.cgi?id=55115
1591
1592         This patch adds stubs for DataTransferItems/DataTransferItem as well as implementing the
1593         basic functionality on the Chromium port. With the exception of DataTransferItem::getAsFile,
1594         all functionality on the DataTransferItems collection has been implemented.
1595         This change does not actually hook up DataTransferItems to reflect the actual contents of a
1596         drop/paste operation or to allow mutation of data in a copy/drag start yet. That will be
1597         enabled via several followup patches.
1598
1599         Test: editing/pasteboard/data-transfer-items.html
1600
1601         * Android.mk:
1602         * CMakeLists.txt:
1603         * CodeGenerators.pri:
1604         * DerivedSources.cpp:
1605         * DerivedSources.make:
1606         * GNUmakefile.am:
1607         * WebCore.gypi:
1608         * WebCore.pro:
1609         * WebCore.vcproj/WebCore.vcproj:
1610         * WebCore.xcodeproj/project.pbxproj:
1611         * bindings/generic/RuntimeEnabledFeatures.cpp:
1612         * bindings/generic/RuntimeEnabledFeatures.h:
1613         (WebCore::RuntimeEnabledFeatures::setDataTransferItemsEnabled):
1614         (WebCore::RuntimeEnabledFeatures::dataTransferItemsEnabled):
1615         * bindings/scripts/CodeGeneratorV8.pm: Do not emit an #include line for DOMString, since it's built-in.
1616         * dom/Clipboard.h:
1617         (WebCore::Clipboard::policy):
1618         * dom/Clipboard.idl:
1619         * dom/DataTransferItem.cpp: Added.
1620         * dom/DataTransferItem.h: Added.
1621         (WebCore::DataTransferItem::~DataTransferItem):
1622         * dom/DataTransferItem.idl: Added.
1623         * dom/DataTransferItems.h: Added.
1624         (WebCore::DataTransferItems::~DataTransferItems):
1625         * dom/DataTransferItems.idl: Added.
1626         * dom/StringCallback.cpp: Added.
1627         (WebCore::StringCallback::scheduleCallback):
1628         * dom/StringCallback.h: Added.
1629         (WebCore::StringCallback::~StringCallback):
1630         * dom/StringCallback.idl: Added.
1631         * platform/chromium/ClipboardChromium.cpp:
1632         (WebCore::ClipboardChromium::items):
1633         * platform/chromium/ClipboardChromium.h:
1634         * platform/chromium/DataTransferItemChromium.cpp: Added.
1635         (WebCore::DataTransferItemChromium::create):
1636         (WebCore::DataTransferItemChromium::DataTransferItemChromium):
1637         (WebCore::DataTransferItemChromium::kind):
1638         (WebCore::DataTransferItemChromium::type):
1639         (WebCore::DataTransferItemChromium::getAsString):
1640         * platform/chromium/DataTransferItemChromium.h: Added.
1641         * platform/chromium/DataTransferItemsChromium.cpp: Added.
1642         (WebCore::DataTransferItemsChromium::create):
1643         (WebCore::DataTransferItemsChromium::DataTransferItemsChromium):
1644         (WebCore::DataTransferItemsChromium::length):
1645         (WebCore::DataTransferItemsChromium::item):
1646         (WebCore::DataTransferItemsChromium::deleteItem):
1647         (WebCore::DataTransferItemsChromium::clear):
1648         (WebCore::DataTransferItemsChromium::add):
1649         * platform/chromium/DataTransferItemsChromium.h: Added.
1650
1651 2011-03-07  Ryosuke Niwa  <rniwa@webkit.org>
1652
1653         Reviewed by Darin Adler.
1654
1655         selectionHasStyle and selectionStartHasStyle should use EditingStyle
1656         https://bugs.webkit.org/show_bug.cgi?id=55902
1657
1658         Deployed EditingStyle in selectionHasStyle and selectionStartHasStyle.
1659         This allowed us to move triStateOfStyle from Editor.cpp to EditingStyle.cpp.
1660
1661         Also changed the argument lists of selectionHasStyle and selectionStartHasStyle
1662         to take a property id and a value instead of a CSSMutableStyleDeclaration to cleanup
1663         call sites of these two functions.
1664
1665         * WebCore.exp.in: Updated the signature of selectionHasStyle. No longer exports
1666         selectionStartHasStyle because it's not called anywhere outside of WebCore.
1667         * WebCore.order: Ditto.
1668         * editing/EditingStyle.cpp:
1669         (WebCore::EditingStyle::EditingStyle): Added a new constructor that takes a property id
1670         and a property value.
1671         (WebCore::EditingStyle::triStateOfStyle): Moved from Editor.cpp.
1672         * editing/EditingStyle.h:
1673         (WebCore::EditingStyle::create): Added.
1674         * editing/Editor.cpp:
1675         (WebCore::Editor::selectionStartHasStyle): Takes a property id and a value instead of
1676         a CSSStyleDeclaration.
1677         (WebCore::Editor::selectionHasStyle): Ditto.
1678         * editing/Editor.h: Updated the signatures of selectionStartHasStyle and selectionHasStyle.
1679         * editing/EditorCommand.cpp:
1680         (WebCore::executeToggleStyle): Calls selectionStartHasStyle and selectionHasStyle.
1681         (WebCore::stateStyle): Ditto.
1682         * page/ContextMenuController.cpp:
1683         (WebCore::ContextMenuController::checkOrEnableIfNeeded): Ditto.
1684
1685 2011-03-07  Alexey Proskuryakov  <ap@apple.com>
1686
1687         Reviewed by Darin Adler.
1688
1689         REGRESSION (HTML5 tree builder): Text selection in a large text document is extremely slow
1690         https://bugs.webkit.org/show_bug.cgi?id=55898
1691
1692         <rdar://problem/9095839> REGRESSION: Mail hangs with a certain large mail message when
1693         linkifying e-mail addresses in in -[DOMCharacterData setData:]
1694
1695         Changes render tree of fast/text/large-text-composed-char.html, but not image results.
1696
1697         * dom/CharacterData.cpp: (WebCore::CharacterData::parserAppendData):
1698         Changed parserAppendData() to accept a maximum length, and moved code from Text::createWithLengthLimit().
1699
1700         * dom/CharacterData.h: Moved a constant for maximum length from Text.h.
1701
1702         * dom/Text.cpp: (WebCore::Text::createWithLengthLimit):
1703         * dom/Text.h:
1704         This function was unused in ToT. Moved code around to share with CharacterData.
1705
1706         * html/parser/HTMLConstructionSite.cpp: (WebCore::HTMLConstructionSite::insertTextNode):
1707         Chnaged to split large text nodes while parsing again.
1708
1709 2011-03-07  Alice Boxhall  <aboxhall@chromium.org>
1710
1711         Reviewed by Adam Barth.
1712
1713         Fix platform/image-encoders/JPEGImageEncoder.cpp empty_output_buffer() behaviour
1714         https://bugs.webkit.org/show_bug.cgi?id=54522
1715
1716         Fix jpegEmptyOutputBuffer() by ignoring free_in_buffer value as required.
1717
1718         No new tests, as this code is not yet used in WebKit. Once this code is used to implement canvas.toDataUrl(), the canvas tests will exercise it.
1719
1720         * platform/image-encoders/JPEGImageEncoder.cpp:
1721         (WebCore::jpegEmptyOutputBuffer):
1722
1723 2011-03-07  Sergey Glazunov  <serg.glazunov@gmail.com>
1724
1725         Reviewed by Eric Seidel.
1726
1727         Add the missing insertedIntoDocument() call in SVGVKernElement and SVGHKernElement
1728         https://bugs.webkit.org/show_bug.cgi?id=55896
1729
1730         Test: svg/dom/vkern-element-crash.html
1731
1732         * svg/SVGHKernElement.cpp:
1733         (WebCore::SVGHKernElement::insertedIntoDocument):
1734         * svg/SVGVKernElement.cpp:
1735         (WebCore::SVGVKernElement::insertedIntoDocument):
1736
1737 2011-03-07  Sheriff Bot  <webkit.review.bot@gmail.com>
1738
1739         Unreviewed, rolling out r80514.
1740         http://trac.webkit.org/changeset/80514
1741         https://bugs.webkit.org/show_bug.cgi?id=55915
1742
1743         Caused assertion failures (Requested by ukai on #webkit).
1744
1745         * platform/graphics/skia/GraphicsContextSkia.cpp:
1746         (WebCore::GraphicsContext::setPlatformShadow):
1747         * platform/graphics/skia/ImageSkia.cpp:
1748         (WebCore::paintSkBitmap):
1749
1750 2011-03-07  Cosmin Truta  <ctruta@chromium.org>
1751
1752         Reviewed by Adam Barth.
1753
1754         SVG <image> referenced by <use> is displayed incorrectly
1755         https://bugs.webkit.org/show_bug.cgi?id=55750
1756
1757         The result of sourceURI must use the URL of the enclosing document as base.
1758         Otherwise, the base may sometimes be empty, and, as a consequence,
1759         the intermediate KURL object may be invalid.
1760
1761         Test: svg/custom/use-image-in-g.svg
1762
1763         * svg/SVGImageLoader.cpp:
1764         (WebCore::SVGImageLoader::sourceURI):
1765
1766 2011-03-07  Helder Correia  <helder@sencha.com>
1767
1768         Reviewed by Simon Fraser.
1769
1770         Shadow is not shown when using strokeRect with a gradient strokeStyle
1771         https://bugs.webkit.org/show_bug.cgi?id=52509
1772
1773         This happens in CG and is related to bug 51869, this time to be fixed
1774         in GraphicsContext::strokeRect(const FloatRect& r, float lineWidth).
1775         We need to draw the gradient clipped to the stroke on a CGLayer first,
1776         and then draw the layer on the GraphicsContext.
1777
1778         Tests: fast/canvas/canvas-strokeRect-gradient-shadow.html
1779                svg/css/rect-gradient-stroke-shadow.svg
1780
1781         * platform/graphics/cg/GraphicsContextCG.cpp:
1782         (WebCore::GraphicsContext::strokeRect):
1783
1784 2011-03-07  Justin Novosad  <junov@chromium.org>
1785
1786         Reviewed by Kenneth Russell.
1787
1788         Fix for blurs behind bitmap images in Chromium, and boosting
1789         shadow blur quality 
1790         Bug URLs:
1791                 https://bugs.webkit.org/show_bug.cgi?id=55410
1792                 https://bugs.webkit.org/show_bug.cgi?id=55506
1793
1794         No new tests. Covered by existing layout tests. 
1795
1796         * platform/graphics/skia/GraphicsContextSkia.cpp:
1797         (WebCore::GraphicsContext::setPlatformShadow): Turn on high quality shadows and fix shadow color
1798         * platform/graphics/skia/ImageSkia.cpp:
1799         (WebCore::paintSkBitmap): Propagate the draw looper from context to painter
1800
1801 2011-03-07  Andreas Kling  <kling@webkit.org>
1802
1803         Unreviewed Mac build fix after r80508.
1804
1805         * WebCore.exp.in:
1806
1807 2011-03-07  Enrica Casucci  <enrica@apple.com>
1808
1809         Unreviewed build fix.
1810
1811         Rolling back  http://trac.webkit.org/changeset/80497 due to the
1812         32-bit build failures.
1813
1814         * WebCore.xcodeproj/project.pbxproj:
1815         * platform/mac/HTMLConverter.h: Removed.
1816         * platform/mac/HTMLConverter.mm: Removed.
1817         * platform/mac/PasteboardMac.mm:
1818         (WebCore::Pasteboard::writeSelection):
1819
1820 2011-03-07  Andreas Kling  <kling@webkit.org>
1821
1822         Reviewed by Benjamin Poulain.
1823
1824         FrameView::setBaseBackgroundColor: Pass Color argument as const-reference.
1825
1826         * page/FrameView.cpp:
1827         (WebCore::FrameView::setBaseBackgroundColor):
1828         * page/FrameView.h:
1829
1830 2011-03-07  Adam Barth  <abarth@webkit.org>
1831
1832         Reviewed by Dimitri Glazkov.
1833
1834         REGRESSION(r78147): Crash on http://gnarf.net/jquery/test/
1835         https://bugs.webkit.org/show_bug.cgi?id=55894
1836
1837         The m_frame can disappear out from under us, and there's no point in
1838         checking whether the load is complete in a non-existant frame.
1839
1840         Test: fast/parser/document-write-into-initial-document.html
1841
1842         * dom/Document.cpp:
1843         (WebCore::Document::explicitClose):
1844
1845 2011-03-07  Sheriff Bot  <webkit.review.bot@gmail.com>
1846
1847         Unreviewed, rolling out r80500.
1848         http://trac.webkit.org/changeset/80500
1849         https://bugs.webkit.org/show_bug.cgi?id=55908
1850
1851         Caused mysterious GYP error (Requested by abarth on #webkit).
1852
1853         * WebCore.gyp/WebCore.gyp:
1854         * WebCore.gypi:
1855
1856 2011-03-07  Adam Barth  <abarth@webkit.org>
1857
1858         Fix Chromium Mac build.  This header should only be included when the
1859         feature is enabled.
1860
1861         * platform/cf/RunLoopTimerCF.cpp:
1862
1863 2011-03-07  Adam Barth  <abarth@webkit.org>
1864
1865         Reviewed by Dimitri Glazkov.
1866
1867         Add WML files to WebCore.gypi
1868         https://bugs.webkit.org/show_bug.cgi?id=55905
1869
1870         * WebCore.gyp/WebCore.gyp:
1871         * WebCore.gypi:
1872
1873 2011-03-07  Adrienne Walker  <enne@google.com>
1874
1875         Reviewed by James Robinson.
1876
1877         [chromium] Add missing include to #define Skia parameter
1878         https://bugs.webkit.org/show_bug.cgi?id=55885
1879
1880         * platform/graphics/chromium/ShaderChromium.h:
1881
1882 2011-03-07  Chris Fleizach  <cfleizach@apple.com>
1883
1884         Reviewed by Beth Dakin.
1885
1886         AX: WK1 needs to use ScrollView attachment for AXScrollArea, WK2 does not
1887         https://bugs.webkit.org/show_bug.cgi?id=55706
1888
1889         * WebCore.exp.in:
1890         * accessibility/AXObjectCache.cpp:
1891         (WebCore::AXObjectCache::rootObjectForFrame):
1892         * accessibility/AXObjectCache.h:
1893         * accessibility/AccessibilityScrollView.cpp:
1894         (WebCore::AccessibilityScrollView::isAttachment):
1895         (WebCore::AccessibilityScrollView::widgetForAttachmentView):
1896         * accessibility/AccessibilityScrollView.h:
1897         (WebCore::AccessibilityScrollView::firstChild):
1898         * accessibility/mac/AccessibilityObjectWrapper.mm:
1899         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
1900
1901 2011-03-07  Enrica Casucci  <enrica@apple.com>
1902
1903         Reviewed by Darin Adler.
1904         
1905         REGRESSION: Copied content loses formatting on paste to external apps.
1906         https://bugs.webkit.org/show_bug.cgi?id=47615
1907         <rdar://problem/9001214>
1908
1909         This is a resubmission of a patch that was landed a while ago then rolled
1910         back because of a build failure on SnowLeopard and Leopard.
1911         
1912         This patch adds a way for WebKit2 to create NSAttributedStrings from
1913         a DOM range without using the AppKit api initWithDOMRange that internally
1914         needs to access the WebView. The NSAttributedString is needed to create
1915         RTF formats in the pasteboard.
1916         This is to be considered a first step, since in the future we want to have
1917         an implementation based on the TextIterator.
1918
1919         * WebCore.xcodeproj/project.pbxproj: Added new file.
1920         * platform/mac/HTMLConverter.h: Added.
1921         * platform/mac/HTMLConverter.mm: Added.
1922         * platform/mac/PasteboardMac.mm:
1923         (WebCore::Pasteboard::writeSelection): We now use WebHTMLConverter
1924         class for WebKit2 to create the NSAttributedString from the DOM range.
1925
1926 2011-03-07  Adam Barth  <abarth@webkit.org>
1927
1928         Reviewed by Dimitri Glazkov.
1929
1930         Add some missing platform files to WebCore.gypi
1931         https://bugs.webkit.org/show_bug.cgi?id=55897
1932
1933         There are a bunch more, but this is a start.
1934
1935         * WebCore.gyp/WebCore.gyp:
1936         * WebCore.gypi:
1937
1938 2011-03-07  Steve Block  <steveblock@google.com>
1939
1940         Reviewed by Jeremy Orlow.
1941
1942         Rename JNIBridgeV8.cpp/h to JavaFieldV8.cpp/h
1943         https://bugs.webkit.org/show_bug.cgi?id=55879
1944
1945         No new tests, refactoring only.
1946
1947         * Android.v8bindings.mk:
1948         * WebCore.gypi:
1949         * bridge/jni/v8/JavaClassV8.cpp:
1950         * bridge/jni/v8/JavaClassV8.h:
1951         * bridge/jni/v8/JavaFieldV8.cpp: Renamed from Source/WebCore/bridge/jni/v8/JNIBridgeV8.cpp.
1952         (JavaField::JavaField):
1953         * bridge/jni/v8/JavaFieldV8.h: Renamed from Source/WebCore/bridge/jni/v8/JNIBridgeV8.h.
1954         (JSC::Bindings::JavaField::name):
1955         (JSC::Bindings::JavaField::type):
1956         (JSC::Bindings::JavaField::getJNIType):
1957         * bridge/jni/v8/JavaInstanceV8.cpp:
1958         * bridge/jni/v8/JavaNPObjectV8.cpp:
1959
1960 2011-03-07  Daniel Cheng  <dcheng@chromium.org>
1961
1962         Reviewed by Tony Chang.
1963
1964         Add plumbing for paste support to ChromiumDataObject::types()
1965         https://bugs.webkit.org/show_bug.cgi?id=55792
1966
1967         This is a preliminary patch to support event.dataTransfer.items. This
1968         adds plumbing to support retrieving the types in a paste event. It also
1969         moves the check for files in a drag/paste up to ClipboardChromium, since
1970         internal code needs to be able to differentiate between actual files in
1971         a drag and someone that simply decided to use "Files" as a custom type
1972         string.
1973
1974         Test: editing/pasteboard/onpaste-text-html-types.html
1975
1976         * platform/chromium/ChromiumDataObject.cpp:
1977         (WebCore::ChromiumDataObject::types):
1978         (WebCore::ChromiumDataObject::containsFilenames):
1979         * platform/chromium/ChromiumDataObject.h:
1980         * platform/chromium/ClipboardChromium.cpp:
1981         (WebCore::ClipboardChromium::types):
1982         * platform/chromium/ClipboardMimeTypes.cpp:
1983         * platform/chromium/ClipboardMimeTypes.h:
1984
1985 2011-03-07  Takayoshi Kochi  <kochi@chromium.org>
1986
1987         Reviewed by Tony Chang.
1988
1989         [chromium] Use preferred locale information when choosing fallback
1990         font using fontconfig on Linux platform.
1991         http://bugs.webkit.org/show_bug.cgi?id=55453
1992
1993         No new tests, as it depends on ICU and locale setting, so it will be
1994         covered by Chromium side.
1995
1996         * platform/chromium/PlatformBridge.h:
1997         * platform/graphics/chromium/FontCacheLinux.cpp:
1998
1999 2011-03-07  Adam Barth  <abarth@webkit.org>
2000
2001         Reviewed by Eric Seidel.
2002
2003         Add gobject, cpp, and objc bindings to WebCore.gypi
2004         https://bugs.webkit.org/show_bug.cgi?id=55892
2005
2006         These are also excluded from the Chromium build but needed for various
2007         other ports.
2008
2009         * WebCore.gyp/WebCore.gyp:
2010         * WebCore.gypi:
2011
2012 2011-03-07  Sergey Glazunov  <serg.glazunov@gmail.com>
2013
2014         Reviewed by Dimitri Glazkov.
2015
2016         Node::checkAddChild and Node::checkReplaceChild shouldn't change the owner document of a node
2017         https://bugs.webkit.org/show_bug.cgi?id=55803
2018
2019         Test: fast/dom/dom-method-document-change.html
2020
2021         * dom/ContainerNode.cpp:
2022         (WebCore::ContainerNode::insertBefore):
2023         (WebCore::ContainerNode::replaceChild):
2024         (WebCore::ContainerNode::appendChild):
2025         * dom/Node.cpp:
2026         (WebCore::Node::checkReplaceChild):
2027         (WebCore::Node::checkAddChild):
2028         * dom/Node.h:
2029
2030 2011-03-07  Sheriff Bot  <webkit.review.bot@gmail.com>
2031
2032         Unreviewed, rolling out r80484.
2033         http://trac.webkit.org/changeset/80484
2034         https://bugs.webkit.org/show_bug.cgi?id=55891
2035
2036         requires Chromium DEPS roll (Requested by dcheng on #webkit).
2037
2038         * platform/chromium/ChromiumDataObject.cpp:
2039         (WebCore::ChromiumDataObject::types):
2040         * platform/chromium/ChromiumDataObject.h:
2041         (WebCore::ChromiumDataObject::containsFilenames):
2042         * platform/chromium/ClipboardChromium.cpp:
2043         (WebCore::ClipboardChromium::types):
2044         * platform/chromium/ClipboardMimeTypes.cpp:
2045         * platform/chromium/ClipboardMimeTypes.h:
2046
2047 2011-03-07  Adam Barth  <abarth@webkit.org>
2048
2049         Reviewed by Dimitri Glazkov.
2050
2051         Add missing bindings/js files to WebCore.gypi
2052         https://bugs.webkit.org/show_bug.cgi?id=55888
2053
2054         These files are excluded from the Chromium build but needed for the Mac
2055         build.
2056
2057         * WebCore.gypi:
2058
2059 2011-03-07  Daniel Cheng  <dcheng@chromium.org>
2060
2061         Reviewed by Tony Chang.
2062
2063         Add plumbing for paste support to ChromiumDataObject::types()
2064         https://bugs.webkit.org/show_bug.cgi?id=55792
2065
2066         This is a preliminary patch to support event.dataTransfer.items. This
2067         adds plumbing to support retrieving the types in a paste event. It also
2068         moves the check for files in a drag/paste up to ClipboardChromium, since
2069         internal code needs to be able to differentiate between actual files in
2070         a drag and someone that simply decided to use "Files" as a custom type
2071         string.
2072
2073         Test: editing/pasteboard/onpaste-text-html-types.html
2074
2075         * platform/chromium/ChromiumDataObject.cpp:
2076         (WebCore::ChromiumDataObject::types):
2077         (WebCore::ChromiumDataObject::containsFilenames):
2078         * platform/chromium/ChromiumDataObject.h:
2079         * platform/chromium/ClipboardChromium.cpp:
2080         (WebCore::ClipboardChromium::types):
2081         * platform/chromium/ClipboardMimeTypes.cpp:
2082         * platform/chromium/ClipboardMimeTypes.h:
2083
2084 2011-03-07  Joseph Pecoraro  <joepeck@webkit.org>
2085
2086         Reviewed by Kenneth Rohde Christiansen.
2087
2088         Viewport Warning/Error Messages Are Now Inaccurate
2089         https://bugs.webkit.org/show_bug.cgi?id=53707
2090
2091         Correct and improve the error messages for viewport parsing.
2092
2093         Tests: fast/viewport/viewport-warnings-1.html
2094                fast/viewport/viewport-warnings-2.html
2095                fast/viewport/viewport-warnings-3.html
2096                fast/viewport/viewport-warnings-4.html
2097                fast/viewport/viewport-warnings-5.html
2098                fast/viewport/viewport-warnings-6.html
2099
2100         * dom/ViewportArguments.cpp:
2101         (WebCore::numericPrefix):
2102         (WebCore::findSizeValue): remove incorrect device-width / height tips.
2103         (WebCore::setViewportFeature): report a warning for an unrecognized key.
2104         (WebCore::viewportErrorMessageTemplate): added template for unrecognized key.
2105         (WebCore::viewportErrorMessageLevel): classify an unrecognized key is an error.
2106         * dom/ViewportArguments.h: removed no longer used warnings.
2107
2108 2011-03-07  James Robinson  <jamesr@chromium.org>
2109
2110         Reviewed by Kenneth Russell.
2111
2112         [chromium] Separate the update and draw portions of LayerRendererChromium's drawLayers function
2113         https://bugs.webkit.org/show_bug.cgi?id=54047
2114
2115         This splits up LayerRendererChromium::drawLayers() into two phases,
2116         one that updates layers and one that actually draws them.  Most of the
2117         patch is moving the bodies of drawLayers() and updateLayersRecursive()
2118         into smaller helper functions.
2119
2120         The main entry point is renamed updateAndDrawLayers(), but otherwise
2121         has the same signature as drawLayers() did.  Internally it does the
2122         following:
2123
2124         1.) Updates the root layer's contents
2125         2.) Updates the root layer's scrollbars
2126         3.) Updates the RenderSurface tree and the contents of all child
2127         layers
2128         4.) Draws the root layer and root layer scrollbars
2129         5.) Draws all child layers using the previously updated
2130         CCLayerImpl/RenderSurface data.
2131
2132         A few things still need to be done after this patch to complete the separation
2133         of the update and draw step, but they can happen in later patches:
2134         *) The root layer and root layer scrollbars contents should be
2135         uploaded to textures at draw time, not update time.
2136         *) The RenderSurface tree should be updated at draw time, not update
2137         time.
2138
2139         Covered by the compositing/ tests.
2140
2141         * platform/graphics/chromium/LayerRendererChromium.cpp:
2142         (WebCore::LayerRendererChromium::LayerRendererChromium):
2143         (WebCore::LayerRendererChromium::updateRootLayerContents):
2144         (WebCore::LayerRendererChromium::updateRootLayerScrollbars):
2145         (WebCore::LayerRendererChromium::drawRootLayer):
2146         (WebCore::LayerRendererChromium::updateAndDrawLayers):
2147         (WebCore::LayerRendererChromium::updateLayers):
2148         (WebCore::LayerRendererChromium::drawLayers):
2149         (WebCore::LayerRendererChromium::getFramebufferPixels):
2150         (WebCore::LayerRendererChromium::updatePropertiesAndRenderSurfaces):
2151         (WebCore::LayerRendererChromium::updateContentsRecursive):
2152         (WebCore::LayerRendererChromium::drawLayer):
2153         * platform/graphics/chromium/LayerRendererChromium.h:
2154         (WebCore::LayerRendererChromium::visibleRectSize):
2155         * platform/graphics/chromium/RenderSurfaceChromium.cpp:
2156         (WebCore::RenderSurfaceChromium::drawSurface):
2157         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
2158         * platform/graphics/chromium/cc/CCLayerImpl.h:
2159
2160 2011-03-07  Adam Barth  <abarth@webkit.org>
2161
2162         Reviewed by Eric Seidel.
2163
2164         Sort WebCore.gypi
2165         https://bugs.webkit.org/show_bug.cgi?id=55887
2166
2167         These files should be in order.  This is preparation for adding in the
2168         missing files.
2169
2170         * WebCore.gypi:
2171
2172 2011-03-07  Csaba Osztrogon√°c  <ossy@webkit.org>
2173
2174         Unreviewed buildfix after r80478.
2175
2176         * dom/Document.cpp: Add suggested parentheses to make GCC happy.
2177         (WebCore::Document::didReceiveTask):
2178
2179 2011-03-07  Yong Li  <yoli@rim.com>
2180
2181         Reviewed by Darin Adler.
2182
2183         Defer ScriptExecutionContext::Task's in Document when page loading is deferred.
2184         Schedule them with timer when page loading is resumed. The tasks will be performed
2185         in the original order. This fixes the problem that database callbacks could be missed
2186         when page loading was deferred.
2187         https://bugs.webkit.org/show_bug.cgi?id=49401
2188
2189         Manual test added: manual-tests/database-callback-deferred.html.
2190
2191         * dom/Document.cpp:
2192         (WebCore::Document::Document):
2193         (WebCore::Document::~Document):
2194         (WebCore::Document::didReceiveTask):
2195         (WebCore::Document::postTask):
2196         (WebCore::Document::pendingTasksTimerFired):
2197         (WebCore::Document::willDeferLoading):
2198         (WebCore::Document::didResumeLoading):
2199         * dom/Document.h:
2200         * manual-tests/database-callback-deferred.html: Added.
2201         * page/PageGroupLoadDeferrer.cpp:
2202         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
2203         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
2204
2205 2011-03-07  Antti Koivisto  <antti@apple.com>
2206
2207         Reviewed by Sam Weinig.
2208
2209         Use HashMaps for caching primitive values
2210         https://bugs.webkit.org/show_bug.cgi?id=55873
2211         
2212         Most documents use only small subset of cacheable primitive values. By replacing
2213         fixed size cache arrays with HashMaps we can reduce the constant memory usage while also
2214         expanding the range of cacheable values.
2215
2216         * css/CSSPrimitiveValueCache.cpp:
2217         (WebCore::CSSPrimitiveValueCache::CSSPrimitiveValueCache):
2218         (WebCore::CSSPrimitiveValueCache::createIdentifierValue):
2219         (WebCore::CSSPrimitiveValueCache::createColorValue):
2220         (WebCore::CSSPrimitiveValueCache::createValue):
2221         * css/CSSPrimitiveValueCache.h:
2222
2223 2011-03-07  Steve Block  <steveblock@google.com>
2224
2225         Reviewed by Jeremy Orlow.
2226
2227         Split JNIBridgeJSC.cpp/h into JavaArrayJSC.cpp/h and JavaFieldJSC.cpp/h
2228         https://bugs.webkit.org/show_bug.cgi?id=55881
2229
2230         No new tests, refactoring only.
2231
2232         * Android.jscbindings.mk:
2233         * GNUmakefile.am:
2234         * WebCore.xcodeproj/project.pbxproj:
2235         * bridge/jni/jsc/JNIBridgeJSC.cpp: Removed.
2236         * bridge/jni/jsc/JNIBridgeJSC.h: Removed.
2237         * bridge/jni/jsc/JNIUtilityPrivate.cpp:
2238         * bridge/jni/jsc/JavaClassJSC.cpp:
2239         * bridge/jni/jsc/JavaClassJSC.h:
2240         * bridge/jni/jsc/JavaInstanceJSC.cpp:
2241
2242 2011-03-07  Sam Weinig  <sam@webkit.org>
2243
2244         Reviewed by Anders Carlsson.
2245
2246         Replace WebKit2's decidePolicyForMIMEType with decidePolicyForResponse
2247         https://bugs.webkit.org/show_bug.cgi?id=55827
2248
2249         * loader/EmptyClients.h:
2250         (WebCore::EmptyFrameLoaderClient::dispatchDecidePolicyForResponse):
2251         * loader/FrameLoaderClient.h:
2252         * loader/MainResourceLoader.cpp:
2253         (WebCore::MainResourceLoader::didReceiveResponse):
2254         * loader/PolicyChecker.cpp:
2255         (WebCore::PolicyChecker::checkContentPolicy):
2256         * loader/PolicyChecker.h:
2257         Rename FrameLoaderClient::dispatchDecidePolicyForMIMEType to dispatchDecidePolicyForResponse
2258         and pass the entire response, instead of just the MIMEType.
2259
2260 2011-03-07  Eric Carlson  <eric.carlson@apple.com>
2261
2262         Reviewed by Darin Adler.
2263
2264         Add API to enumerate/delete files downloaded for <audio> and <video>
2265         https://bugs.webkit.org/show_bug.cgi?id=55267
2266         <rdar://problem/9049280>
2267
2268         No new tests, this is just more plumbing.
2269
2270         * html/HTMLMediaElement.cpp:
2271         (WebCore::HTMLMediaElement::getSitesInMediaCache): Make static, call MediaPlayer static method.
2272         (WebCore::HTMLMediaElement::clearMediaCache): Ditto.
2273         (WebCore::HTMLMediaElement::clearMediaCacheForSite): Ditto.
2274         * html/HTMLMediaElement.h:
2275
2276         * platform/graphics/MediaPlayer.cpp:
2277         (WebCore::MediaPlayerFactory::MediaPlayerFactory): Add new media engine factory functions.
2278         (WebCore::addMediaEngine): Ditto.
2279         (WebCore::MediaPlayer::getSitesInMediaCache): Call static method on all installed media engines.
2280         (WebCore::MediaPlayer::clearMediaCache): Ditto.
2281         (WebCore::MediaPlayer::clearMediaCacheForSite): Ditto.
2282         * platform/graphics/MediaPlayer.h:
2283
2284         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
2285         (WebCore::MediaPlayerPrivateGStreamer::registerMediaEngine): Update for MediaEngineRegistrar change.
2286
2287         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2288         (WebCore::MediaPlayerPrivateQTKit::registerMediaEngine): Ditto.
2289
2290         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp:
2291         (WebCore::MediaPlayerPrivatePhonon::registerMediaEngine): Ditto.
2292
2293         * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
2294         (WebCore::MediaPlayerPrivateQt::registerMediaEngine): Ditto.
2295
2296         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
2297         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::registerMediaEngine): Ditto.
2298
2299         * platform/graphics/win/MediaPlayerPrivateQuickTimeWin.cpp:
2300         (WebCore::MediaPlayerPrivate::registerMediaEngine): Ditto.
2301
2302 2011-03-07  Steve Block  <steveblock@google.com>
2303
2304         Reviewed by Jeremy Orlow.
2305
2306         Split JNIBridge.cpp/h into JavaString.h and JavaMethod.cpp/h
2307         https://bugs.webkit.org/show_bug.cgi?id=55774
2308
2309         No new tests, refactoring only.
2310
2311         * Android.jscbindings.mk:
2312         * Android.v8bindings.mk:
2313         * GNUmakefile.am:
2314         * WebCore.gypi:
2315         * WebCore.xcodeproj/project.pbxproj:
2316         * bridge/jni/JavaMethod.cpp:
2317         (JavaMethod::JavaMethod):
2318         (JavaMethod::~JavaMethod):
2319         (appendClassName):
2320         (JavaMethod::signature):
2321         (JavaMethod::JNIReturnType):
2322         (JavaMethod::methodID):
2323         * bridge/jni/JavaMethod.h:
2324         (JSC::Bindings::JavaMethod::name):
2325         (JSC::Bindings::JavaMethod::returnType):
2326         (JSC::Bindings::JavaMethod::parameterAt):
2327         (JSC::Bindings::JavaMethod::numParameters):
2328         (JSC::Bindings::JavaMethod::isStatic):
2329         * bridge/jni/JavaString.h:
2330         (JSC::Bindings::JavaString::JavaString):
2331         (JSC::Bindings::JavaString::utf8):
2332         (JSC::Bindings::JavaString::length):
2333         (JSC::Bindings::JavaString::impl):
2334         * bridge/jni/jni_jsobject.mm:
2335         * bridge/jni/jsc/JNIBridgeJSC.h:
2336         * bridge/jni/v8/JNIBridgeV8.h:
2337         * bridge/jni/v8/JavaClassV8.cpp:
2338         * bridge/jni/v8/JavaClassV8.h:
2339         * bridge/jni/v8/JavaInstanceV8.cpp:
2340
2341 2011-03-07  Jeremy Orlow  <jorlow@chromium.org>
2342
2343         Reviewed by Steve Block.
2344
2345         Add source to IDBCursor, objectStore to IDBIndex, and remove storeName
2346         https://bugs.webkit.org/show_bug.cgi?id=55812
2347
2348         This brings us in line with what's in the spec:
2349         http://dvcs.w3.org/hg/IndexedDB/raw-file/tip/Overview.html
2350
2351         * storage/IDBCursor.cpp:
2352         (WebCore::IDBCursor::create):
2353         (WebCore::IDBCursor::IDBCursor):
2354         (WebCore::IDBCursor::source):
2355         * storage/IDBCursor.h:
2356         * storage/IDBCursor.idl:
2357         * storage/IDBCursorWithValue.cpp:
2358         (WebCore::IDBCursorWithValue::create):
2359         (WebCore::IDBCursorWithValue::IDBCursorWithValue):
2360         * storage/IDBCursorWithValue.h:
2361         * storage/IDBIndex.cpp:
2362         (WebCore::IDBIndex::IDBIndex):
2363         * storage/IDBIndex.h:
2364         (WebCore::IDBIndex::create):
2365         (WebCore::IDBIndex::objectStore):
2366         * storage/IDBIndex.idl:
2367         * storage/IDBObjectStore.cpp:
2368         (WebCore::IDBObjectStore::createIndex):
2369         (WebCore::IDBObjectStore::index):
2370         * storage/IDBRequest.cpp:
2371         (WebCore::IDBRequest::onSuccess):
2372
2373 2011-03-07  Chris Fleizach  <cfleizach@apple.com>
2374
2375         Reviewed by Beth Dakin.
2376
2377         AX: kAXCellForColumnAndRowParameterizedAttribute doesn't work ARIA grids with colspans
2378         https://bugs.webkit.org/show_bug.cgi?id=55735
2379
2380         The ARIA grid implementation needed to verify the row/column range of a cell instead of 
2381         assuming a 1-1 mapping between children and row/column.
2382
2383         Test: platform/mac/accessibility/aria-table-with-colspan-cells.html
2384
2385         * accessibility/AccessibilityARIAGrid.cpp:
2386         (WebCore::AccessibilityARIAGrid::cellForColumnAndRow):
2387
2388 2011-03-07  Andrei Popescu  <andreip@google.com>
2389
2390         Reviewed by Steve Block.
2391
2392         IDBRequest::onSuccess(IDBObjectStore*) should be removed as it is unused.
2393         IDBObjectStore objects used to be created asynchronously, so we needed
2394         this method to be invoked, with the new object store as the parameter,
2395         whenever the creation succeeded. The spec has changed so that IDBObjectStore
2396         objects are created synchronously, so this method is no longer needed.
2397         https://bugs.webkit.org/show_bug.cgi?id=55777
2398
2399         No new tests, just refactoring.
2400
2401         * storage/IDBCallbacks.h:
2402         * storage/IDBRequest.cpp:
2403         * storage/IDBRequest.h:
2404
2405 2011-03-04  Steve Block  <steveblock@google.com>
2406
2407         Reviewed by Jeremy Orlow.
2408
2409         JavaParameter should be removed
2410         https://bugs.webkit.org/show_bug.cgi?id=55772
2411
2412         No new tests, refactoring only.
2413
2414         * bridge/jni/JNIBridge.cpp:
2415         (JavaMethod::JavaMethod):
2416         (JavaMethod::~JavaMethod):
2417         (JavaMethod::signature):
2418         * bridge/jni/JNIBridge.h:
2419         (JSC::Bindings::JavaMethod::parameterAt):
2420         (JSC::Bindings::JavaMethod::numParameters):
2421         * bridge/jni/JNIUtility.h:
2422         * bridge/jni/jsc/JavaInstanceJSC.cpp:
2423         (JavaInstance::invokeMethod):
2424         * bridge/jni/v8/JNIUtilityPrivate.cpp:
2425         (JSC::Bindings::convertNPVariantToJValue):
2426         * bridge/jni/v8/JNIUtilityPrivate.h:
2427         * bridge/jni/v8/JavaInstanceV8.cpp:
2428         (JavaInstance::invokeMethod):
2429
2430 2011-03-07  Antti Koivisto  <antti@apple.com>
2431
2432         Reviewed by Oliver Hunt.
2433
2434         REGRESSION (r79574): fast/dom/global-constructors.html failing on Windows 7 Release (Tests) bots 
2435         https://bugs.webkit.org/show_bug.cgi?id=55166
2436         <rdar://problem/9050430>
2437         
2438         Make CSS primitive value cache per-document.
2439         
2440         Test: http/tests/security/cross-origin-css-primitive.html
2441
2442         * Android.mk:
2443         * CMakeLists.txt:
2444         * GNUmakefile.am:
2445         * WebCore.gypi:
2446         * WebCore.pro:
2447         * WebCore.vcproj/WebCore.vcproj:
2448         * WebCore.xcodeproj/project.pbxproj:
2449         * css/CSSComputedStyleDeclaration.cpp:
2450         (WebCore::valueForNinePieceImage):
2451         (WebCore::zoomAdjustedPixelValue):
2452         (WebCore::zoomAdjustedNumberValue):
2453         (WebCore::zoomAdjustedPixelValueForLength):
2454         (WebCore::valueForReflection):
2455         (WebCore::getPositionOffsetValue):
2456         (WebCore::CSSComputedStyleDeclaration::currentColorOrValidColor):
2457         (WebCore::getBorderRadiusCornerValue):
2458         (WebCore::computedTransform):
2459         (WebCore::getDelayValue):
2460         (WebCore::getDurationValue):
2461         (WebCore::CSSComputedStyleDeclaration::getFontSizeCSSValuePreferringKeyword):
2462         (WebCore::CSSComputedStyleDeclaration::valueForShadow):
2463         (WebCore::valueForFamily):
2464         (WebCore::renderTextDecorationFlagsToCSSValue):
2465         (WebCore::fillRepeatToCSSValue):
2466         (WebCore::fillSizeToCSSValue):
2467         (WebCore::contentToCSSValue):
2468         (WebCore::counterToCSSValue):
2469         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
2470         * css/CSSParser.cpp:
2471         (WebCore::CSSParser::parseSheet):
2472         (WebCore::CSSParser::parseRule):
2473         (WebCore::CSSParser::parseKeyframeRule):
2474         (WebCore::CSSParser::parseValue):
2475         (WebCore::CSSParser::parseColor):
2476         (WebCore::CSSParser::parseSelector):
2477         (WebCore::CSSParser::parseDeclaration):
2478         (WebCore::CSSParser::setStyleSheet):
2479         (WebCore::CSSParser::parseWCSSInputProperty):
2480         (WebCore::parseBackgroundClip):
2481         (WebCore::CSSParser::parseFillShorthand):
2482         (WebCore::CSSParser::parsePage):
2483         (WebCore::CSSParser::parseSizeParameter):
2484         (WebCore::CSSParser::parseContent):
2485         (WebCore::CSSParser::parseAttr):
2486         (WebCore::CSSParser::parseBackgroundColor):
2487         (WebCore::CSSParser::parseFillPositionXY):
2488         (WebCore::CSSParser::parseFillPosition):
2489         (WebCore::CSSParser::parseFillRepeat):
2490         (WebCore::CSSParser::parseFillSize):
2491         (WebCore::CSSParser::parseFillProperty):
2492         (WebCore::CSSParser::parseAnimationDelay):
2493         (WebCore::CSSParser::parseAnimationDirection):
2494         (WebCore::CSSParser::parseAnimationDuration):
2495         (WebCore::CSSParser::parseAnimationFillMode):
2496         (WebCore::CSSParser::parseAnimationIterationCount):
2497         (WebCore::CSSParser::parseAnimationName):
2498         (WebCore::CSSParser::parseAnimationPlayState):
2499         (WebCore::CSSParser::parseAnimationProperty):
2500         (WebCore::CSSParser::parseTransformOriginShorthand):
2501         (WebCore::CSSParser::parseAnimationTimingFunction):
2502         (WebCore::CSSParser::parseDashboardRegions):
2503         (WebCore::CSSParser::parseCounterContent):
2504         (WebCore::CSSParser::parseShape):
2505         (WebCore::CSSParser::parseFont):
2506         (WebCore::CSSParser::parseFontFamily):
2507         (WebCore::CSSParser::parseFontStyle):
2508         (WebCore::CSSParser::parseFontVariant):
2509         (WebCore::CSSParser::parseFontWeight):
2510         (WebCore::ShadowParseContext::ShadowParseContext):
2511         (WebCore::ShadowParseContext::commitLength):
2512         (WebCore::ShadowParseContext::commitStyle):
2513         (WebCore::CSSParser::parseShadow):
2514         (WebCore::CSSParser::parseReflect):
2515         (WebCore::BorderImageParseContext::BorderImageParseContext):
2516         (WebCore::BorderImageParseContext::commitNumber):
2517         (WebCore::BorderImageParseContext::commitBorderImage):
2518         (WebCore::CSSParser::parseBorderImage):
2519         (WebCore::CSSParser::parseBorderRadius):
2520         (WebCore::CSSParser::parseCounter):
2521         (WebCore::parseDeprecatedGradientPoint):
2522         (WebCore::parseDeprecatedGradientColorStop):
2523         (WebCore::CSSParser::parseDeprecatedGradient):
2524         (WebCore::valueFromSideKeyword):
2525         (WebCore::parseGradientColorOrKeyword):
2526         (WebCore::CSSParser::parseLinearGradient):
2527         (WebCore::CSSParser::parseRadialGradient):
2528         (WebCore::CSSParser::parseGradientColorStops):
2529         (WebCore::CSSParser::parseTransform):
2530         (WebCore::CSSParser::parseTransformOrigin):
2531         (WebCore::CSSParser::parseTextEmphasisStyle):
2532         * css/CSSParser.h:
2533         (WebCore::CSSParser::primitiveValueCache):
2534         * css/CSSPrimitiveValue.cpp:
2535         * css/CSSPrimitiveValue.h:
2536         (WebCore::CSSPrimitiveValue::createIdentifier):
2537         (WebCore::CSSPrimitiveValue::createColor):
2538         (WebCore::CSSPrimitiveValue::create):
2539         * css/CSSPrimitiveValueCache.cpp: Added.
2540         (WebCore::CSSPrimitiveValueCache::CSSPrimitiveValueCache):
2541         (WebCore::CSSPrimitiveValueCache::~CSSPrimitiveValueCache):
2542         (WebCore::CSSPrimitiveValueCache::createIdentifierValue):
2543         (WebCore::CSSPrimitiveValueCache::createColorValue):
2544         (WebCore::CSSPrimitiveValueCache::createValue):
2545         * css/CSSPrimitiveValueCache.h: Added.
2546         (WebCore::CSSPrimitiveValueCache::create):
2547         (WebCore::CSSPrimitiveValueCache::createValue):
2548         * dom/Document.cpp:
2549         (WebCore::Document::cssPrimitiveValueCache):
2550         * dom/Document.h:
2551
2552 2011-03-06  Adam Barth  <abarth@webkit.org>
2553
2554         Reviewed by Eric Seidel.
2555
2556         Filter sources in WebCore GYP build for Mac
2557         https://bugs.webkit.org/show_bug.cgi?id=55857
2558
2559         This patch removes a large number of files that do not build as part of
2560         the Mac build.  I'm not fully sold on this method of
2561         including/excluding files, but it's the "gyp way" so we should probably
2562         try it first.
2563
2564         This patch also sets xcode_list_excluded_files to 0, which removes the
2565         excluded files from the Xcode project file, which is necessary in order
2566         to prevent the header map feature from including the wrong header file.
2567
2568         * gyp/WebCore.gyp:
2569
2570 2011-03-07  Ryuan Choi  <ryuan.choi@samsung.com>
2571
2572         Unreviewed EFL build fix.
2573
2574         [EFL] Build break on Debug build.
2575         https://bugs.webkit.org/show_bug.cgi?id=55858
2576
2577         * platform/efl/RenderThemeEfl.cpp:
2578         (WebCore::RenderThemeEfl::themePartCacheEntrySurfaceCreate):
2579
2580 2011-03-06  Adam Barth  <abarth@webkit.org>
2581
2582         Reviewed by Eric Seidel.
2583
2584         Add webcore_derived_source_files to WebCore.gypi
2585         https://bugs.webkit.org/show_bug.cgi?id=55856
2586
2587         This is the list of files generated by the Mac port.  It's possible
2588         other ports generate a different list of files.
2589
2590         * WebCore.gypi:
2591         * gyp/WebCore.gyp:
2592
2593 2011-03-06  Naoki Takano  <takano.naoki@gmail.com>
2594
2595         Reviewed by Kent Tamura.
2596
2597         Input type=number spin buttons remain invisible but functional after div changed from hidden to visible.
2598         https://bugs.webkit.org/show_bug.cgi?id=55839
2599         http://crbug.com/73866
2600         http://crbug.com/62527
2601
2602         We also need style change for m_innerSpinButton not only for m_outerSpinBuggon when styleDidChange() is called.
2603
2604         Test: fast/forms/input-appearance-spinbutton-visibility.html
2605
2606         * rendering/RenderTextControlSingleLine.cpp:
2607         (WebCore::RenderTextControlSingleLine::styleDidChange):
2608
2609 2011-03-06  Naoki Takano  <takano.naoki@gmail.com>
2610
2611         Reviewed by Kent Tamura.
2612
2613         [Chromium] Autocomplete suggestion extends out of window (and onto second monitor)
2614         https://bugs.webkit.org/show_bug.cgi?id=54795
2615
2616         Implement width clip logic according to browser screen width and popup window width. This fix is enough for Win and Mac, but there is a problem in Linux. Because WebScreenInfoFactory::screenInfo() can get only merged screen size, not the screen size where the browser exists.
2617
2618         Test: manual-tests/popup-width-restriction-within-screen.html
2619
2620         * manual-tests/popup-width-restriction-within-screen.html: Added.
2621         * platform/chromium/PopupMenuChromium.cpp:
2622         (WebCore::PopupContainer::layoutAndCalculateWidgetRect): Implement the width clip logic according to screen width.
2623
2624 2011-03-06  Yuta Kitamura  <yutak@chromium.org>
2625
2626         Reviewed by Kent Tamura.
2627
2628         Add SHA-1 for new WebSocket protocol
2629         https://bugs.webkit.org/show_bug.cgi?id=55039
2630
2631         * ForwardingHeaders/wtf/SHA1.h: Added.
2632
2633 2011-03-06  Eric Carlson  <eric.carlson@apple.com>
2634
2635         Reviewed by Antti Koivisto.
2636
2637         QuickTime based media engines should respect private browsing mode
2638         https://bugs.webkit.org/show_bug.cgi?id=55848
2639
2640         No new tests, it is only possible to test this by manually deleting and monitoring the
2641         the Quicktime caches.
2642
2643         * html/HTMLMediaElement.cpp:
2644         (WebCore::HTMLMediaElement::privateBrowsingStateDidChange): Add logging.
2645
2646         * platform/graphics/MediaPlayer.cpp:
2647         (WebCore::MediaPlayer::MediaPlayer): Initialize m_privateBrowsing.
2648         (WebCore::MediaPlayer::loadWithNextMediaEngine): Set privacy mode on new media engine.
2649         (WebCore::MediaPlayer::setPrivateBrowsingMode): Stash setting in m_privateBrowsing.
2650         * platform/graphics/MediaPlayer.h:
2651         * platform/graphics/MediaPlayerPrivate.h:
2652         (WebCore::MediaPlayerPrivateInterface::setPrivateBrowsingMode):
2653
2654         * platform/graphics/mac/MediaPlayerPrivateQTKit.h:
2655         * platform/graphics/mac/MediaPlayerPrivateQTKit.mm:
2656         (WebCore::MediaPlayerPrivateQTKit::MediaPlayerPrivateQTKit): Initialize m_privateBrowsing.
2657         (WebCore::MediaPlayerPrivateQTKit::createQTMovie): Pass private browsing attribute when
2658             creating new movie.
2659         (WebCore::MediaPlayerPrivateQTKit::setPrivateBrowsingMode): New, store privacy setting in
2660             m_privateBrowsing and set movie attribute.
2661
2662         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.cpp:
2663         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::MediaPlayerPrivateQuickTimeVisualContext):
2664             Initialize m_privateBrowsing.
2665         (WebCore::MediaPlayerPrivateQuickTimeVisualContext::setPrivateBrowsingMode): New, store 
2666             privacy setting in m_privateBrowsing and call QTMovie.
2667         * platform/graphics/win/MediaPlayerPrivateQuickTimeVisualContext.h:
2668
2669         * platform/graphics/win/QTMovie.cpp:
2670         (QTMoviePrivate::QTMoviePrivate): Initialize m_privateBrowsing.
2671         (QTMovie::load):Pass private browsing property when creating new movie.
2672         (QTMovie::setPrivateBrowsingMode):  New, store privacy setting in m_privateBrowsing and 
2673             set movie property.
2674         * platform/graphics/win/QTMovie.h:
2675
2676 2011-03-06  Daniel Bates  <dbates@rim.com>
2677
2678         Reviewed by Darin Adler.
2679
2680         style.borderSpacing always returns empty string
2681         https://bugs.webkit.org/show_bug.cgi?id=54816
2682
2683         Teach CSSMutableStyleDeclaration::getPropertyValue() how to reconstitute
2684         the value for border-spacing from the value of the WebKit internal CSS
2685         property -webkit-border-horizontal-spacing and -webkit-border-vertical-spacing.
2686
2687         The CSS property border-spacing describes the horizontal and vertical border
2688         spacing for an HTML Table element. Notice, WebKit internally represents the value
2689         of this property as two properties: -webkit-border-horizontal-spacing and
2690         -webkit-border-vertical-spacing, for the horizontal and vertical border spacing,
2691         respectively. And WebKit doesn't know to reconstitute these internal properties.
2692         Therefore style.borderSpacing always returns the empty string.
2693
2694         Test: fast/css/table-border-spacing.html
2695
2696         * css/CSSMutableStyleDeclaration.cpp:
2697         (WebCore::CSSMutableStyleDeclaration::getPropertyValue):
2698         (WebCore::CSSMutableStyleDeclaration::borderSpacingValue): Added.
2699         * css/CSSMutableStyleDeclaration.h:
2700
2701 2011-03-06  Dan Bernstein  <mitz@apple.com>
2702
2703         Reviewed by Oliver Hunt.
2704
2705         <rdar://problem/9093327> Implement -hyphenate-limit-{before,after}
2706         https://bugs.webkit.org/show_bug.cgi?id=55850
2707
2708         Tests: fast/css/parsing-hyphenate-limit.html
2709                fast/text/hyphenate-limit-before-after.html
2710
2711         * css/CSSComputedStyleDeclaration.cpp:
2712         (WebCore::computedProperties) Updated this array with the new properties and some old properties
2713         that it was missing.
2714         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): Added
2715         CSSPropertyWebkitHyphenateLimit{Before,After}.
2716
2717         * css/CSSParser.cpp:
2718         (WebCore::CSSParser::parseValue): Parse -webkit-hyphenate-limit-{before,after}, allowing
2719         'auto' and non-negative integers.
2720
2721         * css/CSSPropertyNames.in: Added -webkit-hyphenate-limit-{before,after}.
2722
2723         * css/CSSStyleSelector.cpp:
2724         (WebCore::CSSStyleSelector::applyProperty): Handle CSSPropertyWebkitHyphenateLimit{Before,After}.
2725
2726         * rendering/RenderBlockLineLayout.cpp:
2727         (WebCore::tryHyphenating): Added minimum prefix and suffix length parameters and checks to only
2728         allow hyphenation if the prefix and the suffix are sufficiently long.
2729         (WebCore::RenderBlock::findNextLineBreak): Pass the limits to tryHyphenating().
2730
2731         * rendering/style/RenderStyle.cpp:
2732         (WebCore::RenderStyle::diff): A difference in hyphenation limits is a layout difference.
2733
2734         * rendering/style/RenderStyle.h:
2735         (WebCore::InheritedFlags::hyphenationLimitBefore): Added.
2736         (WebCore::InheritedFlags::hyphenationLimitAfter): Added.
2737         (WebCore::InheritedFlags::setHyphenationLimitBefore): Added.
2738         (WebCore::InheritedFlags::setHyphenationLimitAfter): Added.
2739         (WebCore::InheritedFlags::initialHyphenationLimitBefore): Added. Returns -1, which is the
2740         representation of 'auto'.
2741         (WebCore::InheritedFlags::initialHyphenationLimitAfter): Ditto.
2742
2743         * rendering/style/StyleRareInheritedData.cpp:
2744         (WebCore::StyleRareInheritedData::StyleRareInheritedData): Initialize hyphenation limits.
2745         (WebCore::StyleRareInheritedData::operator==): Compare hyphenation limits.
2746         * rendering/style/StyleRareInheritedData.h:
2747
2748 2011-03-06  Jessie Berlin  <jberlin@apple.com>
2749
2750         Reviewed by Sam Weinig.
2751
2752         WebKit2: Use CFNetwork Sessions API.
2753         https://bugs.webkit.org/show_bug.cgi?id=55435.
2754
2755         When Private Browsing is enabled, use cookies from a in-memory cookie storage based on the
2756         Private Browsing Storage Session.
2757
2758         * WebCore.exp.in:
2759         Add the new WKSI functions.
2760         * platform/mac/WebCoreSystemInterface.h:
2761         Ditto.
2762         * platform/mac/WebCoreSystemInterface.mm:
2763         Ditto.
2764
2765         * platform/mac/CookieJar.mm:
2766         (WebCore::cookies):
2767         If USE(CFURLSTORAGESESSIONS) and there is a Private Browsing Cookie Storage, call into WKSI.
2768         Otherwise, behave the same as before.
2769         (WebCore::cookieRequestHeaderFieldValue):
2770         Ditto.
2771         (WebCore::setCookies):
2772         Ditto.
2773         (WebCore::cookiesEnabled):
2774         Ditto
2775         (WebCore::getRawCookies):
2776         Ditto.
2777         (WebCore::deleteCookie):
2778         Ditto.
2779
2780         * platform/network/CookieStorage.h:
2781         * platform/network/cf/CookieStorageCFNet.cpp:
2782         (WebCore::privateBrowsingCookieStorage):
2783         Keep track of the Private Browsing Cookie Storage in a locally defined static inside a
2784         function instead of at the global scope.
2785         (WebCore::currentCookieStorage):
2786         Use privateBrowsingCookieStorage.
2787         (WebCore::setCurrentCookieStorage):
2788         Ditto.
2789         (WebCore::setCookieStoragePrivateBrowsingEnabled):
2790         If USE(CFURLSTORAGESESSIONS), send the Private Browsing Storage Session to
2791         wkCreatePrivateInMemoryHTTPCookieStorage.
2792         * platform/network/mac/CookieStorageMac.mm:
2793         (WebCore::privateBrowsingCookieStorage):
2794         Keep track of the Private Browsing Cookie Storage.
2795         (WebCore::setCookieStoragePrivateBrowsingEnabled):
2796         If USE(CFURLSTORAGESESSIONS), then set or clear privateBrowsingCookieStorage().
2797         Added a FIXME to observe changes to the Private Browsing Cookie Storage when it is defined.
2798
2799         * platform/network/mac/ResourceHandleMac.mm:
2800         (WebCore::shouldRelaxThirdPartyCookiePolicy):
2801         Refactor the logic to determine whether or not to relax the third party cookie policy here.
2802         If USE(CFURLSTORAGESESSIONS), then get the information from the privateBrowsingCookieStorage.
2803         (WebCore::ResourceHandle::createNSURLConnection):
2804         Use shouldRelaxThirdPartyCookiePolicy.
2805         (WebCore::ResourceHandle::loadResourceSynchronously):
2806         Ditto.
2807
2808 2011-03-05  Sheriff Bot  <webkit.review.bot@gmail.com>
2809
2810         Unreviewed, rolling out r80428.
2811         http://trac.webkit.org/changeset/80428
2812         https://bugs.webkit.org/show_bug.cgi?id=55833
2813
2814         Broke SnowLeopard (Requested by xan_ on #webkit).
2815
2816         * plugins/gtk/PluginViewGtk.cpp:
2817         (WebCore::PluginView::handlePostReadFile):
2818
2819 2011-03-01  Martin Robinson  <mrobinson@igalia.com>
2820
2821         Reviewed by Xan Lopez.
2822
2823         [GTK] Windowless plugins override the view cursor
2824         https://bugs.webkit.org/show_bug.cgi?id=55531
2825
2826         manual test: manual-tests/plugins/windowless.html
2827
2828         * platform/gtk/WidgetGtk.cpp:
2829         (WebCore::Widget::setCursor): Call into the ChromeClient implementation now.
2830         * plugins/gtk/PluginViewGtk.cpp:
2831         (WebCore::PluginView::initXEvent): Instead of setting the window for windowless
2832         plugin events, set the window value to none. This method is also used to send
2833         focus in / focus out events to windowed plugins, but this is not one of the plugin
2834         types where the window parameter matters. This matches what Mozilla does. Also
2835         pass in the display of the widget itself, not the default display.
2836         (WebCore::PluginView::handleMouseEvent): When the cursor leaves the plugin area,
2837         reset the cursor.
2838         (WebCore::PluginView::platformGetValue): Clean up this section slightly. Give the
2839         widget the top-level window explicitly. This matches Mozilla.
2840
2841 2011-03-05  Martin Robinson  <mrobinson@igalia.com>
2842
2843         Reviewed by Xan Lopez.
2844
2845         [GTK] http/tests/plugins/post-url-file.html fails on GTK+
2846         https://bugs.webkit.org/show_bug.cgi?id=55826
2847
2848         Correct the implementation of handlePostReadFile which uses GIO APIs and
2849         actually resizes the buffer to fit the entire size of the file data. This
2850         was likely leading to memory corruption until now.
2851
2852         * plugins/gtk/PluginViewGtk.cpp:
2853         (WebCore::PluginView::handlePostReadFile): Fix this method.
2854
2855 2011-03-05  Mikhail Naganov  <mnaganov@chromium.org>
2856
2857         Reviewed by Pavel Feldman.
2858
2859         Web Inspector: [Chromium] Allow dynamic enabling of detailed heap profiles.
2860         https://bugs.webkit.org/show_bug.cgi?id=55824
2861
2862         Detailed heap profiles can be now enabled by typing "leakz" in Profiles tab.
2863
2864         * inspector/front-end/DetailedHeapshotView.js:
2865         (WebInspector.DetailedHeapshotView.prototype.isDetailedSnapshot):
2866         * inspector/front-end/ProfilesPanel.js:
2867         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot.doParse):
2868         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot):
2869         (WebInspector.ProfilesPanel.prototype._reportHeapSnapshotProgress):
2870         (WebInspector.ProfilesPanel.prototype.handleShortcut):
2871         (WebInspector.ProfilesPanel.prototype._displayDetailedHeapProfilesEnabledHint.hideHint):
2872         (WebInspector.ProfilesPanel.prototype._displayDetailedHeapProfilesEnabledHint):
2873         (WebInspector.ProfilesPanel.prototype._enableDetailedHeapProfiles):
2874         (WebInspector.ProfilesPanel.prototype._recognizeKeyboardCombo):
2875
2876 2011-03-05  Qi Zhang  <qi.2.zhang@nokia.com>
2877
2878         Reviewed by Laszlo Gombos.
2879
2880         [Qt] Mobile Devices should include Model and Firmware Version in Webkit Generated User Agent String
2881         https://bugs.webkit.org/show_bug.cgi?id=48636
2882
2883         Add model infomation into user agent string when qtmobility is available, but only for symbian, Maemo and MeeGo.
2884
2885         * WebCore.pri:
2886         * features.pri:
2887
2888 2011-03-05  Pavel Feldman  <pfeldman@chromium.org>
2889
2890         Not reviewed: adding null check to prevent inspector tests from failing.
2891
2892         * inspector/front-end/TextViewer.js:
2893         (WebInspector.TextEditorGutterChunk.prototype.get offsetTop):
2894         (WebInspector.TextEditorMainChunk.prototype.get offsetTop):
2895
2896 2011-03-05  Pavel Feldman  <pfeldman@chromium.org>
2897
2898         Not reviewed: chromium rebaseline, flaky test fix.
2899
2900         * inspector/front-end/BreakpointManager.js:
2901         (WebInspector.DOMBreakpointView.prototype.populateStatusMessageElement.decorateNode):
2902         (WebInspector.DOMBreakpointView.prototype.populateStatusMessageElement):
2903         (WebInspector.DOMBreakpointView.prototype._format.formatters.s):
2904         (WebInspector.DOMBreakpointView.prototype._format.append):
2905         (WebInspector.DOMBreakpointView.prototype._format):
2906
2907 2011-03-04  Pavel Podivilov  <podivilov@chromium.org>
2908
2909         Reviewed by Yury Semikhatsky.
2910
2911         Web Inspector: [chromium] pause when script is running is broken.
2912         https://bugs.webkit.org/show_bug.cgi?id=55762
2913
2914         * inspector/CodeGeneratorInspector.pm:
2915
2916 2011-03-05  Adam Barth  <abarth@webkit.org>
2917
2918         Reviewed by Dimitri Glazkov.
2919
2920         Add Derived Sources to WebCore GYP build
2921         https://bugs.webkit.org/show_bug.cgi?id=55813
2922
2923         Adding the derived source action to the GYP file required tweaking
2924         DerivedSources.make.  I'm not sure how DerivedSources.make worked
2925         before beause these paths were incorrectly based.
2926
2927         * DerivedSources.make:
2928         * gyp/generate-derived-sources.sh: Added.
2929         * gyp/WebCore.gyp:
2930
2931 2011-03-04  Pavel Feldman  <pfeldman@chromium.org>
2932
2933         Reviewed by Yury Semikhatsky.
2934
2935         Web Inspector: fix layout tests flakiness.
2936         https://bugs.webkit.org/show_bug.cgi?id=55816
2937
2938         - Order of issuing of evaluateForTestInFrontend was not guaranteed on the backend side (InspectorAgent side)
2939         - Order of dispatching using timeouts was guaranteed via queueing. Source of all kinds of pains on SnowLeopard Release (inspector.js)
2940
2941         * inspector/CodeGeneratorInspector.pm:
2942         * inspector/InspectorAgent.cpp:
2943         (WebCore::InspectorAgent::InspectorAgent):
2944         (WebCore::InspectorAgent::disconnectFrontend):
2945         (WebCore::InspectorAgent::populateScriptObjects):
2946         (WebCore::InspectorAgent::evaluateForTestInFrontend):
2947         (WebCore::InspectorAgent::issueEvaluateForTestCommands):
2948         * inspector/InspectorAgent.h:
2949         * inspector/front-end/TimelinePanel.js:
2950         (WebInspector.TimelinePanel.FormattedRecord):
2951         * inspector/front-end/inspector.js:
2952         (WebInspector.dispatch):
2953
2954 2011-03-05  Adam Barth  <abarth@webkit.org>
2955
2956         Reviewed by Dimitri Glazkov.
2957
2958         WebCore GYP build should generate fewer than 10,000 compile errors per file
2959         https://bugs.webkit.org/show_bug.cgi?id=55810
2960
2961         This patch adds some missing include paths.  We need to figure out how
2962         to handle separate include paths per port.  It's clear that
2963         ForwardingHeaders are only useful for Mac, but it's less clear how to
2964         handle the others.
2965
2966         * WebCore.gypi:
2967         * gyp/WebCore.gyp:
2968
2969 2011-03-05  Dan Bernstein  <mitz@apple.com>
2970
2971         Reviewed by Cameron Zwarich.
2972
2973         <rdar://problem/9082946> Make the Core Text code path in GlyphPage::fill() more robust
2974         https://bugs.webkit.org/show_bug.cgi?id=55817
2975
2976         * platform/graphics/mac/GlyphPageTreeNodeMac.cpp:
2977         (WebCore::GlyphPage::fill): When determining if a CTRun uses the primary font, compare against
2978         a CGFont obtained from Core Text for the primary font. This CGFont may be different from
2979         the CGFont stored in the FontPlatformData.
2980
2981 2011-03-05  Ilya Sherman  <isherman@chromium.org>
2982
2983         Reviewed by Darin Adler.
2984
2985         HTMLInputElement::setValue() should schedule change event when the element is focused.
2986         Refactored tracking of "changed since last change event" state from renderer to DOM.In service of https://code.google.com/p/chromium/issues
2987         In service of https://code.google.com/p/chromium/issues/detail?id=42716
2988         https://bugs.webkit.org/show_bug.cgi?id=53160
2989
2990         Test: fast/forms/onchange-change-type.html
2991         Test: fast/forms/onchange-setvalueforuser.html
2992
2993         * WebCore.exp.in:
2994         * dom/Document.cpp:
2995         (WebCore::Document::setFocusedNode):
2996         * dom/Element.h:
2997         (WebCore::Element::wasChangedSinceLastFormControlChangeEvent): Added.
2998         (WebCore::Element::setChangedSinceLastFormControlChangeEvent): Added.
2999         * html/HTMLFormControlElement.cpp:
3000         (WebCore::HTMLFormControlElement::HTMLFormControlElement):
3001         (WebCore::HTMLFormControlElement::wasChangedSinceLastFormControlChangeEvent): Added.
3002         (WebCore::HTMLFormControlElement::setChangedSinceLastFormControlChangeEvent): Added.
3003         (WebCore::HTMLFormControlElement::dispatchFormControlChangeEvent): Also clear the "changed since last change event" flag.
3004         (WebCore::HTMLFormControlElement::dispatchFormControlInputEvent): Also set the "changed since last change event" flag.
3005         * html/HTMLFormControlElement.h:
3006         * html/HTMLInputElement.cpp:
3007         (WebCore::HTMLInputElement::updateType): Also clear the "changed since last change event" flag.
3008         (WebCore::HTMLInputElement::setValue):
3009             For a focused text field, dispatch an input event, but delay the change event until the field loses focus.
3010         (WebCore::HTMLInputElement::defaultEventHandler):
3011         (WebCore::HTMLInputElement::stepUpFromRenderer):
3012         * html/shadow/TextControlInnerElements.cpp:
3013         (WebCore::SearchFieldCancelButtonElement::defaultEventHandler):
3014         * rendering/RenderTextControl.cpp:
3015         (WebCore::RenderTextControl::RenderTextControl):
3016         (WebCore::RenderTextControl::subtreeHasChanged):
3017         * rendering/RenderTextControl.h:
3018         * rendering/RenderTextControlMultiLine.cpp:
3019         (WebCore::RenderTextControlMultiLine::subtreeHasChanged):
3020         * rendering/RenderTextControlSingleLine.cpp:
3021         (WebCore::RenderTextControlSingleLine::subtreeHasChanged):
3022         * wml/WMLInputElement.cpp:
3023         (WebCore::WMLInputElement::WMLInputElement):
3024         (WebCore::WMLInputElement::defaultEventHandler):
3025         * wml/WMLInputElement.h:
3026         (WebCore::WMLInputElement::wasChangedSinceLastFormControlChangeEvent): Added.
3027         (WebCore::WMLInputElement::setChangedSinceLastFormControlChangeEvent): Added.
3028
3029 2011-03-04  Xianzhu Wang  <wangxianzhu@google.com>
3030
3031         Reviewed by Adam Barth.
3032
3033         Remove fake request loading of SVGImage to avoid MainResourceLoader
3034         leak. The frame->init() already ensures initialization of the
3035         document loader.
3036
3037         https://bugs.webkit.org/show_bug.cgi?id=55017
3038
3039         Test: fast/images/svg-image-leak-loader.html
3040
3041         * svg/graphics/SVGImage.cpp:
3042         (WebCore::SVGImage::dataChanged):
3043
3044 2011-03-04  Mike Reed  <reed@google.com>
3045
3046         Reviewed by Mihai Parparita.
3047
3048         [Chromium] fast/canvas/canvas-arc-360-winding.html fails on Linux and Windows
3049         https://bugs.webkit.org/show_bug.cgi?id=49477
3050
3051         * platform/graphics/skia/PathSkia.cpp:
3052         (WebCore::Path::addArc):
3053
3054 2011-03-04  Jia Pu  <jpu@apple.com>
3055
3056         Reviewed by Darin Adler.
3057
3058         On Mac, the bounding box sent to EditorClient::showCorrectionPanel() is incorrect when the correction occurs in an iframe.
3059         https://bugs.webkit.org/show_bug.cgi?id=55717
3060         <rdar://problem/9018127>
3061
3062         manual-test: manual-tests/platforms/mac/autocorrection/autocorrection-in-iframe.html
3063
3064         Previously, the bounding box passed into EditorClient::showCorrectionPanel() is in the frame's
3065         coordinate. This is incorrect when the correction occurs in an iframe. This patch added code
3066         to convert the bounding box to window coordinate using ScrollView::contentToWindow().
3067
3068         * dom/Range.cpp:
3069         (WebCore::Range::getBoundingClientRect):
3070         (WebCore::Range::boundingRect):
3071         * dom/Range.h:
3072         * editing/Editor.cpp:
3073         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
3074         (WebCore::Editor::correctionPanelTimerFired):
3075         (WebCore::Editor::windowRectForRange):
3076         * editing/Editor.h:
3077         * manual-tests/autocorrection/autocorrection-in-iframe.html: Added.
3078         * manual-tests/autocorrection/document-for-iframe-test.html: Added.
3079
3080 2011-03-04  Jia Pu  <jpu@apple.com>
3081
3082         Reviewed by Darin Adler.
3083
3084         Those checking in Editor::removeSpellAndCorrectionMarkersFromWordsToBeEdited() should be done with VisiblePosition::isNull().
3085         https://bugs.webkit.org/show_bug.cgi?id=55731
3086
3087         No new tests. There's no behavioral change.
3088
3089         This patch improved clarity and readability of Editor::removeSpellAndCorrectionMarkersFromWordsToBeEdited().
3090
3091         * editing/Editor.cpp:
3092         (WebCore::Editor::removeSpellAndCorrectionMarkersFromWordsToBeEdited):
3093
3094 2011-03-04  John Bauman  <jbauman@chromium.org>
3095
3096         Reviewed by Kenneth Russell.
3097
3098         [chromium] premultipliedAlpha WebGL context attribute is ignored.
3099         https://bugs.webkit.org/show_bug.cgi?id=55411
3100
3101         Update compositor to set the blending of each layer correctly.
3102
3103         Test: compositing/webgl/webgl-nonpremultiplied-blend.html
3104
3105         * platform/graphics/chromium/CanvasLayerChromium.cpp:
3106         (WebCore::CanvasLayerChromium::CanvasLayerChromium):
3107         (WebCore::CanvasLayerChromium::draw):
3108         * platform/graphics/chromium/CanvasLayerChromium.h:
3109         * platform/graphics/chromium/ContentLayerChromium.cpp:
3110         (WebCore::ContentLayerChromium::draw):
3111         * platform/graphics/chromium/LayerRendererChromium.cpp:
3112         (WebCore::LayerRendererChromium::drawLayers):
3113         * platform/graphics/chromium/WebGLLayerChromium.cpp:
3114         (WebCore::WebGLLayerChromium::setContext):
3115
3116 2011-03-04  Adam Barth  <abarth@webkit.org>
3117
3118         Reviewed by Eric Seidel.
3119
3120         WebCore GYP build should link with the correct frameworks
3121         https://bugs.webkit.org/show_bug.cgi?id=55804
3122
3123         * gyp/WebCore.gyp:
3124
3125 2011-03-04  Adam Barth  <abarth@webkit.org>
3126
3127         Reviewed by Eric Seidel.
3128
3129         WebCore GYP build should Check For Inappropriate Files in Framework
3130         https://bugs.webkit.org/show_bug.cgi?id=55806
3131
3132         * gyp/WebCore.gyp:
3133
3134 2011-03-04  Dimitri Glazkov  <dglazkov@chromium.org>
3135
3136         Reviewed by Adam Barth.
3137
3138         Add skeletal WebCore.gyp
3139         https://bugs.webkit.org/show_bug.cgi?id=55802
3140
3141         This doesn't yet build, but the basic structure is there.
3142
3143         * WebCore.gypi: Added headers and include directories variables.
3144         * gyp/WebCore.gyp: Added.
3145
3146 2011-03-04  Adam Barth  <abarth@webkit.org>
3147
3148         Reviewed by Dimitri Glazkov.
3149
3150         Remove unneeded round-trips through ../Source in the Chromium GYP build
3151         https://bugs.webkit.org/show_bug.cgi?id=55795
3152
3153         This is just cleanup work, but it was bugging me.
3154
3155         * WebCore.gyp/WebCore.gyp:
3156
3157 2011-03-04  Mike Reed  <reed@google.com>
3158
3159         Reviewed by James Robinson.
3160
3161         Option to use skia's native text drawing APIs when drawing text
3162         on Windows, rather than from outlines using drawPath(). This will
3163         only have a significant effect when the skia-gpu backend is enabled.
3164         https://bugs.webkit.org/show_bug.cgi?id=55609
3165
3166         No new tests. This is disabled by default. When enabled, it will draw
3167         essentially the same, but with slightly different antialiased edges, due
3168         to differences between the current scanconverter and GDI's font scaler.
3169         When enabled, we will have to recalibrate layouttest image results. 
3170
3171         * platform/graphics/skia/SkiaFontWin.cpp:
3172         (WebCore::skiaDrawText):
3173         (WebCore::setupPaintForFont):
3174         (WebCore::paintSkiaText):
3175
3176 2011-03-04  Adrienne Walker  <enne@google.com>
3177
3178         Reviewed by James Robinson.
3179
3180         [chromium] Fix texture stride issues on large content and image layers.
3181         https://bugs.webkit.org/show_bug.cgi?id=55679
3182
3183         This was an error caused during the refactoring in r80081.
3184
3185         Tests: LayoutTests/compositing/tiling/huge-layer-img.html
3186
3187         * platform/graphics/chromium/ContentLayerChromium.cpp:
3188         (WebCore::ContentLayerChromium::updateTexture):
3189         * platform/graphics/chromium/ImageLayerChromium.cpp:
3190         (WebCore::ImageLayerChromium::updateTextureIfNeeded):
3191
3192 2011-03-04  Sheriff Bot  <webkit.review.bot@gmail.com>
3193
3194         Unreviewed, rolling out r80379.
3195         http://trac.webkit.org/changeset/80379
3196         https://bugs.webkit.org/show_bug.cgi?id=55799
3197
3198         "Breaks leopard compile (implicit conversion)" (Requested by
3199         tonyg-cr on #webkit).
3200
3201         * css/CSSStyleSelector.cpp:
3202         (WebCore::convertToLength):
3203         (WebCore::CSSStyleSelector::applyProperty):
3204         (WebCore::CSSStyleSelector::createTransformOperations):
3205         * platform/Length.h:
3206         (WebCore::Length::Length):
3207         (WebCore::Length::operator==):
3208         (WebCore::Length::operator!=):
3209         (WebCore::Length::rawValue):
3210         (WebCore::Length::type):
3211         (WebCore::Length::quirk):
3212         (WebCore::Length::setValue):
3213         (WebCore::Length::setRawValue):
3214         (WebCore::Length::calcFloatValue):
3215         (WebCore::Length::isZero):
3216         (WebCore::Length::blend):
3217         * rendering/AutoTableLayout.cpp:
3218         (WebCore::AutoTableLayout::recalcColumn):
3219         (WebCore::AutoTableLayout::calcEffectiveLogicalWidth):
3220         * rendering/FixedTableLayout.cpp:
3221         (WebCore::FixedTableLayout::calcWidthArray):
3222
3223 2011-03-04  Jessie Berlin  <jberlin@apple.com>
3224
3225         Reviewed by Darin Adler.
3226
3227         WebKit2: Use CFNetwork Sessions API.
3228         https://bugs.webkit.org/show_bug.cgi?id=55435.
3229
3230         Add in the CFURLSTORAGESESSIONS guards that I incorrectly left out because the code was
3231         contained within guards that made USE(CFURLSTORAGESESSIONS) always be true.
3232
3233         * platform/network/cf/ResourceHandleCFNet.cpp:
3234         (WebCore::makeFinalRequest):
3235         (WebCore::ResourceHandle::willSendRequest):
3236         * platform/network/cf/ResourceRequestCFNet.cpp:
3237         * platform/network/mac/ResourceHandleMac.mm:
3238         (WebCore::ResourceHandle::createNSURLConnection):
3239         (WebCore::ResourceHandle::willSendRequest):
3240         * platform/network/mac/ResourceRequestMac.mm:
3241
3242 2011-03-04  Yuqiang Xian  <yuqiang.xian@intel.com>
3243
3244         Reviewed by Darin Adler.
3245
3246         improve layout performance by reducing the traversal time of the floating objects
3247         https://bugs.webkit.org/show_bug.cgi?id=55440
3248
3249         We observered large overhead on traversing the floating objects list
3250         in logicalLeftOffsetForLine() and logicalRightOffsetForLine() especially
3251         when the list becomes enormous, for example in the default 30x30 maze test
3252         from http://ie.microsoft.com/testdrive/Performance/MazeSolver/Default.html
3253         there're >3700 floating objects. When placing a new floating object the
3254         entire list (from begin to end) is traversed for multiple times.
3255         There's a low hanging fruit to reduce the chances to do the traversal
3256         which is especially applicable in logicalLeftOffsetForLine and logicalRightOffsetForLine.
3257         As the two routines either cares about FloatLeft objects or FloatRight objects only,
3258         if we know there's no corresponding type floating objects in the list
3259         we can avoid the traversal actually. One thing we could do is to record
3260         the number of FloatLeft objects and the number of FloatRight objects and
3261         add a check before doing the traversal. This can reduce the time by 45%
3262         to resolve the 30x30 Maze measured on N470 Netbook MeeGo using latest
3263         Chromium browser 11 (from 503s to 269s).
3264
3265         No new tests, relying on existing layout tests.
3266
3267         * rendering/RenderBlock.cpp:
3268         (WebCore::RenderBlock::~RenderBlock):
3269         (WebCore::RenderBlock::addOverflowFromFloats):
3270         (WebCore::RenderBlock::repaintOverhangingFloats):
3271         (WebCore::RenderBlock::paintFloats):
3272         (WebCore::RenderBlock::selectionGaps):
3273         (WebCore::RenderBlock::insertFloatingObject):
3274         (WebCore::RenderBlock::removeFloatingObject):
3275         (WebCore::RenderBlock::removeFloatingObjectsBelow):
3276         (WebCore::RenderBlock::positionNewFloats):
3277         (WebCore::RenderBlock::positionNewFloatOnLine):
3278         (WebCore::RenderBlock::logicalLeftOffsetForLine):
3279         (WebCore::RenderBlock::logicalRightOffsetForLine):
3280         (WebCore::RenderBlock::nextFloatLogicalBottomBelow):
3281         (WebCore::RenderBlock::lowestFloatLogicalBottom):
3282         (WebCore::RenderBlock::clearFloats):
3283         (WebCore::RenderBlock::addOverhangingFloats):
3284         (WebCore::RenderBlock::addIntrudingFloats):
3285         (WebCore::RenderBlock::containsFloat):
3286         (WebCore::RenderBlock::hitTestFloats):
3287         (WebCore::RenderBlock::adjustForBorderFit):
3288         (WebCore::RenderBlock::FloatingObjects::clear):
3289         (WebCore::RenderBlock::FloatingObjects::increaseObjectsCount):
3290         (WebCore::RenderBlock::FloatingObjects::decreaseObjectsCount):
3291         * rendering/RenderBlock.h:
3292         (WebCore::RenderBlock::containsFloats):
3293         (WebCore::RenderBlock::FloatingObjects::FloatingObjects):
3294         (WebCore::RenderBlock::FloatingObjects::hasLeftObjects):
3295         (WebCore::RenderBlock::FloatingObjects::hasRightObjects):
3296         (WebCore::RenderBlock::FloatingObjects::set):
3297         * rendering/RenderBlockLineLayout.cpp:
3298         (WebCore::RenderBlock::layoutInlineChildren):
3299         (WebCore::RenderBlock::matchedEndLine):
3300
3301 2011-03-04  Rik Cabanier  <cabanier@gmail.com>
3302
3303         Reviewed by David Hyatt.
3304
3305         Fix that allows fixed length values to be floating point
3306         https://bugs.webkit.org/show_bug.cgi?id=52699
3307
3308         * WebCore.xcodeproj/project.pbxproj:
3309         * css/CSSStyleSelector.cpp:
3310         (WebCore::convertToLength):
3311         (WebCore::convertToIntLength):
3312         (WebCore::convertToFloatLength):
3313         (WebCore::CSSStyleSelector::applyProperty):
3314         (WebCore::CSSStyleSelector::createTransformOperations):
3315         * platform/Length.h:
3316         (WebCore::Length::Length):
3317         (WebCore::Length::operator==):
3318         (WebCore::Length::operator!=):
3319         (WebCore::Length::rawValue):
3320         (WebCore::Length::type):
3321         (WebCore::Length::quirk):
3322         (WebCore::Length::setValue):
3323         (WebCore::Length::calcFloatValue):
3324         (WebCore::Length::isZero):
3325         (WebCore::Length::blend):
3326         (WebCore::Length::getIntValue):
3327         (WebCore::Length::getFloatValue):
3328         * rendering/AutoTableLayout.cpp:
3329         (WebCore::AutoTableLayout::recalcColumn):
3330         (WebCore::AutoTableLayout::calcEffectiveLogicalWidth):
3331         * rendering/FixedTableLayout.cpp:
3332         (WebCore::FixedTableLayout::calcWidthArray):
3333
3334 2011-03-04  Steve Falkenburg  <sfalken@apple.com>
3335
3336         Reviewed by Jon Honeycutt.
3337
3338         Adopt VersionStamper tool for Windows WebKit DLLs
3339         https://bugs.webkit.org/show_bug.cgi?id=55784
3340         
3341         We now use a tool to stamp the version number onto the Apple WebKit DLLs
3342         during the post-build step.
3343
3344         * WebCore.vcproj/QTMovieWin.rc: Removed.
3345         * WebCore.vcproj/QTMovieWin.vcproj:
3346         * WebCore.vcproj/QTMovieWinPostBuild.cmd: Stamp version with VersionStamper.
3347         * WebCore.vcproj/QTMovieWinPreBuild.cmd: Don't run auto-version.sh. We don't use autoversion.h in this project.
3348         * WebCore.vcproj/WebCoreMediaQT.vsprops: Remove unnecessary include paths for resource files.
3349
3350 2011-03-04  Cosmin Truta  <ctruta@chromium.org>
3351
3352         Reviewed by Adam Barth.
3353
3354         Clarify comment about potential memory leak in SVGImage
3355         https://bugs.webkit.org/show_bug.cgi?id=55362
3356
3357         No functionality change. No new tests.
3358
3359         * svg/graphics/SVGImage.cpp:
3360         (WebCore::SVGImage::dataChanged):
3361
3362 2011-03-04  Jessie Berlin  <jberlin@apple.com>
3363
3364         Reviewed by Maciej Stachowiak.
3365
3366         WebKit2: Use CFNetwork Sessions API.
3367         https://bugs.webkit.org/show_bug.cgi?id=55435.
3368
3369         When Private Browsing is enabled, get the cached url response from the cache associated with
3370         the Private Browsing Storage Session.
3371
3372         * WebCore.exp.in:
3373         Export the symbol for ResourceHandle::privateBrowsingStorageSession.
3374
3375 2011-03-04  Steve Block  <steveblock@google.com>
3376
3377         Reviewed by Jeremy Orlow.
3378
3379         JSC and V8 versions of Java bridge should share JobjectWrapper
3380         https://bugs.webkit.org/show_bug.cgi?id=55763
3381
3382         No new tests, refactoring only.
3383
3384         * Android.jscbindings.mk:
3385         * Android.v8bindings.mk:
3386         * WebCore.gypi:
3387         * WebCore.order:
3388         * WebCore.xcodeproj/project.pbxproj:
3389         * bridge/jni/JobjectWrapper.cpp:
3390         (JobjectWrapper::JobjectWrapper):
3391         (JobjectWrapper::~JobjectWrapper):
3392         * bridge/jni/JobjectWrapper.h:
3393         (JSC::Bindings::JobjectWrapper::instance):
3394         (JSC::Bindings::JobjectWrapper::setInstance):
3395         (JSC::Bindings::JobjectWrapper::ref):
3396         (JSC::Bindings::JobjectWrapper::deref):
3397         * bridge/jni/jsc/JNIBridgeJSC.cpp:
3398         (JavaField::JavaField):
3399         (JavaArray::JavaArray):
3400         * bridge/jni/jsc/JNIBridgeJSC.h:
3401         * bridge/jni/jsc/JavaInstanceJSC.cpp:
3402         (JavaInstance::JavaInstance):
3403         * bridge/jni/jsc/JavaInstanceJSC.h:
3404
3405 2011-03-04  Patrick Gansterer  <paroga@webkit.org>
3406
3407         Reviewed by Nikolas Zimmermann.
3408
3409         Move shared code into SVGStyledTransformableElement::svgAttributeChanged
3410         https://bugs.webkit.org/show_bug.cgi?id=55771
3411
3412         All sub classes of SVGStyledTransformableElement request a relayout
3413         the same way. So move that code into the common base class.
3414
3415         * svg/SVGCircleElement.cpp:
3416         (WebCore::SVGCircleElement::svgAttributeChanged):
3417         * svg/SVGEllipseElement.cpp:
3418         (WebCore::SVGEllipseElement::svgAttributeChanged):
3419         * svg/SVGForeignObjectElement.cpp:
3420         (WebCore::SVGForeignObjectElement::svgAttributeChanged):
3421         * svg/SVGGElement.cpp:
3422         (WebCore::SVGGElement::svgAttributeChanged):
3423         * svg/SVGImageElement.cpp:
3424         (WebCore::SVGImageElement::svgAttributeChanged):
3425         * svg/SVGLineElement.cpp:
3426         (WebCore::SVGLineElement::svgAttributeChanged):
3427         * svg/SVGPathElement.cpp:
3428         (WebCore::SVGPathElement::svgAttributeChanged):
3429         * svg/SVGPolyElement.cpp:
3430         (WebCore::SVGPolyElement::svgAttributeChanged):
3431         * svg/SVGRectElement.cpp:
3432         (WebCore::SVGRectElement::svgAttributeChanged):
3433         * svg/SVGStyledTransformableElement.cpp:
3434         (WebCore::SVGStyledTransformableElement::svgAttributeChanged):
3435         * svg/SVGStyledTransformableElement.h:
3436         * svg/SVGUseElement.cpp:
3437         (WebCore::SVGUseElement::svgAttributeChanged):
3438
3439 2011-03-03  John Abd-El-Malek  <jam@chromium.org>
3440
3441         Reviewed by Dimitri Glazkov.
3442
3443         [chromium] Get rid of IsContentFiltered flags since they&apos;re not used anymore
3444         https://bugs.webkit.org/show_bug.cgi?id=55748
3445
3446         * platform/network/chromium/ResourceResponse.cpp:
3447         (WebCore::ResourceResponse::doPlatformCopyData):
3448         (WebCore::ResourceResponse::doPlatformAdopt):
3449         * platform/network/chromium/ResourceResponse.h:
3450         (WebCore::ResourceResponse::ResourceResponse):
3451
3452 2011-03-03  Timothy Hatcher  <timothy@apple.com>
3453
3454         Export SerializedScriptValue::create(JSC::ExecState* exec, JSC::JSValue value).
3455
3456         Reviewed by Darin Adler.
3457
3458         * WebCore.exp.in: Added __ZN7WebCore21SerializedScriptValue6createEPN3JSC9ExecStateENS1_7JSValueE.
3459
3460 2011-03-04  Pavel Podivilov  <podivilov@chromium.org>
3461
3462         Reviewed by Yury Semikhatsky.
3463
3464         Web Inspector: extract all code that depends on source mapping from SourceFrame.
3465         https://bugs.webkit.org/show_bug.cgi?id=55464
3466
3467         Extract all dependencies on DebuggerModel and ScriptsPanel to a delegate class
3468         to encapsulate source mapping aspects from SourceFrame.
3469
3470         * inspector/front-end/ResourceView.js:
3471         (WebInspector.ResourceView.createResourceView):
3472         (WebInspector.SourceFrameDelegateForResourcesPanel):
3473         (WebInspector.SourceFrameDelegateForResourcesPanel.prototype.requestContent):
3474         * inspector/front-end/ScriptsPanel.js:
3475         (WebInspector.ScriptsPanel.prototype._createSourceFrame):
3476         (WebInspector.SourceFrameDelegateForScriptsPanel):
3477         * inspector/front-end/SourceFrame.js:
3478         (WebInspector.SourceFrame):
3479         (WebInspector.SourceFrame.prototype.show):
3480         (WebInspector.SourceFrame.prototype._createTextViewer):
3481         (WebInspector.SourceFrame.prototype._contextMenu.addConditionalBreakpoint.didEditBreakpointCondition):
3482         (WebInspector.SourceFrame.prototype._contextMenu.addConditionalBreakpoint):
3483         (WebInspector.SourceFrame.prototype._contextMenu.else.editBreakpointCondition.didEditBreakpointCondition):
3484         (WebInspector.SourceFrame.prototype._contextMenu.else.editBreakpointCondition):
3485         (WebInspector.SourceFrame.prototype._contextMenu.else.setBreakpointEnabled):
3486         (WebInspector.SourceFrame.prototype._contextMenu):
3487         (WebInspector.SourceFrame.prototype._mouseDown):
3488         (WebInspector.SourceFrame.prototype._mouseMove):
3489         (WebInspector.SourceFrame.prototype._hidePopup):
3490         (WebInspector.SourceFrame.prototype._mouseHover):
3491         (WebInspector.SourceFrame.prototype._showPopup.showObjectPopup):
3492         (WebInspector.SourceFrame.prototype._showPopup):
3493         (WebInspector.SourceFrame.prototype._doubleClick):
3494         (WebInspector.SourceFrame.prototype._didEditLine):
3495         (WebInspector.SourceFrameDelegate):
3496         (WebInspector.SourceFrameDelegate.prototype.requestContent):
3497         (WebInspector.SourceFrameDelegate.prototype.debuggingSupported):
3498         (WebInspector.SourceFrameDelegate.prototype.setBreakpoint):
3499         (WebInspector.SourceFrameDelegate.prototype.removeBreakpoint):
3500         (WebInspector.SourceFrameDelegate.prototype.updateBreakpoint):
3501         (WebInspector.SourceFrameDelegate.prototype.findBreakpoint):
3502         (WebInspector.SourceFrameDelegate.prototype.continueToLine):
3503         (WebInspector.SourceFrameDelegate.prototype.canEditScriptSource):
3504         (WebInspector.SourceFrameDelegate.prototype.editScriptSource):
3505         (WebInspector.SourceFrameDelegate.prototype.debuggerPaused):
3506         (WebInspector.SourceFrameDelegate.prototype.evaluate):
3507         (WebInspector.SourceFrameDelegate.prototype.releaseEvaluationResult):
3508
3509 2011-03-04  Andrey Kosyakov  <caseq@chromium.org>
3510
3511         Reviewed by Pavel Feldman.
3512