Standardize WinCairo conditionalized code under PLATFORM macro.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-07-12  Brent Fulgham  <bfulgham@webkit.org>
2
3         Standardize WinCairo conditionalized code under PLATFORM macro.
4         https://bugs.webkit.org/show_bug.cgi?id=64377
5
6         Reviewed by Maciej Stachowiak.
7
8         Update compile-time conditions that had previously used #ifdef
9         of WIN_CAIRO to consistently use PLATFORM(WIN_CAIRO).
10
11         * WebCore.vcproj/WebCoreCairo.vsprops: Remove redundant declaration
12           of WIN_CAIRO.
13         * WebCore.vcproj/WebCoreDebugCairoCFLite.vsprops: Update to use
14           the existing WinCairo.vsprops file.
15         * WebCorePrefix.h: Update for new WTF_PLATFORM_WIN_CAIRO define.
16         * config.h: Update to use PLATFORM(WIN_CAIRO).
17
18 2011-07-13  Alexandru Chiculita  <achicu@adobe.com>
19
20         [CSS Exclusions] Fix for comment #23 on wrap-shape parsing bug 61726
21         https://bugs.webkit.org/show_bug.cgi?id=64464
22
23         Reviewed by Tony Chang.
24
25         No new tests needed.
26
27         * css/CSSParser.cpp:
28         (WebCore::CSSParser::parseWrapShapeRect): Removed the "valid" local.
29         (WebCore::CSSParser::parseWrapShapeCircle): Removed the "valid" local.
30         (WebCore::CSSParser::parseWrapShapeEllipse): Removed the "valid" local.
31         * css/CSSPrimitiveValue.cpp:
32         * css/CSSWrapShapes.h:
33         (WebCore::CSSWrapShapePolygon::getXAt): Replaced bit shift with multiplication.
34         (WebCore::CSSWrapShapePolygon::getYAt): Replaced bit shift with multiplication.
35         * rendering/style/RenderStyle.cpp:
36         * rendering/style/StyleRareNonInheritedData.h:
37
38 2011-07-13  Abhishek Arya  <inferno@chromium.org>
39
40         Reviewed by Adam Barth.
41
42         Issue with Frame lifetime due to deletion in beforeload event.
43         https://bugs.webkit.org/show_bug.cgi?id=64457
44
45         Copy the Frame protector higher in the stack from loadWithDocumentLoader
46         to loadFrameRequest since any of loadPostRequest or loadURL can call
47         loadWithDocumentLoader, thereby dispatching the beforeload event and
48         blowing away the frame. This deleted frame will be later accessed in
49         the loadFrameRequest function causing a crash.       
50  
51         Test: fast/events/form-iframe-target-before-load-crash2.html
52
53         * loader/FrameLoader.cpp:
54         (WebCore::FrameLoader::loadFrameRequest):
55         (WebCore::FrameLoader::loadWithDocumentLoader):
56
57 2011-07-13  Mihnea Ovidenie  <mihnea@adobe.com>
58
59         [CSSRegions]content:-webkit-from-flow not applied correctly
60         https://bugs.webkit.org/show_bug.cgi?id=64438
61
62         Reviewed by Tony Chang.
63
64         Forgot to modify getStringValue(), i was modifying only getStringValue(ExceptionCode&).
65
66         Test: fast/regions/content-webkit-from-flow-parsing.html (existing).
67
68         * css/CSSPrimitiveValue.cpp:
69         (WebCore::CSSPrimitiveValue::getStringValue):
70
71 2011-07-12  Ryosuke Niwa  <rniwa@webkit.org>
72
73         Don't reuse the last InsertTextCommand
74         https://bugs.webkit.org/show_bug.cgi?id=64416
75
76         Reviewed by Justin Garcia.
77
78         This patch makes the interface of InsertTextCommand less foreign. It now takes arguments in
79         its constructor and executes the command in doApply like other edit commands.
80
81         * editing/CompositeEditCommand.cpp:
82         (WebCore::CompositeEditCommand::applyCommandToComposite): Added.
83         * editing/CompositeEditCommand.h:
84         * editing/InsertTextCommand.cpp:
85         (WebCore::InsertTextCommand::InsertTextCommand): Takes arguments input used to take.
86         (WebCore::InsertTextCommand::doApply): Renamed from input.
87         * editing/InsertTextCommand.h:
88         (WebCore::InsertTextCommand::create): Takes arguments input used to take.
89         * editing/TypingCommand.cpp:
90         (WebCore::TypingCommand::insertTextRunWithoutNewlines): Creates InsertTextCommand.
91
92 2011-07-12  Dmitry Lomov  <dslomov@google.com>
93
94         https://bugs.webkit.org/show_bug.cgi?id=63041
95         [Chromium][V8] Make DOMDataStore per-isolate
96         This patch:
97          - makes DOMData class an utility class with static members only
98          - adds an isolate-specific DOMDataStore in V8BindingPerIsolateData.
99         Dromaeo benchmarks are not affected.
100
101         Reviewed by Adam Barth.
102
103         * bindings/v8/DOMData.cpp:
104         (WebCore::getDefaultStore):
105         (WebCore::DOMData::getCurrentStore):
106         * bindings/v8/DOMData.h:
107         * bindings/v8/DOMDataStore.cpp:
108         (WebCore::DOMDataStore::DOMDataStore):
109         (WebCore::DOMDataStore::allStores):
110         * bindings/v8/DOMDataStore.h:
111         * bindings/v8/ScopedDOMDataStore.cpp:
112         (WebCore::ScopedDOMDataStore::ScopedDOMDataStore):
113         * bindings/v8/ScopedDOMDataStore.h:
114         * bindings/v8/StaticDOMDataStore.cpp:
115         (WebCore::StaticDOMDataStore::StaticDOMDataStore):
116         * bindings/v8/StaticDOMDataStore.h:
117         * bindings/v8/V8Binding.h:
118         (WebCore::V8BindingPerIsolateData::allStores):
119         (WebCore::V8BindingPerIsolateData::getDOMDataStore):
120         (WebCore::V8BindingPerIsolateData::setDOMDataStore):
121         * bindings/v8/V8Binding.cpp:
122         (WebCore::V8BindingPerIsolateData::V8BindingPerIsolateData):
123         * bindings/v8/V8DOMMap.cpp:
124         (WebCore::DOMDataStoreHandle::DOMDataStoreHandle):
125         (WebCore::getDOMDataStore):
126         (WebCore::enableFasterDOMStoreAccess):
127
128 2011-07-12  Simon Fraser  <simon.fraser@apple.com>
129
130         Rename compositing-related updateContentsScale() methods
131         https://bugs.webkit.org/show_bug.cgi?id=64430
132
133         Reviewed by Joseph Pecoraro.
134
135         Rename updateContentsScale() to something less presumptuous; layers may choose
136         to do something other than update their contents scale when the page scale factor
137         changes. pageScaleFactorChanged() is a better name.
138
139         * page/Frame.cpp:
140         (WebCore::Frame::pageScaleFactorChanged):
141         (WebCore::Frame::scalePage):
142         * page/Frame.h:
143         * rendering/RenderLayer.cpp:
144         (WebCore::RenderLayer::pageScaleFactorChanged):
145         * rendering/RenderLayer.h:
146         * rendering/RenderLayerBacking.cpp:
147         (WebCore::RenderLayerBacking::pageScaleFactorChanged):
148         * rendering/RenderLayerBacking.h:
149         * rendering/RenderLayerCompositor.cpp:
150         (WebCore::RenderLayerCompositor::pageScaleFactorChanged):
151         * rendering/RenderLayerCompositor.h:
152
153 2011-07-13  Pierre Rossi  <pierre.rossi@gmail.com>
154
155         Fix compile for QRawFont.
156
157         https://bugs.webkit.org/show_bug.cgi?id=64453
158
159         Reviewed by Andreas Kling.
160
161         * platform/graphics/GraphicsContext.h:
162         * platform/graphics/qt/FontQt.cpp:
163         (WebCore::Font::drawGlyphs):
164
165 2011-07-13  John Knottenbelt  <jknotten@chromium.org>
166
167         Reference Geolocation object from GeoNotifier and Geolocation::setIsAllowed.
168         https://bugs.webkit.org/show_bug.cgi?id=64363
169
170         Reviewed by Tony Gentilcore.
171
172         Test: fast/dom/Geolocation/remove-remote-context-in-error-callback-crash.html
173
174         * page/Geolocation.cpp:
175         (WebCore::Geolocation::setIsAllowed):
176         * page/Geolocation.h:
177
178 2011-07-13  Vsevolod Vlasov  <vsevik@chromium.org>
179
180         Web Inspector: Network panel search needs each resource to have unique identifier.
181         https://bugs.webkit.org/show_bug.cgi?id=64287
182
183         Reviewed by Pavel Feldman.
184
185         * inspector/front-end/NetworkManager.js:
186         (WebInspector.NetworkManager.prototype.requestContent):
187         (WebInspector.NetworkDispatcher):
188         (WebInspector.NetworkDispatcher.prototype.requestWillBeSent):
189         (WebInspector.NetworkDispatcher.prototype.resourceLoadedFromMemoryCache):
190         (WebInspector.NetworkDispatcher.prototype._appendRedirect):
191         * inspector/front-end/NetworkPanel.js:
192         (WebInspector.NetworkPanel.prototype._appendResource):
193         (WebInspector.NetworkPanel.prototype._frameNavigated):
194         (WebInspector.NetworkPanel.prototype._updateSearchMatchedListAfterResourceIdentifierChanged):
195
196 2011-07-13  Alexandru Chiculita  <achicu@adobe.com>
197
198         Bridge RenderBoxModelObject::calculateBackgroundImageGeometry parameters into a class
199         https://bugs.webkit.org/show_bug.cgi?id=63987
200
201         Reviewed by Hajime Morita.
202
203         Change doesn't add new functionality. No test needed.
204
205         * rendering/RenderBox.cpp:
206         (WebCore::RenderBox::maskClipRect):
207         (WebCore::RenderBox::repaintLayerRectsForImage):
208         * rendering/RenderBoxModelObject.cpp:
209         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
210         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setNoRepeatX):
211         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setNoRepeatY):
212         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::useFixedAttachment):
213         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::clip):
214         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::relativePhase):
215         (WebCore::RenderBoxModelObject::calculateBackgroundImageGeometry):
216         * rendering/RenderBoxModelObject.h:
217         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::destOrigin):
218         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setDestOrigin):
219         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::destRect):
220         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setDestRect):
221         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::phase):
222         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setPhase):
223         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::tileSize):
224         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setTileSize):
225         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setPhaseX):
226         (WebCore::RenderBoxModelObject::BackgroundImageGeometry::setPhaseY):
227
228 2011-07-13  MORITA Hajime  <morrita@google.com>
229
230         Refactoring: Ignored ExceptionCode value should be less annoying.
231         https://bugs.webkit.org/show_bug.cgi?id=63688
232
233         - Introduced ExceptionCodePlaceholder class for the default parameter of ExceptionCode.
234         - Introduced ASSERT_NO_EXCEPTION to check ExceptionCode not set to non-zero after the call.
235         - Adopted ASSERT_NO_EXCEPTION in Range.cpp
236
237         No new tests. No behaviour change.
238
239         Reviewed by Darin Adler.
240
241         * GNUmakefile.list.am:
242         * WebCore.gypi:
243         * WebCore.xcodeproj/project.pbxproj:
244         * dom/ExceptionCodePlaceholder.h: Added.
245         (WebCore::ExceptionCodePlaceholder::ExceptionCodePlaceholder):
246         (WebCore::ExceptionCodePlaceholder::operator ExceptionCode& ):
247         (WebCore::IgnorableExceptionCode::IgnorableExceptionCode):
248         (WebCore::CheckedExceptionCode::CheckedExceptionCode):
249         (WebCore::CheckedExceptionCode::~CheckedExceptionCode):
250         * dom/Range.cpp:
251         (WebCore::Range::Range):
252         (WebCore::Range::editingStartPosition):
253         * dom/Range.h:        
254
255 2011-07-13  Nikolas Zimmermann  <nzimmermann@rim.com>
256
257         Regression: OOB read in svg text run
258         https://bugs.webkit.org/show_bug.cgi?id=63627
259
260         Not reviewed.
261
262         Fixed last minute typo leading to assertions.
263
264         * rendering/InlineTextBox.cpp:
265         (WebCore::InlineTextBox::paintSelection):
266
267 2011-07-12  Andrey Kosyakov  <caseq@chromium.org>
268
269         Web Inspector: factor NetworkLogView out of Network panel
270         https://bugs.webkit.org/show_bug.cgi?id=64366
271
272         Reviewed by Pavel Feldman.
273
274         * inspector/front-end/NetworkPanel.js:
275         (WebInspector.NetworkLogView):
276         (WebInspector.NetworkLogView.prototype.get useLargeRows):
277         (WebInspector.NetworkLogView.prototype.set allowPopover):
278         (WebInspector.NetworkLogView.prototype.elementsToRestoreScrollPositionsFor):
279         (WebInspector.NetworkLogView.prototype.resize):
280         (WebInspector.NetworkLogView.prototype._createTable):
281         (WebInspector.NetworkLogView.prototype.show):
282         (WebInspector.NetworkLogView.prototype.hide):
283         (WebInspector.NetworkLogView.prototype._reset):
284         (WebInspector.NetworkLogView.prototype.switchToDetailedView):
285         (WebInspector.NetworkLogView.prototype.switchToBriefView):
286         (WebInspector.NetworkLogView.prototype.get _setLargerResources):
287         (WebInspector.NetworkLogView.prototype._getPopoverAnchor):
288         (WebInspector.NetworkPanel):
289         (WebInspector.NetworkPanel.prototype.get toolbarItemLabel):
290         (WebInspector.NetworkPanel.prototype.get statusBarItems):
291         (WebInspector.NetworkPanel.prototype.elementsToRestoreScrollPositionsFor):
292         (WebInspector.NetworkPanel.prototype.resize):
293         (WebInspector.NetworkPanel.prototype._reset):
294         (WebInspector.NetworkPanel.prototype.updateSidebarWidth):
295         (WebInspector.NetworkPanel.prototype.updateMainViewWidth):
296         (WebInspector.NetworkPanel.prototype.handleShortcut):
297         (WebInspector.NetworkPanel.prototype.show):
298         (WebInspector.NetworkPanel.prototype.hide):
299         (WebInspector.NetworkPanel.prototype.get resources):
300         (WebInspector.NetworkPanel.prototype.resourceById):
301         (WebInspector.NetworkPanel.prototype.canShowAnchorLocation):
302         (WebInspector.NetworkPanel.prototype.showAnchorLocation):
303         (WebInspector.NetworkPanel.prototype._onViewCleared):
304         (WebInspector.NetworkPanel.prototype._onRowSizeChanged):
305         (WebInspector.NetworkPanel.prototype._onResourceSelected):
306         (WebInspector.NetworkPanel.prototype._showResource):
307         (WebInspector.NetworkPanel.prototype._closeVisibleResource):
308         (WebInspector.NetworkPanel.prototype._toggleGridMode):
309         (WebInspector.NetworkPanel.prototype._toggleViewingResourceMode):
310         (WebInspector.NetworkPanel.prototype.performSearch):
311         (WebInspector.NetworkPanel.prototype.jumpToPreviousSearchResult):
312         (WebInspector.NetworkPanel.prototype.jumpToNextSearchResult):
313         (WebInspector.NetworkPanel.prototype.searchCanceled):
314         (WebInspector.NetworkDataGridNode):
315         (WebInspector.NetworkDataGridNode.prototype.isFilteredOut):
316         (WebInspector.NetworkDataGridNode.prototype.select):
317         (WebInspector.NetworkDataGridNode.prototype.get selectable):
318
319 2011-07-13  Sheriff Bot  <webkit.review.bot@gmail.com>
320
321         Unreviewed, rolling out r90634.
322         http://trac.webkit.org/changeset/90634
323         https://bugs.webkit.org/show_bug.cgi?id=64448
324
325         Qt HTTP Pipelining is not robust enough to be used in that
326         generic way. (Requested by benjaminp on #webkit).
327
328         * platform/network/qt/ResourceRequestQt.cpp:
329         (WebCore::ResourceRequest::toNetworkRequest):
330
331 2011-07-13  Nikolas Zimmermann  <nzimmermann@rim.com>
332
333         Regression: OOB read in svg text run
334         https://bugs.webkit.org/show_bug.cgi?id=63627
335
336         Reviewed by Zoltan Herczeg.
337
338         A TextRun is constructed for a portion of a string [a,b] whose original length is c (0 < a < b < c).
339         The TextRun charactersLength variable stores the length of the remaining text from (b..c) in order
340         to support ligatures in SVG Fonts. Example: <text>ffl</text>. When measuring the advance from char 0
341         to char 1 the whole 'ffl' text must be passed to the SVG glyph selection code, as the SVG Font may
342         define a single glyph for the characters 'ffl' thus leading to a single character long text
343         pointing to the ffl ligature, not three individual 'f' / 'f' / 'l' characters anymore.
344
345         constructTextRun(..const UChar*, int length, ..) did not correctly calculate the maximum length (b..c).
346         The passed in UChar buffer starts at eg. textRenderer->characters() + start(), and following condition
347         holds true for 'length': start() + length <= textRenderer->textLength() (which denotes the maximum length
348         of the textRenderer->characters() buffer). We have to keep track of the start() offset, so that we
349         can calculate the charactersLength for the TextRun correctly: textRenderer->textLength() - start().
350
351         There are also other cases like RenderCombinedText and/or the presence of hyphens that were incorrectly
352         tracked. Only InlineTextBox had to be fixed, the other callsites in eg. RenderBlockLineLayout already
353         computed the maximum length correctly - I assured this by valgrind runs on all SVG Font tests.
354
355         * rendering/InlineTextBox.cpp:
356         (WebCore::InlineTextBox::paint):
357         (WebCore::InlineTextBox::paintSelection):
358         (WebCore::InlineTextBox::constructTextRun): Add maximumLength parameter to constructTextRun.
359         * rendering/InlineTextBox.h: Ditto.
360
361 2011-07-12  Antti Koivisto  <antti@apple.com>
362
363         didFirstVisuallyNonEmptyLayout dispatched too early
364         https://bugs.webkit.org/show_bug.cgi?id=64412
365
366         Reviewed by Darin Adler and Sam Weinig.
367
368         Improve the mechanism that dispatches didFirstVisuallyNonEmptyLayout
369
370         - Wait until a threshold of characters and pixels has been exceeded before dispatching.
371         - Wait until stylesheets are loaded (painting is disabled in this case).
372
373         * page/FrameView.cpp:
374         (WebCore::FrameView::reset):
375         (WebCore::FrameView::performPostLayoutTasks):
376         * page/FrameView.h:
377         (WebCore::FrameView::incrementVisuallyNonEmptyCharacterCount):
378         (WebCore::FrameView::incrementVisuallyNonEmptyPixelCount):
379         * rendering/RenderImage.cpp:
380         (WebCore::RenderImage::RenderImage):
381         (WebCore::RenderImage::imageChanged):
382         * rendering/RenderImage.h:
383         * rendering/RenderText.cpp:
384         (WebCore::RenderText::RenderText):
385
386 2011-07-12  MORITA Hajime  <morrita@google.com>
387
388         [Refactoring][ShadowContentElement] Forwarded node list should be a linked-list.
389         https://bugs.webkit.org/show_bug.cgi?id=64252
390
391         Reviewed by Dimitri Glazkov.
392
393         Introduced ShadowInclusionList and ShadowInclusion for maintaining
394         forwarded content children. ShadowInclusion is doubly-linked list.
395         ShadowContentElement::m_inclusions is replaced by ShadowInclusionList.
396         
397         This change is a prepration for bug 64251, which will introduce
398         forwarded-children to content-element table.
399         
400         No new tests. No behavioral change.
401
402         * dom/NodeRenderingContext.cpp:
403         (WebCore::nextRendererOf):
404         (WebCore::previousRendererOf):
405         (WebCore::firstRendererOf):
406         (WebCore::lastRendererOf):
407         * dom/ShadowContentElement.cpp:
408         (WebCore::ShadowInclusion::append):
409         (WebCore::ShadowInclusion::unlink):
410         (WebCore::ShadowInclusionList::ShadowInclusionList):
411         (WebCore::ShadowInclusionList::~ShadowInclusionList):
412         (WebCore::ShadowInclusionList::find):
413         (WebCore::ShadowInclusionList::clear):
414         (WebCore::ShadowInclusionList::append):
415         (WebCore::ShadowContentElement::attach):
416         * dom/ShadowContentElement.h:
417         (WebCore::ShadowInclusion::includer):
418         (WebCore::ShadowInclusion::content):
419         (WebCore::ShadowInclusion::next):
420         (WebCore::ShadowInclusion::previous):
421         (WebCore::ShadowInclusion::ShadowInclusion):
422         (WebCore::ShadowInclusion::create):
423         (WebCore::ShadowInclusionList::first):
424         (WebCore::ShadowInclusionList::last):
425         (WebCore::ShadowInclusionList::isEmpty):
426         (WebCore::ShadowInclusionList::append):
427         (WebCore::ShadowContentElement::inclusions):
428         * dom/ShadowContentSelector.cpp:
429         (WebCore::ShadowContentSelector::selectInclusion):
430         * dom/ShadowContentSelector.h:
431
432 2011-07-12  David Reveman  <reveman@chromium.org>
433
434         [Chromium] Use nearest filter method with pixel aligned transforms.
435         https://bugs.webkit.org/show_bug.cgi?id=64338
436
437         Reviewed by James Robinson.
438
439         Check for integer translation and use nearest texture filter when
440         possible to avoid filter precisions problems at the layer edges.
441
442         Test: compositing/iframes/nested-iframe-scrolling.html (existing)
443
444         * platform/graphics/chromium/LayerTilerChromium.cpp:
445         (WebCore::LayerTilerChromium::drawTiles):
446         * platform/graphics/transforms/TransformationMatrix.cpp:
447         (WebCore::TransformationMatrix::isIntegerTranslation):
448         * platform/graphics/transforms/TransformationMatrix.h:
449
450 2011-07-12  David Reveman  <reveman@chromium.org>
451
452         Removed unnecessary function parameters from TilingData::textureOffset.
453         https://bugs.webkit.org/show_bug.cgi?id=64245
454
455         Reviewed by Brent Fulgham.
456
457         No new tests, no functionality changes.
458
459         * platform/graphics/chromium/LayerTilerChromium.cpp:
460         (WebCore::LayerTilerChromium::drawTiles):
461         * platform/graphics/gpu/TilingData.cpp:
462         (WebCore::TilingData::textureOffset):
463         * platform/graphics/gpu/TilingData.h:
464
465 2011-07-12  Ryosuke Niwa  <rniwa@webkit.org>
466
467         Move RenderTextControl::indexForVisiblePosition to HTMLTextFormControlElement
468         https://bugs.webkit.org/show_bug.cgi?id=64403
469
470         Reviewed by Hajime Morita.
471
472         Moved indexForVisiblePosition from RenderTextControl to HTMLTextFormControlElement.
473
474         Also replaced the call to RenderTextControl::isSelectableElement by a call to enclosingTextFormControl
475         (moved from htmlediting to HTMLTextFormControlElement) because we are only interested in checking
476         whether the given position is inside the current text form control or not.
477
478         In addition, modernized the code in indexForVisiblePosition by calling parentAnchoredEquivalent on the
479         given position and replacing calls to deprecateNode and deprecatedEditingOffset by calls to containerNode
480         and offsetInContainer.
481
482         * accessibility/AccessibilityRenderObject.cpp:
483         (WebCore::AccessibilityRenderObject::indexForVisiblePosition): Calls indexForVisiblePosition.
484         * editing/htmlediting.cpp: Removed enclosingTextFromControl.
485         * editing/htmlediting.h: Removed enclosingTextFromControl.
486         * html/HTMLTextFormControlElement.cpp:
487         (WebCore::HTMLTextFormControlElement::indexForVisiblePosition): Moved from RenderTextControl.
488         (WebCore::HTMLTextFormControlElement::computeSelectionStart): Calls indexForVisiblePosition.
489         (WebCore::HTMLTextFormControlElement::computeSelectionEnd): Calls indexForVisiblePosition.
490         (WebCore::enclosingTextFormControl): Moved from htmlediting.cpp
491         * html/HTMLTextFormControlElement.h:
492         * rendering/RenderTextControl.cpp:
493         * rendering/RenderTextControl.h:
494
495 2011-07-12  Julien Chaffraix  <jchaffraix@webkit.org>
496
497         Make RenderObject::containingBlock virtual for better speed and clarity
498         https://bugs.webkit.org/show_bug.cgi?id=64318
499
500         Reviewed by Darin Adler.
501
502         No new tests, performance refactoring.
503
504         On some of my test cases, this method takes between 3 and 5% of the time spend.
505         The method makes 2 calls to virtual methods which could be moved to their overriden
506         version of containingBlock if we made it virtual.
507
508         That's what this patch does. It saves between 1 and 2% on some synthetic test cases
509         as well as made the current method shorter.
510
511         * rendering/RenderObject.cpp:
512         (WebCore::RenderObject::containingBlock): Removed code for RenderView and RenderTableCell,
513         replaced by ASSERTs.
514
515         * rendering/RenderObject.h: Made containingBlock virtual.
516
517         * rendering/RenderTableCell.h:
518         (WebCore::RenderTableCell::containingBlock):
519         * rendering/RenderView.h:
520         (WebCore::RenderView::containingBlock):
521         The code moved from RenderObject is inlined in those 2 methods.
522
523 2011-07-12  James Robinson  <jamesr@chromium.org>
524
525         [chromium] Chromium win build fix.
526
527         * platform/graphics/chromium/FontChromiumWin.cpp:
528         (WebCore::drawGlyphsWin):
529
530 2011-07-12  Pratik Solanki  <psolanki@apple.com>
531
532         Get webkit to compile with USE(CFNETWORK) enabled on Mac
533         https://bugs.webkit.org/show_bug.cgi?id=63674
534
535         Reviewed by David Kilzer.
536
537         Changes to ResourceHandle class to get it to compile with USE(CFNETWORK).
538
539         No new tests because no change in functionality and option is not enabled on Mac.
540
541         * platform/network/ResourceHandle.h:
542         * platform/network/ResourceHandleInternal.h:
543         * platform/network/cf/ResourceHandleCFNet.cpp:
544         (WebCore::didReceiveResponse):
545         (WebCore::ResourceHandleInternal::~ResourceHandleInternal):
546         (WebCore::ResourceHandle::start):
547         (WebCore::WebCoreSynchronousLoaderClient::willSendRequest): Call adjustMIMETypeIfNecessary
548         on Mac. Also port over fix for <rdar://problem/6901522> added in r43993 which forces the
549         MIME type to text/html if the request is annotated with a "ForceHTMLMIMEType" property.
550
551 2011-07-12  James Robinson  <jamesr@chromium.org>
552
553         [chromium] Delete the unused legacy accelerated canvas 2d code
554         https://bugs.webkit.org/show_bug.cgi?id=64214
555
556         Reviewed by Stephen White.
557
558         This removes the legacy accelerated canvas 2d path and support logic since we (chromium) are no longer using
559         this codepath and it seems clear that no other port is interested.
560
561         Refactoring and removing unused code, so no new tests.
562
563         * WebCore.gypi:
564         * WebCore.xcodeproj/project.pbxproj:
565         * html/canvas/CanvasRenderingContext2D.cpp:
566         (WebCore::CanvasRenderingContext2D::CanvasRenderingContext2D):
567         (WebCore::CanvasRenderingContext2D::setGlobalCompositeOperation):
568         (WebCore::CanvasRenderingContext2D::didDraw):
569         * html/canvas/CanvasRenderingContext2D.h:
570         * loader/EmptyClients.h:
571         * page/ChromeClient.h:
572         * page/Page.cpp:
573         (WebCore::Page::sharedGraphicsContext3D):
574         * page/Page.h:
575         * platform/graphics/GraphicsContext.cpp:
576         (WebCore::GraphicsContext::setSharedGraphicsContext3D):
577         (WebCore::GraphicsContext::syncSoftwareCanvas):
578         * platform/graphics/GraphicsContext.h:
579         * platform/graphics/GraphicsContext3D.h:
580         * platform/graphics/chromium/DrawingBufferChromium.cpp:
581         (WebCore::DrawingBuffer::setGrContext):
582         * platform/graphics/chromium/FontLinux.cpp:
583         (WebCore::Font::drawGlyphs):
584         * platform/graphics/chromium/cc/CCLayerSorter.cpp:
585         (WebCore::pointInTriangle):
586         * platform/graphics/gpu/BicubicShader.cpp: Removed.
587         * platform/graphics/gpu/BicubicShader.h: Removed.
588         * platform/graphics/gpu/ConvolutionShader.cpp: Removed.
589         * platform/graphics/gpu/ConvolutionShader.h: Removed.
590         * platform/graphics/gpu/GraphicsContextGPU.cpp: Removed.
591         * platform/graphics/gpu/GraphicsContextGPU.h: Removed.
592         * platform/graphics/gpu/SharedGraphicsContext3D.cpp: Removed.
593         * platform/graphics/gpu/SharedGraphicsContext3D.h: Removed.
594         * platform/graphics/gpu/SolidFillShader.cpp: Removed.
595         * platform/graphics/gpu/SolidFillShader.h: Removed.
596         * platform/graphics/gpu/TexShader.cpp: Removed.
597         * platform/graphics/gpu/TexShader.h: Removed.
598         * platform/graphics/skia/GraphicsContextSkia.cpp:
599         (WebCore::GraphicsContext::savePlatformState):
600         (WebCore::GraphicsContext::restorePlatformState):
601         (WebCore::GraphicsContext::addInnerRoundedRectClip):
602         (WebCore::GraphicsContext::clearRect):
603         (WebCore::GraphicsContext::clip):
604         (WebCore::GraphicsContext::canvasClip):
605         (WebCore::GraphicsContext::clipOut):
606         (WebCore::GraphicsContext::clipPath):
607         (WebCore::GraphicsContext::concatCTM):
608         (WebCore::GraphicsContext::setCTM):
609         (WebCore::GraphicsContext::drawConvexPolygon):
610         (WebCore::GraphicsContext::drawEllipse):
611         (WebCore::GraphicsContext::drawFocusRing):
612         (WebCore::GraphicsContext::drawLine):
613         (WebCore::GraphicsContext::drawLineForTextChecking):
614         (WebCore::GraphicsContext::drawLineForText):
615         (WebCore::GraphicsContext::drawRect):
616         (WebCore::GraphicsContext::fillPath):
617         (WebCore::GraphicsContext::fillRect):
618         (WebCore::GraphicsContext::fillRoundedRect):
619         (WebCore::GraphicsContext::scale):
620         (WebCore::GraphicsContext::setAlpha):
621         (WebCore::GraphicsContext::setPlatformCompositeOperation):
622         (WebCore::GraphicsContext::setPlatformFillColor):
623         (WebCore::GraphicsContext::setPlatformShadow):
624         (WebCore::GraphicsContext::strokeArc):
625         (WebCore::GraphicsContext::strokePath):
626         (WebCore::GraphicsContext::strokeRect):
627         (WebCore::GraphicsContext::rotate):
628         (WebCore::GraphicsContext::translate):
629         (WebCore::GraphicsContext::setSharedGraphicsContext3D):
630         (WebCore::GraphicsContext::syncSoftwareCanvas):
631         * platform/graphics/skia/ImageBufferSkia.cpp:
632         (WebCore::ImageBuffer::copyImage):
633         (WebCore::ImageBuffer::draw):
634         (WebCore::ImageBuffer::getUnmultipliedImageData):
635         (WebCore::ImageBuffer::getPremultipliedImageData):
636         (WebCore::ImageBuffer::putUnmultipliedImageData):
637         (WebCore::ImageBuffer::putPremultipliedImageData):
638         * platform/graphics/skia/ImageSkia.cpp:
639         (WebCore::BitmapImage::draw):
640         (WebCore::BitmapImageSingleFrameSkia::draw):
641         * platform/graphics/skia/NativeImageSkia.cpp:
642         (WebCore::NativeImageSkia::~NativeImageSkia):
643         * platform/graphics/skia/PlatformContextSkia.cpp:
644         (WebCore::PlatformContextSkia::PlatformContextSkia):
645         (WebCore::PlatformContextSkia::~PlatformContextSkia):
646         (WebCore::PlatformContextSkia::setSharedGraphicsContext3D):
647         (WebCore::PlatformContextSkia::makeGrContextCurrent):
648         * platform/graphics/skia/PlatformContextSkia.h:
649
650 2011-07-12  Emil A Eklund  <eae@chromium.org>
651
652         Switch InlineFlowBox to to new layout types
653         https://bugs.webkit.org/show_bug.cgi?id=64399
654
655         Reviewed by Eric Seidel.
656
657         First step in moving floats over to the new layout abstraction.
658
659         No new tests, no new functionality.
660
661         * rendering/InlineBox.cpp:
662         (WebCore::InlineBox::logicalHeight):
663         * rendering/InlineBox.h:
664         (WebCore::InlineBox::logicalTop):
665         (WebCore::InlineBox::logicalBottom):
666         (WebCore::InlineBox::setLogicalTop):
667         * rendering/InlineFlowBox.cpp:
668         (WebCore::InlineFlowBox::adjustMaxAscentAndDescent):
669         (WebCore::InlineFlowBox::computeLogicalBoxHeights):
670         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
671         (WebCore::InlineFlowBox::addBoxShadowVisualOverflow):
672         (WebCore::InlineFlowBox::addTextBoxVisualOverflow):
673         (WebCore::InlineFlowBox::addReplacedChildOverflow):
674         (WebCore::InlineFlowBox::constrainToLineTopAndBottomIfNeeded):
675         (WebCore::InlineFlowBox::computeOverAnnotationAdjustment):
676         (WebCore::InlineFlowBox::computeUnderAnnotationAdjustment):
677         * rendering/InlineFlowBox.h:
678         * rendering/RenderBlock.cpp:
679         (WebCore::RenderBlock::logicalRightSelectionGap):
680         * rendering/RenderBlock.h:
681         * rendering/RootInlineBox.cpp:
682         (WebCore::RootInlineBox::alignBoxesInBlockDirection):
683         (WebCore::RootInlineBox::lineSelectionGap):
684         (WebCore::RootInlineBox::ascentAndDescentForBox):
685         (WebCore::RootInlineBox::verticalPositionForBox):
686         * rendering/RootInlineBox.h:
687         * rendering/style/RenderStyle.cpp:
688         (WebCore::RenderStyle::getShadowExtent):
689         (WebCore::RenderStyle::getShadowHorizontalExtent):
690         (WebCore::RenderStyle::getShadowVerticalExtent):
691         * rendering/style/RenderStyle.h:
692         (WebCore::InheritedFlags::getTextShadowExtent):
693         (WebCore::InheritedFlags::getTextShadowHorizontalExtent):
694         (WebCore::InheritedFlags::getTextShadowVerticalExtent):
695         (WebCore::InheritedFlags::getTextShadowInlineDirectionExtent):
696         (WebCore::InheritedFlags::getTextShadowBlockDirectionExtent):
697         (WebCore::InheritedFlags::getBoxShadowExtent):
698         (WebCore::InheritedFlags::getBoxShadowHorizontalExtent):
699         (WebCore::InheritedFlags::getBoxShadowVerticalExtent):
700         (WebCore::InheritedFlags::getBoxShadowInlineDirectionExtent):
701         (WebCore::InheritedFlags::getBoxShadowBlockDirectionExtent):
702         (WebCore::InheritedFlags::getShadowInlineDirectionExtent):
703         (WebCore::InheritedFlags::getShadowBlockDirectionExtent):
704         * rendering/style/ShadowData.cpp:
705         (WebCore::calculateShadowExtent):
706         (WebCore::ShadowData::adjustRectForShadow):
707         * rendering/style/ShadowData.h:
708         (WebCore::ShadowData::ShadowData):
709         (WebCore::ShadowData::x):
710         (WebCore::ShadowData::y):
711
712 2011-07-12  Kenichi Ishibashi  <bashi@chromium.org>
713
714         [Chromium] SVG text is not rendered sometimes with geometricPrecision
715         https://bugs.webkit.org/show_bug.cgi?id=64341
716
717         Changing the type of x and y offsets of ComplexTextControllerLinux to make it possible to treat negative offsets.
718
719         Reviewed by Tony Chang.
720
721         Test: platform/chromium-linux/svg/text/text-with-geometric-precision.svg
722
723         * platform/graphics/chromium/ComplexTextControllerLinux.cpp: Changed the type of m_offsetX and m_startingY from unsigned to int.
724         (WebCore::ComplexTextController::ComplexTextController): Changed the type of the argument.
725         (WebCore::ComplexTextController::reset): Ditto.
726         * platform/graphics/chromium/ComplexTextControllerLinux.h:
727
728 2011-07-12  Alexandru Chiculita  <achicu@adobe.com>
729
730         Reviewed by David Hyatt.
731
732         [CSS Exclusions] Parse wrap-shape property
733         https://bugs.webkit.org/show_bug.cgi?id=61726
734
735         Parsing wrap-shape: rect, circle, ellipse and polygon.
736         Moved WindRule from Path.h to it's own file.
737
738         Test: fast/exclusions/parsing-wrap-shape.html
739
740         * WebCore.vcproj/WebCore.vcproj:
741         * WebCore.xcodeproj/project.pbxproj:
742         * css/CSSComputedStyleDeclaration.cpp:
743         (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue):
744         * css/CSSParser.cpp:
745         (WebCore::CSSParser::parseValue):
746         (WebCore::CSSParser::parseWrapShapeRect):
747         (WebCore::CSSParser::parseWrapShapeCircle):
748         (WebCore::CSSParser::parseWrapShapeEllipse):
749         (WebCore::CSSParser::parseWrapShapePolygon):
750         (WebCore::CSSParser::parseWrapShape):
751         * css/CSSParser.h:
752         * css/CSSPrimitiveValue.cpp:
753         (WebCore::CSSPrimitiveValue::init):
754         (WebCore::CSSPrimitiveValue::cleanup):
755         (WebCore::CSSPrimitiveValue::cssText):
756         * css/CSSPrimitiveValue.h:
757         (WebCore::CSSPrimitiveValue::getShapeValue):
758         * css/CSSPropertyNames.in:
759         * css/CSSStyleSelector.cpp:
760         (WebCore::CSSStyleSelector::applyProperty):
761         * css/CSSValueKeywords.in:
762         * css/CSSWrapShapes.cpp: Added.
763         (WebCore::CSSWrapShapeRect::cssText):
764         (WebCore::CSSWrapShapeCircle::cssText):
765         (WebCore::CSSWrapShapeEllipse::cssText):
766         (WebCore::CSSWrapShapePolygon::cssText):
767         * css/CSSWrapShapes.h: Added.
768         (WebCore::CSSWrapShape::~CSSWrapShape):
769         (WebCore::CSSWrapShape::CSSWrapShape):
770         (WebCore::CSSWrapShapeRect::create):
771         (WebCore::CSSWrapShapeRect::left):
772         (WebCore::CSSWrapShapeRect::top):
773         (WebCore::CSSWrapShapeRect::width):
774         (WebCore::CSSWrapShapeRect::height):
775         (WebCore::CSSWrapShapeRect::radiusX):
776         (WebCore::CSSWrapShapeRect::radiusY):
777         (WebCore::CSSWrapShapeRect::setLeft):
778         (WebCore::CSSWrapShapeRect::setTop):
779         (WebCore::CSSWrapShapeRect::setWidth):
780         (WebCore::CSSWrapShapeRect::setHeight):
781         (WebCore::CSSWrapShapeRect::setRadiusX):
782         (WebCore::CSSWrapShapeRect::setRadiusY):
783         (WebCore::CSSWrapShapeRect::type):
784         (WebCore::CSSWrapShapeRect::CSSWrapShapeRect):
785         (WebCore::CSSWrapShapeCircle::create):
786         (WebCore::CSSWrapShapeCircle::left):
787         (WebCore::CSSWrapShapeCircle::top):
788         (WebCore::CSSWrapShapeCircle::radius):
789         (WebCore::CSSWrapShapeCircle::setLeft):
790         (WebCore::CSSWrapShapeCircle::setTop):
791         (WebCore::CSSWrapShapeCircle::setRadius):
792         (WebCore::CSSWrapShapeCircle::type):
793         (WebCore::CSSWrapShapeCircle::CSSWrapShapeCircle):
794         (WebCore::CSSWrapShapeEllipse::create):
795         (WebCore::CSSWrapShapeEllipse::left):
796         (WebCore::CSSWrapShapeEllipse::top):
797         (WebCore::CSSWrapShapeEllipse::radiusX):
798         (WebCore::CSSWrapShapeEllipse::radiusY):
799         (WebCore::CSSWrapShapeEllipse::setLeft):
800         (WebCore::CSSWrapShapeEllipse::setTop):
801         (WebCore::CSSWrapShapeEllipse::setRadiusX):
802         (WebCore::CSSWrapShapeEllipse::setRadiusY):
803         (WebCore::CSSWrapShapeEllipse::type):
804         (WebCore::CSSWrapShapeEllipse::CSSWrapShapeEllipse):
805         (WebCore::CSSWrapShapePolygon::create):
806         (WebCore::CSSWrapShapePolygon::appendPoint):
807         (WebCore::CSSWrapShapePolygon::getXAt):
808         (WebCore::CSSWrapShapePolygon::getYAt):
809         (WebCore::CSSWrapShapePolygon::setWindRule):
810         (WebCore::CSSWrapShapePolygon::windRule):
811         (WebCore::CSSWrapShapePolygon::type):
812         (WebCore::CSSWrapShapePolygon::CSSWrapShapePolygon):
813         * css/SVGCSSValueKeywords.in:
814         * platform/graphics/Path.h:
815         * platform/graphics/WindRule.h: Added.
816         * rendering/style/RenderStyle.cpp:
817         (WebCore::RenderStyle::diff):
818         * rendering/style/RenderStyle.h:
819         (WebCore::InheritedFlags::setWrapShape):
820         (WebCore::InheritedFlags::wrapShape):
821         (WebCore::InheritedFlags::initialWrapShape):
822         * rendering/style/StyleRareNonInheritedData.cpp:
823         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
824         (WebCore::StyleRareNonInheritedData::operator==):
825         * rendering/style/StyleRareNonInheritedData.h:
826
827 2011-07-12  Simon Fraser  <simon.fraser@apple.com>
828
829         Clean up some RenderLayerCompositor code relating to scroll and root layers
830         https://bugs.webkit.org/show_bug.cgi?id=64400
831
832         Reviewed by James Robinson.
833
834         There was no need for FrameView::syncCompositingStateForThisFrame()
835         to call syncCompositingStateForThisLayerOnly() on the various
836         scrollbar-related layers, because the subsequent call to 
837         compositor()->flushPendingLayerChanges() starts to flush at
838         m_overflowControlsHostLayer if one exists, and it's an ancestor
839         of the scrollbar layers.
840         
841         Also clean up terminology in RenderLayerCompositor.
842             m_rootPlatformLayer -> m_rootContentLayer
843             rootPlatformLayer() -> rootGraphicsLayer()
844         
845         No behavior change, so no new tests.
846         
847         * page/FrameView.cpp:
848         (WebCore::FrameView::syncCompositingStateForThisFrame):
849         * rendering/RenderLayerCompositor.cpp:
850         (WebCore::RenderLayerCompositor::enableCompositingMode):
851         (WebCore::RenderLayerCompositor::flushPendingLayerChanges):
852         (WebCore::RenderLayerCompositor::updateCompositingLayers):
853         (WebCore::RenderLayerCompositor::layerTreeAsText):
854         (WebCore::RenderLayerCompositor::parentFrameContentLayers):
855         (WebCore::RenderLayerCompositor::rootGraphicsLayer):
856         (WebCore::RenderLayerCompositor::didMoveOnscreen):
857         (WebCore::RenderLayerCompositor::willMoveOffscreen):
858         (WebCore::RenderLayerCompositor::updateRootLayerPosition):
859         (WebCore::RenderLayerCompositor::ensureRootLayer):
860         (WebCore::RenderLayerCompositor::destroyRootLayer):
861         (WebCore::RenderLayerCompositor::attachRootLayer):
862         (WebCore::RenderLayerCompositor::detachRootLayer):
863         (WebCore::RenderLayerCompositor::updateRootLayerAttachment):
864         * rendering/RenderLayerCompositor.h:
865
866 2011-07-12  Sheriff Bot  <webkit.review.bot@gmail.com>
867
868         Unreviewed, rolling out r90842.
869         http://trac.webkit.org/changeset/90842
870         https://bugs.webkit.org/show_bug.cgi?id=64401
871
872         Causes crash in debug on compositing/overflow/content-gains-
873         scrollbars.html (Requested by jamesr on #webkit).
874
875         * WebCore.gypi:
876         * platform/graphics/chromium/ContentLayerChromium.cpp:
877         (WebCore::ContentLayerChromium::ContentLayerChromium):
878         (WebCore::ContentLayerChromium::paintContentsIfDirty):
879         (WebCore::ContentLayerChromium::cleanupResources):
880         (WebCore::ContentLayerChromium::setLayerRenderer):
881         (WebCore::ContentLayerChromium::tilingTransform):
882         (WebCore::ContentLayerChromium::contentBounds):
883         (WebCore::ContentLayerChromium::updateLayerSize):
884         (WebCore::ContentLayerChromium::draw):
885         (WebCore::ContentLayerChromium::drawsContent):
886         (WebCore::ContentLayerChromium::createTilerIfNeeded):
887         (WebCore::ContentLayerChromium::updateCompositorResources):
888         (WebCore::ContentLayerChromium::setTilingOption):
889         (WebCore::ContentLayerChromium::bindContentsTexture):
890         (WebCore::ContentLayerChromium::setIsMask):
891         (WebCore::writeIndent):
892         (WebCore::ContentLayerChromium::dumpLayerProperties):
893         * platform/graphics/chromium/ContentLayerChromium.h:
894         * platform/graphics/chromium/ImageLayerChromium.cpp:
895         (WebCore::ImageLayerChromium::ImageLayerChromium):
896         (WebCore::ImageLayerChromium::paintContentsIfDirty):
897         (WebCore::ImageLayerChromium::updateCompositorResources):
898         (WebCore::ImageLayerChromium::contentBounds):
899         * platform/graphics/chromium/ImageLayerChromium.h:
900         (WebCore::ImageLayerChromium::drawsContent):
901         * platform/graphics/chromium/LayerChromium.cpp:
902         (WebCore::LayerChromium::pushPropertiesTo):
903         (WebCore::LayerChromium::ccLayerImpl):
904         * platform/graphics/chromium/LayerChromium.h:
905         (WebCore::LayerChromium::draw):
906         * platform/graphics/chromium/LayerRendererChromium.cpp:
907         (WebCore::LayerRendererChromium::drawRootLayer):
908         * platform/graphics/chromium/LayerTilerChromium.cpp:
909         (WebCore::LayerTilerChromium::updateRect):
910         (WebCore::LayerTilerChromium::draw):
911         (WebCore::LayerTilerChromium::drawTiles):
912         * platform/graphics/chromium/LayerTilerChromium.h:
913         * platform/graphics/chromium/TiledLayerChromium.cpp: Removed.
914         * platform/graphics/chromium/TiledLayerChromium.h: Removed.
915         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
916         (WebCore::CCLayerImpl::drawsContent):
917         (WebCore::CCLayerImpl::draw):
918         * platform/graphics/chromium/cc/CCLayerImpl.h:
919         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp: Removed.
920         * platform/graphics/chromium/cc/CCTiledLayerImpl.h: Removed.
921
922 2011-07-12  Joseph Pecoraro  <joepeck@webkit.org>
923
924         ApplicationCache update should not immediately fail when reaching per-origin quota
925         https://bugs.webkit.org/show_bug.cgi?id=64177
926
927         Reviewed by Alexey Proskuryakov.
928
929         New behavior of handling ApplicationCache per-origin quotas. Previously,
930         if the quota was reached while downloading we would fail the download
931         and then prompt the user for a storage increase. This required a refresh,
932         a redownload of resources, and the total storage was not known so the
933         process could be repeated multiple times before an acceptable quota
934         was found or the user disallowed an increase.
935         
936         The new behavior is to complete the download of the entire appcache.
937         When the cache completes downloading and it is greater than the origin
938         quota, prompt the user to allow a quota increase with the known space
939         needed. If the quota is increased, the cache will succeed, otherwise
940         it will fail with the normal failure steps.
941
942         An alternative behavior is prompting while downloading immediately
943         when the origin quota is reached, however at that point the entire
944         space needed is unknown and so quota increases might not be enough
945         and could result in multiple prompts to the user.
946
947         Tests: http/tests/appcache/origin-quota-continued-download-multiple-manifests.html
948                http/tests/appcache/origin-quota-continued-download.html
949
950         * loader/appcache/ApplicationCacheGroup.h:
951         * loader/appcache/ApplicationCacheGroup.cpp:
952         (WebCore::ApplicationCacheGroup::ApplicationCacheGroup):
953         Rename instance variable to be more clear on its intent.
954
955         (WebCore::ApplicationCacheGroup::didFinishLoading):
956         Check the quota limit while downloading so we can fail early
957         if the user already denied a quota increase.
958
959         (WebCore::ApplicationCacheGroup::didReachOriginQuota):
960         Pass the space needed information to the chrome client.
961
962         (WebCore::ApplicationCacheGroup::cacheUpdateFailedDueToOriginQuota):
963         Removed. Instead convert the callers to update state and console
964         log when the per-origin quota is reached. This allows us to follow
965         the normal failure steps if the quota is reached at the end of a
966         download, and the alternative short path when we fail during downloading.
967
968         (WebCore::ApplicationCacheGroup::recalculateAvailableSpaceInQuota):
969         Extract to a helper function.
970
971         (WebCore::ApplicationCacheGroup::checkIfLoadIsComplete):
972         Allow for a quota increase at the end of the download now that
973         we know the space needed. Then proceed to fail or succeed
974         as we normally would.
975
976         * loader/appcache/ApplicationCacheStorage.h:
977         * loader/appcache/ApplicationCacheStorage.cpp:
978         (WebCore::ApplicationCacheStorage::checkOriginQuota):
979         (WebCore::ApplicationCacheStorage::storeNewestCache):
980         Extract checking the origin quota for when an ApplicationCacheGroup
981         will be replacing an ApplicationCacheGroup into a helper function.
982         The helper also provides an out parameter for the space needed
983         to properly fit the new cache group if it wouldn't fit.
984
985         * page/ChromeClient.h:
986         * loader/EmptyClients.h:
987         (WebCore::EmptyChromeClient::reachedApplicationCacheOriginQuota):
988         Add a space needed parameter when reaching the per-origin quota.
989
990 2011-07-12  Chris Rogers  <crogers@google.com>
991
992         AudioDevice::Stop can close NULL handle.
993         https://bugs.webkit.org/show_bug.cgi?id=64157
994
995         Reviewed by Kenneth Russell.
996
997         No new tests since audio API is not yet implemented.
998
999         * bindings/js/JSAudioContextCustom.cpp:
1000         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
1001         * bindings/v8/custom/V8AudioContextCustom.cpp:
1002         (WebCore::V8AudioContext::constructorCallback):
1003         * webaudio/AudioContext.cpp:
1004         (WebCore::AudioContext::create):
1005         (WebCore::AudioContext::uninitialize):
1006         * webaudio/AudioContext.h:
1007
1008 2011-07-12  John Bates  <jbates@google.com>
1009
1010         Move call to syncCompositingLayers so that we do not trigger redundant draws.
1011         https://bugs.webkit.org/show_bug.cgi?id=64224
1012
1013         doComposite was triggering two composites every time a canvas was dirtied.
1014         By moving syncCompositingLayers call to layout, the client code can draw without triggering
1015         a redundant frame. Also renamed WebViewImpl::updateLayers to
1016         syncCompositingLayers, because it was confusing. CCLayerTreeHostImplProxy::updateLayers was
1017         no longer needed, because animateAndLayout calls WebViewImpl::layout.
1018
1019         Reviewed by James Robinson.
1020
1021         * platform/graphics/chromium/LayerRendererChromium.cpp:
1022         (WebCore::LayerRendererChromium::updateLayers):
1023         * platform/graphics/chromium/LayerRendererChromium.h:
1024         * platform/graphics/chromium/cc/CCLayerTreeHost.cpp:
1025         (WebCore::CCLayerTreeHost::syncCompositingLayers):
1026         * platform/graphics/chromium/cc/CCLayerTreeHost.h:
1027         * platform/graphics/chromium/cc/CCLayerTreeHostImplProxy.cpp:
1028         (WebCore::CCLayerTreeHostImplProxy::requestFrameAndCommit):
1029
1030 2011-07-12  Ryosuke Niwa  <rniwa@webkit.org>
1031
1032         Isolate HTMLTextFormControlElement into a separate file
1033         https://bugs.webkit.org/show_bug.cgi?id=64381
1034
1035         Reviewed by Dimitri Glazkov.
1036
1037         Extracted HTMLTextFormControlElement.h and HTMLTextFormControlElement.cpp out of
1038         HTMLFormControlElement.h and HTMLFormControlElement.cpp.
1039
1040         Also moved defaultEventHandler from HTMLFormControlElementWithState to HTMLTextFormControlElement
1041         because it was specific to HTMLTextFormControlElement, and replaced all references to
1042         HTMLFormControlElementWithState in HTMLInputElement and HTMLTextAreaElement by ones to
1043         HTMLTextFormControlElement.
1044
1045         * CMakeLists.txt:
1046         * GNUmakefile.list.am:
1047         * WebCore.gypi:
1048         * WebCore.pro:
1049         * WebCore.vcproj/WebCore.vcproj:
1050         * WebCore.xcodeproj/project.pbxproj:
1051         * editing/TextIterator.cpp:
1052         * editing/htmlediting.cpp:
1053         * html/HTMLElementsAllInOne.cpp:
1054         * html/HTMLFormControlElement.cpp:
1055         (WebCore::HTMLFormControlElement::isFocusable):
1056         * html/HTMLFormControlElement.h:
1057         * html/HTMLInputElement.cpp:
1058         (WebCore::HTMLInputElement::isKeyboardFocusable):
1059         (WebCore::HTMLInputElement::isMouseFocusable):
1060         (WebCore::HTMLInputElement::updateFocusAppearance):
1061         (WebCore::HTMLInputElement::canStartSelection):
1062         (WebCore::HTMLInputElement::parseMappedAttribute):
1063         (WebCore::HTMLInputElement::finishParsingChildren):
1064         (WebCore::HTMLInputElement::rendererIsNeeded):
1065         (WebCore::HTMLInputElement::attach):
1066         (WebCore::HTMLInputElement::detach):
1067         (WebCore::HTMLInputElement::copyNonAttributeProperties):
1068         (WebCore::HTMLInputElement::defaultEventHandler):
1069         (WebCore::HTMLInputElement::willMoveToNewOwnerDocument):
1070         (WebCore::HTMLInputElement::didMoveToNewOwnerDocument):
1071         (WebCore::HTMLInputElement::addSubresourceAttributeURLs):
1072         (WebCore::HTMLInputElement::recalcWillValidate):
1073         * html/HTMLInputElement.h:
1074         * html/HTMLTextAreaElement.cpp:
1075         (WebCore::HTMLTextAreaElement::defaultEventHandler):
1076         * html/HTMLTextAreaElement.h:
1077         * html/HTMLTextFormControlElement.cpp: Copied from Source/WebCore/html/HTMLFormControlElement.cpp.
1078         (WebCore::HTMLTextFormControlElement::defaultEventHandler):
1079         * html/HTMLTextFormControlElement.h: Copied from Source/WebCore/html/HTMLFormControlElement.h.
1080
1081 2011-07-12  Sheriff Bot  <webkit.review.bot@gmail.com>
1082
1083         Unreviewed, rolling out r90831.
1084         http://trac.webkit.org/changeset/90831
1085         https://bugs.webkit.org/show_bug.cgi?id=64389
1086
1087         Likely caused fast/canvas/DrawImageSinglePixelStretch.html to
1088         start timing out on the chromium GPU bots (Requested by ojan
1089         on #webkit).
1090
1091         * platform/graphics/skia/ImageBufferSkia.cpp:
1092         (WebCore::getImageData):
1093         (WebCore::putImageData):
1094
1095 2011-07-12  James Robinson  <jamesr@chromium.org>
1096
1097         Reviewed by Kenneth Russell.
1098
1099         [chromium] Move draw implementation for ContentLayerChromium/ImageLayerChromium to the appropriate CCLayerImpl subclass
1100         https://bugs.webkit.org/show_bug.cgi?id=58833
1101
1102         Adds a TiledLayerChromium class to handle the tiling logic shared by ContentLayerChromium and ImageLayerChromium
1103         so that they can be siblings in the class hierarchy instead of children. Also adds a CCTiledLayerImpl to handle
1104         the drawing responsibilities for tiled layers.
1105
1106         TiledLayerChromium maintains a tiler, tiling options, and calculates the tiling transform. Subclasses are
1107         responsible for providing an appropriate texture updater implementation. CCTiledLayerImpl takes the tiler,
1108         tiling transform and layer properties and draws the layer.  Longer term it'd be better of the CCTiledLayerImpl
1109         owned the tiler and the TiledLayerChromium only owned an updater, but getting there will require changing the
1110         way tile eviction works.
1111
1112         * WebCore.gypi:
1113         * platform/graphics/chromium/ContentLayerChromium.cpp:
1114         (WebCore::ContentLayerChromium::ContentLayerChromium):
1115         (WebCore::ContentLayerChromium::paintContentsIfDirty):
1116         (WebCore::ContentLayerChromium::drawsContent):
1117         * platform/graphics/chromium/ContentLayerChromium.h:
1118         (WebCore::ContentLayerChromium::textureUpdater):
1119         * platform/graphics/chromium/ImageLayerChromium.cpp:
1120         (WebCore::ImageLayerChromium::ImageLayerChromium):
1121         (WebCore::ImageLayerChromium::cleanupResources):
1122         (WebCore::ImageLayerChromium::paintContentsIfDirty):
1123         (WebCore::ImageLayerChromium::textureUpdater):
1124         (WebCore::ImageLayerChromium::contentBounds):
1125         (WebCore::ImageLayerChromium::drawsContent):
1126         (WebCore::ImageLayerChromium::createTextureUpdaterIfNeeded):
1127         * platform/graphics/chromium/ImageLayerChromium.h:
1128         * platform/graphics/chromium/LayerChromium.cpp:
1129         (WebCore::LayerChromium::pushPropertiesTo):
1130         (WebCore::LayerChromium::ccLayerImpl):
1131         * platform/graphics/chromium/LayerChromium.h:
1132         (WebCore::LayerChromium::contentBounds):
1133         * platform/graphics/chromium/LayerRendererChromium.cpp:
1134         (WebCore::LayerRendererChromium::drawRootLayer):
1135         (WebCore::visibleLayerRect):
1136         (WebCore::paintLayerContentsIfDirty):
1137         (WebCore::LayerRendererChromium::paintLayerContents):
1138         (WebCore::LayerRendererChromium::drawLayer):
1139         * platform/graphics/chromium/LayerTilerChromium.cpp:
1140         (WebCore::LayerTilerChromium::updateRect):
1141         (WebCore::LayerTilerChromium::draw):
1142         (WebCore::LayerTilerChromium::drawTiles):
1143         * platform/graphics/chromium/LayerTilerChromium.h:
1144         * platform/graphics/chromium/TiledLayerChromium.cpp: Added.
1145         (WebCore::TiledLayerChromium::TiledLayerChromium):
1146         (WebCore::TiledLayerChromium::~TiledLayerChromium):
1147         (WebCore::TiledLayerChromium::createCCLayerImpl):
1148         (WebCore::TiledLayerChromium::cleanupResources):
1149         (WebCore::TiledLayerChromium::setLayerRenderer):
1150         (WebCore::TiledLayerChromium::updateTileSizeAndTilingOption):
1151         (WebCore::TiledLayerChromium::drawsContent):
1152         (WebCore::TiledLayerChromium::createTilerIfNeeded):
1153         (WebCore::TiledLayerChromium::updateCompositorResources):
1154         (WebCore::TiledLayerChromium::setTilingOption):
1155         (WebCore::TiledLayerChromium::setIsMask):
1156         (WebCore::TiledLayerChromium::tilingTransform):
1157         (WebCore::TiledLayerChromium::pushPropertiesTo):
1158         (WebCore::writeIndent):
1159         (WebCore::TiledLayerChromium::dumpLayerProperties):
1160         * platform/graphics/chromium/TiledLayerChromium.h: Copied from Source/WebCore/platform/graphics/chromium/ContentLayerChromium.h.
1161         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
1162         (WebCore::CCLayerImpl::draw):
1163         * platform/graphics/chromium/cc/CCLayerImpl.h:
1164         (WebCore::CCLayerImpl::setDrawsContent):
1165         (WebCore::CCLayerImpl::drawsContent):
1166         (WebCore::CCLayerImpl::contentBounds):
1167         (WebCore::CCLayerImpl::setContentBounds):
1168         (WebCore::CCLayerImpl::doubleSided):
1169         (WebCore::CCLayerImpl::setDoubleSided):
1170         * platform/graphics/chromium/cc/CCTiledLayerImpl.cpp: Added.
1171         (WebCore::CCTiledLayerImpl::CCTiledLayerImpl):
1172         (WebCore::CCTiledLayerImpl::~CCTiledLayerImpl):
1173         (WebCore::CCTiledLayerImpl::draw):
1174         (WebCore::CCTiledLayerImpl::bindContentsTexture):
1175         (WebCore::CCTiledLayerImpl::dumpLayerProperties):
1176         * platform/graphics/chromium/cc/CCTiledLayerImpl.h: Added.
1177         (WebCore::CCTiledLayerImpl::create):
1178         (WebCore::CCTiledLayerImpl::setTilingTransform):
1179         (WebCore::CCTiledLayerImpl::setTiler):
1180
1181 2011-07-12  Arno Renevier  <arno@renevier.net>
1182
1183         [GTK] DOM bindings do not have gir annotations
1184         https://bugs.webkit.org/show_bug.cgi?id=45395
1185
1186         Reviewed by Xan Lopez.
1187
1188         * bindings/scripts/CodeGeneratorGObject.pm: generate introspection annotations.
1189         * bindings/scripts/test/GObject/WebKitDOMTestCallback.h: update for new output.
1190         * bindings/scripts/test/GObject/WebKitDOMTestObj.h: ditto.
1191         * bindings/scripts/test/GObject/WebKitDOMTestSerializedScriptValueInterface.h: ditto.
1192
1193 2011-07-12  Chris Rogers  <crogers@google.com>
1194
1195         webkitAudioContext does not do proper sanity checking on its arguments.
1196         https://bugs.webkit.org/show_bug.cgi?id=64076
1197
1198         Reviewed by Kenneth Russell.
1199
1200         No new tests since audio API is not yet implemented.
1201
1202         * bindings/js/JSAudioContextCustom.cpp:
1203         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
1204         (WebCore::JSAudioContext::createBuffer):
1205         * bindings/v8/custom/V8AudioContextCustom.cpp:
1206         (WebCore::V8AudioContext::constructorCallback):
1207         (WebCore::V8AudioContext::createBufferCallback):
1208         * platform/audio/HRTFDatabaseLoader.h:
1209         (WebCore::HRTFDatabaseLoader::databaseSampleRate):
1210         * webaudio/AudioContext.cpp:
1211         (WebCore::AudioContext::create):
1212         (WebCore::AudioContext::createOfflineContext):
1213         (WebCore::AudioContext::createBuffer):
1214         * webaudio/AudioContext.h:
1215
1216 2011-07-12  Pratik Solanki  <psolanki@apple.com>
1217
1218         Implement didReceiveDataArray callback for CFNetwork based loader
1219         https://bugs.webkit.org/show_bug.cgi?id=64130
1220
1221         Reviewed by David Kilzer.
1222
1223         Factor out the didReceiveDataArray code from ResourceHandleMac.mm into
1224         a new method ResourceHandle::handleDataArray(). Implement the callback
1225         in the CFNetwork loader code and call handleDataArray() to process
1226         incoming data.
1227
1228         No new tests because the flag is not enabled for any bots.
1229
1230         * platform/network/ResourceHandle.h:
1231         * platform/network/cf/ResourceHandleCFNet.cpp:
1232         (WebCore::didReceiveDataArray):
1233         (WebCore::ResourceHandle::createCFURLConnection):
1234         (WebCore::ResourceHandle::handleDataArray):
1235         * platform/network/mac/ResourceHandleMac.mm:
1236         (-[WebCoreResourceHandleAsDelegate connection:didReceiveDataArray:]):
1237
1238 2011-07-12  Emil A Eklund  <eae@chromium.org>
1239
1240         Switch preferred width/height and columns to to new layout types
1241         https://bugs.webkit.org/show_bug.cgi?id=64329
1242
1243         Reviewed by Eric Seidel.
1244
1245         No new tests, no new functionality.
1246
1247         * rendering/LayoutTypes.h:
1248         (WebCore::ceiledLayoutUnit):
1249         Add ceiledLayoutUnit to go with the floored version.
1250         
1251         * rendering/RenderBlock.cpp:
1252         (WebCore::RenderBlock::adjustRectForColumns):
1253         (WebCore::RenderBlock::flipForWritingModeIncludingColumns):
1254         (WebCore::RenderBlock::adjustStartEdgeForWritingModeIncludingColumns):
1255         Rename rect version of flipForWritingModeIncludingColumns to
1256         adjustStartEdgeForWritingModeIncludingColumns as it adjust the start edge
1257         and does not flip the rect.
1258        
1259         (WebCore::RenderBlock::adjustForColumns):
1260         (WebCore::updatePreferredWidth):
1261         * rendering/RenderBlock.h:
1262         * rendering/RenderBox.cpp:
1263         (WebCore::RenderBox::minPreferredLogicalWidth):
1264         (WebCore::RenderBox::maxPreferredLogicalWidth):
1265         (WebCore::RenderBox::offsetFromContainer):
1266         (WebCore::RenderBox::computePercentageLogicalHeight):
1267         (WebCore::RenderBox::flipForWritingMode):
1268         (WebCore::RenderBox::flipForWritingModeIncludingColumns):
1269         * rendering/RenderBox.h:
1270         * rendering/RenderListBox.cpp:
1271         (WebCore::RenderListBox::itemBoundingBoxRect):
1272         * rendering/RenderListBox.h:
1273         * rendering/RenderObject.h:
1274         (WebCore::RenderObject::minPreferredLogicalWidth):
1275         (WebCore::RenderObject::maxPreferredLogicalWidth):
1276         (WebCore::RenderObject::adjustForColumns):
1277         * rendering/RenderReplaced.cpp:
1278         (WebCore::RenderReplaced::computeReplacedLogicalWidth):
1279         (WebCore::RenderReplaced::computeReplacedLogicalHeight):
1280         * rendering/TableLayout.h:
1281
1282 2011-07-12  Levi Weintraub  <leviw@chromium.org>
1283
1284         Change roundedIntRect to roundedRect
1285         https://bugs.webkit.org/show_bug.cgi?id=64326
1286
1287         Reviewed by Eric Seidel.
1288
1289         Renaming RoundedIntRect to RoundedRect and moving the underlying type to Layout units from
1290         integer-based versions.
1291
1292         No new tests, no new functionality
1293
1294         * WebCore.gypi:
1295         * WebCore.pro:
1296         * WebCore.vcproj/WebCore.vcproj:
1297         * WebCore.xcodeproj/project.pbxproj:
1298         * platform/graphics/GraphicsContext.cpp:
1299         (WebCore::GraphicsContext::addRoundedRectClip):
1300         (WebCore::GraphicsContext::clipOutRoundedRect):
1301         (WebCore::GraphicsContext::fillRoundedRect):
1302         (WebCore::GraphicsContext::fillRectWithRoundedHole):
1303         * platform/graphics/GraphicsContext.h:
1304         * platform/graphics/Path.cpp:
1305         (WebCore::Path::addRoundedRect):
1306         * platform/graphics/Path.h:
1307         * platform/graphics/RoundedIntRect.cpp: Removed.
1308         * platform/graphics/RoundedIntRect.h: Removed.
1309         * platform/graphics/RoundedRect.cpp: Copied from Source/WebCore/platform/graphics/RoundedIntRect.cpp.
1310         (WebCore::RoundedRect::Radii::isZero):
1311         (WebCore::RoundedRect::Radii::scale):
1312         (WebCore::RoundedRect::Radii::expand):
1313         (WebCore::RoundedRect::inflateWithRadii):
1314         (WebCore::RoundedRect::Radii::includeLogicalEdges):
1315         (WebCore::RoundedRect::Radii::excludeLogicalEdges):
1316         (WebCore::RoundedRect::RoundedRect):
1317         (WebCore::RoundedRect::includeLogicalEdges):
1318         (WebCore::RoundedRect::excludeLogicalEdges):
1319         (WebCore::RoundedRect::isRenderable):
1320         * platform/graphics/RoundedRect.h: Copied from Source/WebCore/platform/graphics/RoundedIntRect.h.
1321         (WebCore::RoundedRect::Radii::Radii):
1322         (WebCore::RoundedRect::Radii::setTopLeft):
1323         (WebCore::RoundedRect::Radii::setTopRight):
1324         (WebCore::RoundedRect::Radii::setBottomLeft):
1325         (WebCore::RoundedRect::Radii::setBottomRight):
1326         (WebCore::RoundedRect::Radii::topLeft):
1327         (WebCore::RoundedRect::Radii::topRight):
1328         (WebCore::RoundedRect::Radii::bottomLeft):
1329         (WebCore::RoundedRect::Radii::bottomRight):
1330         (WebCore::RoundedRect::Radii::expand):
1331         (WebCore::RoundedRect::Radii::shrink):
1332         (WebCore::RoundedRect::rect):
1333         (WebCore::RoundedRect::setRect):
1334         (WebCore::RoundedRect::move):
1335         (WebCore::RoundedRect::inflate):
1336         (WebCore::RoundedRect::expandRadii):
1337         (WebCore::RoundedRect::shrinkRadii):
1338         (WebCore::operator==):
1339         * platform/graphics/ShadowBlur.cpp:
1340         (WebCore::ScratchBuffer::setLastShadowValues):
1341         (WebCore::ScratchBuffer::setLastInsetShadowValues):
1342         (WebCore::ScratchBuffer::matchesLastShadow):
1343         (WebCore::ScratchBuffer::matchesLastInsetShadow):
1344         (WebCore::computeSliceSizesFromRadii):
1345         (WebCore::ShadowBlur::templateSize):
1346         (WebCore::ShadowBlur::drawRectShadow):
1347         (WebCore::ShadowBlur::drawInsetShadow):
1348         (WebCore::ShadowBlur::drawRectShadowWithoutTiling):
1349         (WebCore::ShadowBlur::drawInsetShadowWithoutTiling):
1350         (WebCore::ShadowBlur::drawInsetShadowWithTiling):
1351         (WebCore::ShadowBlur::drawRectShadowWithTiling):
1352         (WebCore::ShadowBlur::drawLayerPieces):
1353         * platform/graphics/ShadowBlur.h:
1354         * platform/graphics/cg/GraphicsContextCG.cpp:
1355         (WebCore::GraphicsContext::fillRect):
1356         (WebCore::GraphicsContext::fillRoundedRect):
1357         (WebCore::GraphicsContext::fillRectWithRoundedHole):
1358         * rendering/RenderBox.cpp:
1359         (WebCore::RenderBox::paintBoxDecorations):
1360         * rendering/RenderBoxModelObject.cpp:
1361         (WebCore::RenderBoxModelObject::getBackgroundRoundedRect):
1362         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1363         (WebCore::RenderBoxModelObject::paintOneBorderSide):
1364         (WebCore::RenderBoxModelObject::paintBorderSides):
1365         (WebCore::RenderBoxModelObject::paintTranslucentBorderSides):
1366         (WebCore::RenderBoxModelObject::paintBorder):
1367         (WebCore::RenderBoxModelObject::drawBoxSideFromPath):
1368         (WebCore::RenderBoxModelObject::clipBorderSidePolygon):
1369         (WebCore::RenderBoxModelObject::paintBoxShadow):
1370         * rendering/RenderBoxModelObject.h:
1371         * rendering/RenderThemeMac.mm:
1372         (WebCore::RenderThemeMac::paintMenuListButtonGradients):
1373         (WebCore::RenderThemeMac::paintSliderTrack):
1374         * rendering/style/RenderStyle.cpp:
1375         (WebCore::calcRadiiFor):
1376         (WebCore::calcConstraintScaleFor):
1377         (WebCore::RenderStyle::getRoundedBorderFor):
1378         (WebCore::RenderStyle::getRoundedInnerBorderFor):
1379         * rendering/style/RenderStyle.h:
1380
1381 2011-07-12  Mike Reed  <reed@google.com>
1382
1383         [skia] optimize getImageData to avoid a copy when not needed. lockPixels() now does the right thing.
1384         https://bugs.webkit.org/show_bug.cgi?id=64302
1385
1386         Reviewed by Stephen White.
1387
1388         No new tests. Just an optimization for getImageData(), existing <canvas> tests apply
1389
1390         * platform/graphics/skia/ImageBufferSkia.cpp:
1391         (WebCore::getImageData):
1392         (WebCore::putImageData):
1393
1394 2011-07-12  Pavel Feldman  <pfeldman@google.com>
1395
1396         Web Inspector: introduce UserMetrics for collecting stats in Chromium port.
1397         https://bugs.webkit.org/show_bug.cgi?id=64350
1398
1399         Reviewed by Yury Semikhatsky.
1400
1401         Test: inspector/user-metrics.html
1402
1403         * WebCore.gypi:
1404         * WebCore.vcproj/WebCore.vcproj:
1405         * bindings/js/JSInspectorFrontendHostCustom.cpp:
1406         (WebCore::JSInspectorFrontendHost::recordActionTaken):
1407         (WebCore::JSInspectorFrontendHost::recordPanelShown):
1408         (WebCore::JSInspectorFrontendHost::recordSettingChanged):
1409         * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
1410         (WebCore::histogramEnumeration):
1411         (WebCore::V8InspectorFrontendHost::recordActionTakenCallback):
1412         (WebCore::V8InspectorFrontendHost::recordPanelShownCallback):
1413         (WebCore::V8InspectorFrontendHost::recordSettingChangedCallback):
1414         * inspector/InspectorFrontendHost.idl:
1415         * inspector/front-end/AuditsPanel.js:
1416         (WebInspector.AuditsPanel.prototype.initiateAudit):
1417         * inspector/front-end/ConsoleView.js:
1418         * inspector/front-end/DebuggerModel.js:
1419         (WebInspector.DebuggerModel.prototype.setBreakpoint):
1420         (WebInspector.DebuggerModel.prototype.setBreakpointBySourceId):
1421         * inspector/front-end/InspectorFrontendHostStub.js:
1422         (.WebInspector.InspectorFrontendHostStub.prototype.loadSessionSetting):
1423         (.WebInspector.InspectorFrontendHostStub.prototype.recordActionTaken):
1424         (.WebInspector.InspectorFrontendHostStub.prototype.recordPanelShown):
1425         (.WebInspector.InspectorFrontendHostStub.prototype.recordSettingChanged):
1426         * inspector/front-end/ProfilesPanel.js:
1427         (WebInspector.ProfilesPanel.prototype._setRecordingProfile):
1428         (WebInspector.ProfilesPanel.prototype.takeHeapSnapshot):
1429         * inspector/front-end/TimelinePanel.js:
1430         (WebInspector.TimelinePanel.prototype._toggleTimelineButtonClicked):
1431         * inspector/front-end/UserMetrics.js: Added.
1432         (WebInspector.UserMetrics.settingChanged):
1433         (WebInspector.UserMetrics):
1434         (WebInspector.UserMetrics.prototype.panelShown):
1435         (WebInspector.UserMetrics._Recorder):
1436         (WebInspector.UserMetrics._Recorder.prototype.record):
1437         * inspector/front-end/WebKit.qrc:
1438         * inspector/front-end/inspector.html:
1439         * inspector/front-end/inspector.js:
1440         (WebInspector._toggleAttach):
1441
1442 2011-07-12  Pratik Solanki  <psolanki@apple.com>
1443
1444         Reviewed by David Kilzer.
1445
1446         Add NSURLResponse wrapper in ResourceResponse when USE(CFNETWORK) is enabled
1447         https://bugs.webkit.org/show_bug.cgi?id=63286
1448
1449         When USE(CFNETWORK) is enabled on Mac, keep an NSURLResponse object along with the
1450         CFURLResponseRef so that WebKit can continue using the NSURLResponse.
1451
1452         No new tests because no change in functionality and option is not enabled on Mac.
1453
1454         * platform/network/cf/ResourceResponse.h:
1455         (WebCore::ResourceResponse::ResourceResponse):
1456         * platform/network/mac/ResourceResponseMac.mm:
1457         (WebCore::ResourceResponse::initNSURLResponse):
1458         (WebCore::ResourceResponse::nsURLResponse):
1459         (WebCore::ResourceResponse::ResourceResponse):
1460
1461 2011-07-12  Pavel Podivilov  <podivilov@chromium.org>
1462
1463         Web Inspector: Cancelling an empty edit fails.
1464         https://bugs.webkit.org/show_bug.cgi?id=64351
1465
1466         Reviewed by Pavel Feldman.
1467
1468         * inspector/front-end/ResourceView.js:
1469         (WebInspector.EditableResourceSourceFrame.prototype.cancelEditing):
1470
1471 2011-07-12  Pavel Podivilov  <podivilov@chromium.org>
1472
1473         Web Inspector: make TextViewerDelegate methods implementations public in SourceFrame.
1474         https://bugs.webkit.org/show_bug.cgi?id=64353
1475
1476         Reviewed by Pavel Feldman.
1477
1478         * inspector/front-end/SourceFrame.js:
1479         (WebInspector.SourceFrame.prototype.beforeTextChanged):
1480         (WebInspector.SourceFrame.prototype.afterTextChanged):
1481         (WebInspector.SourceFrame.prototype.populateTextAreaContextMenu):
1482         (WebInspector.SourceFrame.prototype.suggestedFileName):
1483         (WebInspector.SourceFrame.prototype.doubleClick):
1484         (WebInspector.SourceFrame.prototype.cancelEditing):
1485         (WebInspector.TextViewerDelegateForSourceFrame.prototype.doubleClick):
1486         (WebInspector.TextViewerDelegateForSourceFrame.prototype.beforeTextChanged):
1487         (WebInspector.TextViewerDelegateForSourceFrame.prototype.afterTextChanged):
1488         (WebInspector.TextViewerDelegateForSourceFrame.prototype.commitEditing):
1489         (WebInspector.TextViewerDelegateForSourceFrame.prototype.cancelEditing):
1490         (WebInspector.TextViewerDelegateForSourceFrame.prototype.populateLineGutterContextMenu):
1491         (WebInspector.TextViewerDelegateForSourceFrame.prototype.populateTextAreaContextMenu):
1492         (WebInspector.TextViewerDelegateForSourceFrame.prototype.suggestedFileName):
1493
1494 2011-07-12  Andrey Kosyakov  <caseq@chromium.org>
1495
1496         Web Inspector: remove more dead code from the Network panel
1497         https://bugs.webkit.org/show_bug.cgi?id=64291
1498
1499         Reviewed by Pavel Feldman.
1500
1501         * inspector/front-end/NetworkPanel.js:
1502         (WebInspector.NetworkPanel.prototype._toggleGridMode):
1503         (WebInspector.NetworkPanel.prototype._toggleViewingResourceMode):
1504         * inspector/front-end/networkPanel.css:
1505
1506 2011-07-12  Adam Roben  <aroben@apple.com>
1507
1508         Unreviewed, rolling out r90811.
1509         http://trac.webkit.org/changeset/90811
1510         https://bugs.webkit.org/show_bug.cgi?id=61025
1511
1512         Several svg tests failing assertions beneath
1513         SVGSMILElement::findInstanceTime
1514
1515         * svg/animation/SVGSMILElement.cpp:
1516         (WebCore::SVGSMILElement::findInstanceTime):
1517
1518 2011-07-12  Oliver Varga  <Varga.Oliver@stud.u-szeged.hu>
1519
1520         Reviewed by Nikolas Zimmermann.
1521
1522         Speed up SVGSMILElement::findInstanceTime.
1523         https://bugs.webkit.org/show_bug.cgi?id=61025
1524
1525         Replace the linear search to binary search on ordered list because
1526         the previous searches from the beginning was not efficient.
1527         Out of index error fixed by Renata Hodovan.
1528
1529         No new tests this is only a performance tweak.
1530
1531         * svg/animation/SVGSMILElement.cpp:
1532         (WebCore::extractTimeFromVector):
1533         (WebCore::SVGSMILElement::findInstanceTime):
1534
1535 2011-07-11  Zeng Huiqing  <huiqing.zeng@intel.com>
1536
1537         Optimize HTMLInputElement::updateCheckedRadioButtons
1538         https://bugs.webkit.org/show_bug.cgi?id=62840
1539
1540         Reviewed by Kent Tamura.
1541
1542         No new tests.
1543
1544         * dom/Document.h:
1545         (WebCore::Document::getFormElements):
1546         * html/HTMLInputElement.cpp:
1547         (WebCore::HTMLInputElement::updateCheckedRadioButtons):
1548         (WebCore::HTMLInputElement::setChecked):
1549
1550 2011-07-11  Pratik Solanki  <psolanki@apple.com>
1551
1552         Reviewed by David Kilzer.
1553
1554         Add NSURLRequest wrapper in ResourceRequest when USE(CFNETWORK) is enabled
1555         https://bugs.webkit.org/show_bug.cgi?id=63276
1556
1557         When USE(CFNETWORK) is enabled on Mac, keep an NSURLRequest object along with the
1558         CFURLRequestRef so that WebKit can continue using the NSURLRequest.
1559
1560         No new tests because no change in functionality and option is not enabled on Mac.
1561
1562         * platform/network/cf/ResourceRequest.h:
1563         (WebCore::ResourceRequest::updateNSURLRequest):
1564         (WebCore::ResourceRequest::ResourceRequest):
1565         * platform/network/cf/ResourceRequestCFNet.cpp:
1566         (WebCore::findCFURLRequestSetContentDispositionEncodingFallbackArrayFunction):
1567         (WebCore::findCFURLRequestCopyContentDispositionEncodingFallbackArrayFunction):
1568         (WebCore::ResourceRequest::doUpdatePlatformRequest):
1569         (WebCore::ResourceRequest::applyWebArchiveHackForMail):
1570         * platform/network/mac/ResourceRequestMac.mm:
1571         (WebCore::ResourceRequest::nsURLRequest):
1572         (WebCore::ResourceRequest::ResourceRequest):
1573         (WebCore::ResourceRequest::updateNSURLRequest):
1574
1575 2011-07-11  Ryosuke Niwa  <rniwa@webkit.org>
1576
1577         positionForPoint is broken when a block is positioned relatively inside the parent
1578         https://bugs.webkit.org/show_bug.cgi?id=64298
1579
1580         Reviewed by Simon Fraser.
1581
1582         The bug was caused by positionForPointRespectingEditingBoundaries's not taking relativePositionOffset
1583         into account when computing the point in child coordinates. Fixed the bug by adding the offset to
1584         childLocation as needed.
1585
1586         Test: fast/block/positioning/hittest-on-relative-positioned-children.html
1587
1588         * rendering/RenderBlock.cpp:
1589         (WebCore::positionForPointRespectingEditingBoundaries): Fixed the bug; also replaced all instances of
1590         IntPoint by LayoutPoint.
1591
1592 2011-07-11  Dan Bernstein  <mitz@apple.com>
1593
1594         Excessive expansion of justified text when rounding hacks are enabled
1595         https://bugs.webkit.org/show_bug.cgi?id=64331
1596
1597         Reviewed by Anders Carlsson.
1598
1599         Test: platform/mac/fast/text/rounding-hacks-expansion.html
1600
1601         When rounding hacks are enabled, the expansion at each expansion opportunity should be by an
1602         integer. Restored more of the logic that was removed in r78846 in order to ensure this.
1603
1604         * platform/graphics/WidthIterator.cpp:
1605         (WebCore::WidthIterator::advance):
1606         * platform/graphics/mac/ComplexTextController.cpp:
1607         (WebCore::ComplexTextController::adjustGlyphsAndAdvances):
1608
1609 2011-07-11  Jer Noble  <jer.noble@apple.com>
1610
1611         HTML5 video controller in fullscreen is partly off-screen (at least on youtube) using ClickToFlash
1612         https://bugs.webkit.org/show_bug.cgi?id=64327
1613
1614         Reviewed by Darin Adler.
1615
1616         No new tests; no change in functionality, so covered by existing tests.
1617
1618         Make the rules from fullscreenQuickTime.css !important so they are not overridden
1619         by page authors.
1620
1621         * css/fullscreenQuickTime.css:
1622         (video:-webkit-full-screen::-webkit-media-controls-panel):
1623
1624 2011-07-11  Levi Weintraub  <leviw@chromium.org>
1625
1626         Switch lineTop and lineBottom to new layout types
1627         https://bugs.webkit.org/show_bug.cgi?id=64317
1628
1629         Reviewed by Eric Seidel.
1630
1631         Changing lineTop and lineBottom to LayoutUnits and preparing all uses
1632         of them for the upcoming conversion.
1633
1634         No new tests, no new functionality.
1635
1636         * rendering/EllipsisBox.cpp:
1637         (WebCore::EllipsisBox::nodeAtPoint):
1638         * rendering/EllipsisBox.h:
1639         * rendering/GapRects.h:
1640         (WebCore::GapRects::left):
1641         (WebCore::GapRects::center):
1642         (WebCore::GapRects::right):
1643         (WebCore::GapRects::uniteLeft):
1644         (WebCore::GapRects::uniteCenter):
1645         (WebCore::GapRects::uniteRight):
1646         (WebCore::GapRects::operator LayoutRect):
1647         * rendering/InlineBox.cpp:
1648         (WebCore::InlineBox::nodeAtPoint):
1649         * rendering/InlineBox.h:
1650         * rendering/InlineFlowBox.cpp:
1651         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
1652         (WebCore::InlineFlowBox::flipLinesInBlockDirection):
1653         (WebCore::InlineFlowBox::computeOverflow):
1654         (WebCore::InlineFlowBox::setLayoutOverflow):
1655         (WebCore::InlineFlowBox::setVisualOverflow):
1656         (WebCore::InlineFlowBox::setOverflowFromLogicalRects):
1657         (WebCore::InlineFlowBox::nodeAtPoint):
1658         * rendering/InlineFlowBox.h:
1659         (WebCore::InlineFlowBox::layoutOverflowRect):
1660         (WebCore::InlineFlowBox::visualOverflowRect):
1661         * rendering/InlineTextBox.cpp:
1662         (WebCore::InlineTextBox::nodeAtPoint):
1663         * rendering/RenderLineBoxList.cpp:
1664         (WebCore::RenderLineBoxList::anyLineIntersectsRect):
1665         * rendering/RenderLineBoxList.h:
1666         * rendering/RenderListItem.cpp:
1667         (WebCore::RenderListItem::positionListMarker):
1668         * rendering/RenderTextControl.h:
1669         * rendering/RenderTextControlMultiLine.cpp:
1670         (WebCore::RenderTextControlMultiLine::adjustControlHeightBasedOnLineHeight):
1671         * rendering/RenderTextControlSingleLine.cpp:
1672         (WebCore::RenderTextControlSingleLine::adjustControlHeightBasedOnLineHeight):
1673         * rendering/RenderTextControlSingleLine.h:
1674         * rendering/RootInlineBox.cpp:
1675         (WebCore::RootInlineBox::nodeAtPoint):
1676         * rendering/RootInlineBox.h:
1677         (WebCore::RootInlineBox::lineTop):
1678         (WebCore::RootInlineBox::lineBottom):
1679         (WebCore::RootInlineBox::setLineTopBottomPositions):
1680         (WebCore::RootInlineBox::logicalTopVisualOverflow):
1681         (WebCore::RootInlineBox::logicalBottomVisualOverflow):
1682         (WebCore::RootInlineBox::logicalTopLayoutOverflow):
1683         (WebCore::RootInlineBox::logicalBottomLayoutOverflow):
1684         * rendering/svg/SVGInlineFlowBox.h:
1685         * rendering/svg/SVGInlineTextBox.cpp:
1686         (WebCore::SVGInlineTextBox::nodeAtPoint):
1687         * rendering/svg/SVGInlineTextBox.h:
1688         * rendering/svg/SVGRootInlineBox.h:
1689
1690 2011-07-11  Martin Robinson  <mrobinson@igalia.com>
1691
1692         Reviewed by Daniel Bates.
1693
1694         [GTK] Transition to Mozilla named cursors have incorrect hotspot and rendering
1695         https://bugs.webkit.org/show_bug.cgi?id=62752
1696
1697         Instead of offsetting the cursor blit by the hotspot, just pass the hotspot
1698         arguments to the GdkCursor constructor.
1699
1700         No new tests. This is covered by manual-tests/cursor.html.
1701
1702         * platform/gtk/CursorGtk.cpp:
1703         (WebCore::createNamedCursor):
1704
1705 2011-07-11  Yi Shen  <yi.4.shen@nokia.com>
1706
1707         [Qt] Unreviewed rollout 90779 which may fail the layout-test.
1708
1709         * platform/network/qt/QNetworkReplyHandler.cpp:
1710         (WebCore::QNetworkReplyHandlerCallQueue::setDeferSignals):
1711         * platform/network/qt/QNetworkReplyHandler.h:
1712
1713 2011-07-11  Bradley Nelson  <bradnelson@chromium.org>
1714
1715         Reviewed by Darin Fisher.
1716
1717         Split webcore_dom off webcore_remaining to reduce its size for
1718         whole program optimization builds.
1719
1720         https://bugs.webkit.org/show_bug.cgi?id=64299
1721
1722         * WebCore.gyp/WebCore.gyp:
1723
1724 2011-07-11  Yi Shen  <yi.4.shen@nokia.com>
1725
1726         [Qt] ASSERTION FAILED in ResourceHandle::setDefersLoading causes crash
1727         https://bugs.webkit.org/show_bug.cgi?id=62808
1728
1729         Reviewed by Benjamin Poulain.
1730
1731         The assertion in ResourceHandle::setDefersLoading assumes asynchronous
1732         content delivery -- To resume a page, first, its main resource loader
1733         calls setDefersLoading to resume loading the main content; then all the
1734         sub-resource loaders calls setDefersLoading to resume sub-contents.
1735         However, since QNetworkReplyHandler delivers content synchronously,
1736         some new sub-resource loaders get created as soon as the main resource
1737         loader resumed, and all these new sub-resource loaders set their
1738         defersLoading flag to false. Then, the assertion fails for these new
1739         sub-resource loaders when calling setDefersLoading on them. As a fix,
1740         this path makes QNetworkReplyHandler deliver content asynchronously.
1741
1742         Test: loader/load-defer-resume-crash.html
1743
1744         * platform/network/qt/QNetworkReplyHandler.cpp:
1745         (WebCore::QNetworkReplyHandlerCallQueue::setDeferSignals):
1746         * platform/network/qt/QNetworkReplyHandler.h:
1747
1748 2011-07-08  Ryosuke Niwa  <rniwa@webkit.org>
1749
1750         Move innerTextElement() from RenderTextControl to HTMLTextFormControlElement
1751         https://bugs.webkit.org/show_bug.cgi?id=64134
1752
1753         Reviewed by Kent Tamura.
1754
1755         Moved innerTextElement from RenderTextControl to HTMLTextFormControlElement. It is implemented by
1756         HTMLInputElement and HTMLTextAreaElement instead of RenderTextControlSingleLine and
1757         RenderTextControlMultiLine.
1758
1759         This refactoring removes the indirection through RenderTextControl and makes the ownership of
1760         shadow DOM for input and textarea elements clear. Accessing the shadow DOM of input and textarea elements
1761         are now less error prone because it no longer depends on the lifetime of the render tree.
1762
1763         * accessibility/AccessibilityRenderObject.cpp:
1764         (WebCore::AccessibilityRenderObject::indexForVisiblePosition): Access innerTextElement via
1765         HTMLTextFormControlElement.
1766         * dom/Node.cpp:
1767         (WebCore::traverseTreeAndMark): No longer calls innerTextElement because this was a work-around
1768         needed before making input and textarea elements use the new shadow DOM model.
1769         * editing/TextIterator.cpp:
1770         (WebCore::TextIterator::handleReplacedElement): Access innerTextElement via HTMLTextFormControlElement.
1771         * html/HTMLFormControlElement.cpp:
1772         (WebCore::hasVisibleTextArea): Takes innerTextElement.
1773         (WebCore::HTMLTextFormControlElement::setSelectionRange): Calls innerTextElement().
1774         (WebCore::HTMLTextFormControlElement::selection): Ditto.
1775         (WebCore::HTMLTextFormControlElement::selectionStart): Ditto; no longer uses a temporary local variable
1776         for innerTextElement because innerTextElement() no longer depends on the lifetime of the render tree.
1777         (WebCore::HTMLTextFormControlElement::selectionEnd): Ditto.
1778         * html/HTMLFormControlElement.h:
1779         * html/HTMLTextAreaElement.cpp:
1780         (WebCore::HTMLTextAreaElement::innerTextElement): Added.
1781         * html/HTMLTextAreaElement.h:
1782         * rendering/RenderTextControl.cpp:
1783         (WebCore::RenderTextControl::textFormControlElement): Made this function a const member.
1784         (WebCore::RenderTextControl::innerTextElement): Added.
1785         * rendering/RenderTextControl.h:
1786         * rendering/RenderTextControlMultiLine.cpp:
1787         * rendering/RenderTextControlMultiLine.h:
1788         * rendering/RenderTextControlSingleLine.cpp:
1789         * rendering/RenderTextControlSingleLine.h:
1790
1791 2011-07-11  Tony Chang  <tony@chromium.org>
1792
1793         rename RenderObject::isFlexibleBox to isDeprecatedFlexibleBox
1794         https://bugs.webkit.org/show_bug.cgi?id=64217
1795
1796         Reviewed by Ojan Vafai.
1797
1798         This is to make way for the new flexbox needing a similar method.
1799         RenderObject also has isFlexingChildren() and isStretchingChildren(),
1800         but we may be able to use those for the new flexbox as well so I
1801         didn't rename them.
1802
1803         No new tests, just refactoring.
1804
1805         * rendering/RenderBlock.cpp:
1806         (WebCore::RenderBlock::removeChild):
1807         (WebCore::RenderBlock::expandsToEncloseOverhangingFloats):
1808         (WebCore::shouldCheckLines):
1809         * rendering/RenderBox.cpp:
1810         (WebCore::RenderBox::removeFloatingOrPositionedChildFromBlockLists):
1811         (WebCore::RenderBox::computeLogicalWidth):
1812         (WebCore::RenderBox::sizesToIntrinsicLogicalWidth):
1813         (WebCore::RenderBox::computeLogicalHeight):
1814         * rendering/RenderDeprecatedFlexibleBox.cpp:
1815         (WebCore::RenderDeprecatedFlexibleBox::layoutBlock):
1816         * rendering/RenderDeprecatedFlexibleBox.h:
1817         (WebCore::RenderDeprecatedFlexibleBox::isDeprecatedFlexibleBox):
1818         * rendering/RenderObject.h:
1819         (WebCore::RenderObject::isDeprecatedFlexibleBox):
1820
1821 2011-07-11  Nate Chapin  <japhet@chromium.org>
1822
1823         [Chromium] Ensure we don't crash when an
1824         HTMLSelectElement mouse release event removes
1825         the element from the DOM.
1826         https://bugs.webkit.org/show_bug.cgi?id=64295
1827
1828         Reviewed by Dimitri Glazkov.
1829
1830         Manual test only because the crash requires a
1831         real popup menu, which DRT doesn't provide.
1832
1833         * manual-tests/chromium/popup-menu-crash.html: Added.
1834         * platform/chromium/PopupMenuChromium.cpp:
1835         (WebCore::PopupContainer::handleMouseReleaseEvent):
1836
1837 2011-07-11  Mike Reed  <reed@google.com>
1838
1839         [skia] remove platform helpers for gradients and patterns
1840         https://bugs.webkit.org/show_bug.cgi?id=64281
1841
1842         Reviewed by Stephen White.
1843
1844         No new tests. fixes canvas/philip/tests/2d.gradient.object.update.html
1845
1846         Remove (now empty) platform helpers for fill/stroke gradients/patterns. We now pickup the platformGradient
1847         and platformPattern fresh when they're needed, so we can see any edits that have occurred to them
1848         2d.gradient.object.update.html sets the fillgradient, and then edits the gradient object. This CL allows
1849         us to see that edit.
1850
1851         * platform/graphics/GraphicsContext.cpp:
1852         (WebCore::GraphicsContext::setStrokePattern):
1853         (WebCore::GraphicsContext::setFillPattern):
1854         (WebCore::GraphicsContext::setStrokeGradient):
1855         (WebCore::GraphicsContext::setFillGradient):
1856         * platform/graphics/GraphicsContext.h:
1857         * platform/graphics/skia/GraphicsContextSkia.cpp:
1858         (WebCore::GraphicsContext::platformInit):
1859         * platform/graphics/skia/PlatformContextSkia.cpp:
1860         (WebCore::PlatformContextSkia::State::State):
1861         (WebCore::PlatformContextSkia::State::~State):
1862         (WebCore::PlatformContextSkia::PlatformContextSkia):
1863         (WebCore::PlatformContextSkia::drawRect):
1864         (WebCore::PlatformContextSkia::setupShader):
1865         (WebCore::PlatformContextSkia::setupPaintForFilling):
1866         (WebCore::PlatformContextSkia::setupPaintForStroking):
1867         (WebCore::PlatformContextSkia::setFillColor):
1868         (WebCore::PlatformContextSkia::setStrokeColor):
1869         (WebCore::PlatformContextSkia::canAccelerate):
1870         * platform/graphics/skia/PlatformContextSkia.h:
1871         (WebCore::PlatformContextSkia::setGraphicsContext):
1872
1873 2011-07-11  Young Han Lee  <joybro@company100.net>
1874
1875         Reviewed by Simon Fraser.
1876
1877         Transition LayoutTest using pause API shows wrong result if it tries to pause a transition after its delay time.
1878         https://bugs.webkit.org/show_bug.cgi?id=63859
1879
1880         The existing code to set the m_startTime haven't worked because 
1881         the animation is not the right state to accept the start event. 
1882         This patch just sets the values directly instead of using event.
1883
1884         Test: transitions/delay.html
1885
1886         * page/animation/AnimationBase.cpp:
1887         (WebCore::AnimationBase::freezeAtTime):
1888
1889 2011-07-11  Ryosuke Niwa  <rniwa@webkit.org>
1890
1891         Move selection related code from RenderTextControl to HTMLTextFormControlElement
1892         https://bugs.webkit.org/show_bug.cgi?id=64133
1893
1894         Reviewed by Dimitri Glazkov.
1895
1896         Moved selectionStart, selectionEnd, hasVisibleTextArea, setSelectionRange, setContainerAndOffsetForRange
1897         and selection from RenderTextControl.cpp to HTMLFormControlElement.cpp.
1898
1899         This refactoring removes RenderTextControl's dependency on FrameSelection.
1900
1901         * accessibility/AccessibilityRenderObject.cpp:
1902         (WebCore::AccessibilityRenderObject::selectedText): Calls HTMLTextFromControl::selectedText.
1903         (WebCore::AccessibilityRenderObject::selectedTextRange): Calls selectionStart and selectionEnd.
1904         (WebCore::AccessibilityRenderObject::setSelectedTextRange): Ditto.
1905         * html/HTMLFormControlElement.cpp:
1906         (WebCore::HTMLTextFormControlElement::selectedText): Extracted from AccessibilityRenderObject::selectedText.
1907         (WebCore::hasVisibleTextArea): Added.
1908         (WebCore::HTMLTextFormControlElement::setSelectionRange): Merged with the function of the same name in RenderTextControl.
1909         (WebCore::HTMLTextFormControlElement::selectionStart): Calls computeSelectionStart instead of RenderTextControl::selectionStart.
1910         (WebCore::HTMLTextFormControlElement::computeSelectionStart): Moved from RenderTextControl::selectionStart.
1911         (WebCore::HTMLTextFormControlElement::selectionEnd): Calls computeSelectionEnd instead of RenderText::selectionEnd.
1912         (WebCore::HTMLTextFormControlElement::computeSelectionEnd): Moved from RenderTextControl::selectionStart.
1913         (WebCore::setContainerAndOffsetForRange): Moved from RenderTextControl.cpp.
1914         (WebCore::HTMLTextFormControlElement::selection): Merged with the function of the same name in RenderTextControl.
1915         (WebCore::HTMLTextFormControlElement::restoreCachedSelection): Calls computeSelectionStart and computeSelectionEnd instead of
1916         RenderTextControl::selectionStart and RenderTextControl::selectionEnd.
1917         (WebCore::HTMLTextFormControlElement::selectionChanged): Calls selectionStart and selectionEnd.
1918         * html/HTMLFormControlElement.h:
1919         * html/HTMLInputElement.cpp:
1920         (WebCore::HTMLInputElement::setValue): Calls setSelectionRange.
1921         * rendering/RenderTextControl.cpp:
1922         (WebCore::RenderTextControl::textFormControlElement): Added.
1923         * rendering/RenderTextControl.h:
1924
1925 2011-07-11  Andreas Kling  <kling@webkit.org>
1926
1927         Reviewed by Oliver Hunt.
1928
1929         Canvas: Use fast, approximate dirty rects for stroke()
1930         https://bugs.webkit.org/show_bug.cgi?id=59764
1931
1932         No new tests, this is an optimization.
1933
1934         * html/canvas/CanvasRenderingContext2D.cpp:
1935         (WebCore::CanvasRenderingContext2D::stroke): Instead of using
1936         Path::strokeBoundingRect() to calculate the exact bounding rect
1937         for a path stroke, get the Path::boundingRect() and inflate it by
1938         miterLimit + lineWidth to get a slightly oversized dirty rect
1939         in a fraction of the time.
1940
1941 2011-07-11  Andrey Kosyakov  <caseq@chromium.org>
1942
1943         Reviewed by Pavel Feldman.
1944
1945         Web Inspector: [refactoring] Remove dependencies of components requiring network resource list from network panel
1946         https://bugs.webkit.org/show_bug.cgi?id=62477
1947
1948         * inspector/front-end/AuditsPanel.js:
1949         * inspector/front-end/ExtensionServer.js:
1950         (WebInspector.ExtensionServer):
1951         (WebInspector.ExtensionServer.prototype._inspectedURLChanged):
1952         (WebInspector.ExtensionServer.prototype._onGetHAR):
1953         (WebInspector.ExtensionServer.prototype.initExtensions):
1954         * inspector/front-end/HAREntry.js:
1955         (WebInspector.HARLog):
1956         (WebInspector.HARLog.prototype.build):
1957         * inspector/front-end/NetworkManager.js:
1958         (WebInspector.NetworkLog):
1959         (WebInspector.NetworkLog.prototype.get resources):
1960         (WebInspector.NetworkLog.prototype._onInspectedURLChanged):
1961         (WebInspector.NetworkLog.prototype._onResourceStarted):
1962         * inspector/front-end/NetworkPanel.js:
1963         (WebInspector.NetworkPanel.prototype._reset):
1964         (WebInspector.NetworkPanel.prototype._copyAll):
1965         (WebInspector.NetworkPanel.prototype._exportAll):
1966         * inspector/front-end/inspector.js:
1967         (WebInspector.reset):
1968
1969 2011-07-11  Pavel Podivilov  <podivilov@chromium.org>
1970
1971         Web Inspector: make SourceFrame a View.
1972         https://bugs.webkit.org/show_bug.cgi?id=64274
1973
1974         Reviewed by Pavel Feldman.
1975
1976         * inspector/front-end/SourceFrame.js:
1977         (WebInspector.SourceFrame):
1978         (WebInspector.SourceFrame.createSearchRegex):
1979         (WebInspector.SourceFrame.prototype.show):
1980         (WebInspector.SourceFrame.prototype.hide):
1981         (WebInspector.SourceFrame.prototype._beforeTextChanged):
1982         (WebInspector.SourceFrame.prototype._afterTextChanged):
1983         (WebInspector.SourceFrame.prototype._initializeTextViewer):
1984         (WebInspector.SourceFrame.prototype.performSearch.doFindSearchMatches):
1985         (WebInspector.SourceFrame.prototype.performSearch):
1986         (WebInspector.SourceFrame.prototype._populateTextAreaContextMenu):
1987         (WebInspector.SourceFrame.prototype._suggestedFileName):
1988         (WebInspector.SourceFrame.prototype._doubleClick):
1989         (WebInspector.SourceFrame.prototype._cancelEditing):
1990         (WebInspector.TextViewerDelegateForSourceFrame):
1991         (WebInspector.TextViewerDelegateForSourceFrame.prototype.doubleClick):
1992         (WebInspector.TextViewerDelegateForSourceFrame.prototype.beforeTextChanged):
1993         (WebInspector.TextViewerDelegateForSourceFrame.prototype.afterTextChanged):
1994         (WebInspector.TextViewerDelegateForSourceFrame.prototype.commitEditing):
1995         (WebInspector.TextViewerDelegateForSourceFrame.prototype.cancelEditing):
1996         (WebInspector.TextViewerDelegateForSourceFrame.prototype.populateLineGutterContextMenu):
1997         (WebInspector.TextViewerDelegateForSourceFrame.prototype.populateTextAreaContextMenu):
1998         (WebInspector.TextViewerDelegateForSourceFrame.prototype.suggestedFileName):
1999         * inspector/front-end/TextViewer.js:
2000         (WebInspector.TextViewerDelegate.prototype.populateLineGutterContextMenu):
2001
2002 2011-07-11  Noel Gordon  <noel.gordon@gmail.com>
2003
2004         Reviewed by Adam Roben.
2005
2006         Forward focus events to windowless plugins on the windows port.
2007         https://bugs.webkit.org/show_bug.cgi?id=62375
2008
2009         * plugins/win/PluginViewWin.cpp:
2010         (WebCore::PluginView::setFocus): Forward focus events if the plugin is windowless.
2011
2012 2011-07-11  Shinya Kawanaka  <shinyak@google.com>
2013
2014         Added accessibility notification when value is changed.
2015         https://bugs.webkit.org/show_bug.cgi?id=64256
2016
2017         Notifies the value change of range input when accessibility is enabled.
2018
2019         Reviewed by Kent Tamura.
2020
2021         Covered by existing tests.
2022
2023         * html/RangeInputType.cpp:
2024         (WebCore::RangeInputType::handleKeydownEvent):
2025           Added accessibility notification when value is changed.
2026
2027 2011-07-08  Mikhail Naganov  <mnaganov@chromium.org>
2028
2029         Web Inspector: Fix resizing of sidebar pane in Timeline and Profile panels.
2030         https://bugs.webkit.org/show_bug.cgi?id=64161
2031
2032         Reviewed by Pavel Feldman.
2033
2034         * inspector/front-end/ProfilesPanel.js:
2035         (WebInspector.ProfilesPanel.prototype.updateMainViewWidth):
2036         * inspector/front-end/TimelineOverviewPane.js:
2037         (WebInspector.TimelineOverviewPane.prototype.updateMainViewWidth):
2038
2039 2011-07-11  Pavel Feldman  <pfeldman@google.com>
2040
2041         Web Inspector: [REGRESSION r89753-89754] highlight does not respect scroller location.
2042         https://bugs.webkit.org/show_bug.cgi?id=63982
2043
2044         Rolling out 89760, 89756, 89754, 89753 for breaking inspector highlight.
2045
2046         Reviewed by Yury Semikhatsky.
2047
2048         * WebCore.exp.in:
2049         * inspector/DOMNodeHighlighter.cpp:
2050         (WebCore::DOMNodeHighlighter::drawNodeHighlight):
2051         * page/FrameView.cpp:
2052         * page/FrameView.h:
2053         * platform/ScrollView.h:
2054         * platform/Widget.cpp:
2055         * platform/Widget.h:
2056         * rendering/RenderBox.cpp:
2057         (WebCore::RenderBox::mapLocalToContainer):
2058         * rendering/RenderBox.h:
2059         * rendering/RenderInline.cpp:
2060         (WebCore::RenderInline::mapLocalToContainer):
2061         * rendering/RenderInline.h:
2062         * rendering/RenderObject.cpp:
2063         (WebCore::RenderObject::mapLocalToContainer):
2064         (WebCore::RenderObject::localToContainerQuad):
2065         * rendering/RenderObject.h:
2066         (WebCore::RenderObject::localToAbsoluteQuad):
2067         * rendering/RenderView.cpp:
2068         (WebCore::RenderView::mapLocalToContainer):
2069         * rendering/RenderView.h:
2070         * rendering/svg/RenderSVGForeignObject.cpp:
2071         (WebCore::RenderSVGForeignObject::mapLocalToContainer):
2072         * rendering/svg/RenderSVGForeignObject.h:
2073         * rendering/svg/RenderSVGInline.cpp:
2074         (WebCore::RenderSVGInline::mapLocalToContainer):
2075         * rendering/svg/RenderSVGInline.h:
2076         * rendering/svg/RenderSVGModelObject.cpp:
2077         (WebCore::RenderSVGModelObject::mapLocalToContainer):
2078         * rendering/svg/RenderSVGModelObject.h:
2079         * rendering/svg/RenderSVGRoot.cpp:
2080         (WebCore::RenderSVGRoot::mapLocalToContainer):
2081         * rendering/svg/RenderSVGRoot.h:
2082         * rendering/svg/RenderSVGText.cpp:
2083         (WebCore::RenderSVGText::mapLocalToContainer):
2084         * rendering/svg/RenderSVGText.h:
2085         * rendering/svg/SVGRenderSupport.cpp:
2086         (WebCore::SVGRenderSupport::mapLocalToContainer):
2087         * rendering/svg/SVGRenderSupport.h:
2088
2089 2011-07-11  Mustafizur Rahaman  <mustaf.here@gmail.com>
2090
2091         Reviewed by James Robinson.
2092
2093         Fix LayoutTests/canvas/philip/tests/2d.composite.uncovered.fill.destination-atop.html
2094         https://bugs.webkit.org/show_bug.cgi?id=48292
2095         
2096         and
2097         
2098         Fix LayoutTests/canvas/philip/tests/2d.composite.uncovered.pattern.destination-atop.html
2099         https://bugs.webkit.org/show_bug.cgi?id=48302
2100
2101         * html/canvas/CanvasRenderingContext2D.cpp:
2102         (WebCore::CanvasRenderingContext2D::shouldDisplayTransparencyElsewhere): Added CompositeDestinationAtop 
2103         to draw transparency elsewhere for destination-atop
2104
2105 2011-07-08  Mikhail Naganov  <mnaganov@chromium.org>
2106
2107         Web Inspector: [Chromium] Get rid of flickering "Please wait" message in Heap profiler.
2108         https://bugs.webkit.org/show_bug.cgi?id=61175
2109
2110         The message has been replaced with spinner icons appearing instead of profile's
2111         icon. As each profile owns a worker, they run independently, and there can be
2112         multiple spinners at the same time.
2113
2114         Reviewed by Pavel Feldman.
2115
2116         * WebCore.gypi:
2117         * WebCore.vcproj/WebCore.vcproj:
2118         * inspector/front-end/DetailedHeapshotGridNodes.js:
2119         (WebInspector.HeapSnapshotGridNode.prototype._populate.sorted):
2120         (WebInspector.HeapSnapshotGridNode.prototype._populate):
2121         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren.childrenRetrieved):
2122         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren):
2123         * inspector/front-end/DetailedHeapshotView.js:
2124         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged):
2125         (WebInspector.HeapSnapshotRetainingPathsList.prototype.showNext):
2126         (WebInspector.HeapSnapshotRetainingPathsList.prototype.searchCancelled):
2127         (WebInspector.DetailedHeapshotView.profileCallback):
2128         (WebInspector.DetailedHeapshotView):
2129         (WebInspector.DetailedHeapshotView.prototype._changeBase.baseProfileLoaded):
2130         (WebInspector.DetailedHeapshotView.prototype._changeBase):
2131         (WebInspector.DetailedHeapshotView.prototype.processLoadedSnapshot):
2132         (WebInspector.DetailedHeapshotView.prototype._changeView):
2133         * inspector/front-end/HeapSnapshotProxy.js:
2134         (WebInspector.HeapSnapshotWorker):
2135         (WebInspector.HeapSnapshotWorker.prototype.dispose):
2136         (WebInspector.HeapSnapshotWorker.prototype.startCheckingForLongRunningCalls):
2137         (WebInspector.HeapSnapshotWorker.prototype._checkLongRunningCalls):
2138         (WebInspector.HeapSnapshotProxyObject.prototype.callMethod):
2139         (WebInspector.HeapSnapshotProxyObject.prototype.get worker):
2140         * inspector/front-end/Images/spinnerActive.gif: Added. Generated using ajaxload.info.
2141         * inspector/front-end/Images/spinnerActiveSelected.gif: Added. Generated using ajaxload.info.
2142         * inspector/front-end/Images/spinnerInactive.gif: Added. Generated using ajaxload.info.
2143         * inspector/front-end/Images/spinnerInactiveSelected.gif: Added. Generated using ajaxload.info.
2144         * inspector/front-end/PleaseWaitMessage.js: Removed.
2145         * inspector/front-end/ProfilesPanel.js:
2146         (WebInspector.ProfilesPanel.prototype._addProfileHeader):
2147         (WebInspector.ProfilesPanel.prototype.loadHeapSnapshot.setProfileWait):
2148         (WebInspector.ProfilesPanel.prototype.loadHeapSnapshot):
2149         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot.parsed):
2150         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot):
2151         (WebInspector.ProfilesPanel.prototype._reportHeapSnapshotProgress):
2152         * inspector/front-end/SidebarTreeElement.js:
2153         (WebInspector.SidebarTreeElement.prototype.set wait):
2154         * inspector/front-end/WebKit.qrc:
2155         * inspector/front-end/heapProfiler.css:
2156         (.heap-snapshot-sidebar-tree-item.wait .icon):
2157         (.heap-snapshot-sidebar-tree-item.wait.selected .icon):
2158         (body.inactive .heap-snapshot-sidebar-tree-item.wait .icon):
2159         (body.inactive .heap-snapshot-sidebar-tree-item.wait.selected .icon):
2160         * inspector/front-end/inspector.html:
2161
2162 2011-07-10  Patrick Gansterer  <paroga@webkit.org>
2163
2164         Generate conditional include statements in CodeGeneratorJS
2165         https://bugs.webkit.org/show_bug.cgi?id=64231
2166
2167         Reviewed by Brent Fulgham.
2168
2169         Suround headers with a correspondig #if ENABLE() line.
2170         This allows us to generate bindings only of required IDL files.
2171
2172         Changing the current preprocessor statements to the Conditional attribute
2173         in a next step helps in getting rid of calls to the preprocessor,
2174         which causes so much pain on a natvie Windows environment. 
2175
2176         * bindings/scripts/CodeGeneratorJS.pm:
2177         (GenerateImplementation):
2178         (WriteData):
2179
2180 2011-07-10  Patrick Gansterer  <paroga@webkit.org>
2181
2182         Remove array size from generated JSC binding tables
2183         https://bugs.webkit.org/show_bug.cgi?id=64229
2184
2185         Reviewed by Brent Fulgham.
2186
2187         Because many items in the array are surrounded with #if(ENABLE_XXX) lines,
2188         the array size isn't fix and correct in all cases.
2189         So let the compiler calculate the correct size itself.
2190
2191         * bindings/scripts/CodeGeneratorJS.pm:
2192         (GenerateHashTable):
2193         * bindings/scripts/test/JS/JSTestInterface.cpp:
2194         * bindings/scripts/test/JS/JSTestMediaQueryListListener.cpp:
2195         * bindings/scripts/test/JS/JSTestObj.cpp:
2196         * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
2197
2198 2011-07-10  Kenichi Ishibashi  <bashi@chromium.org>
2199
2200         Let plugins participate in form submission
2201         https://bugs.webkit.org/show_bug.cgi?id=13061
2202
2203         Implements HTMLObjectElement::appendFormData() so that object
2204         elements respond as form associated elements.
2205
2206         Reviewed by Anders Carlsson.
2207
2208         Test: plugins/form-value.html
2209
2210         * html/HTMLObjectElement.cpp:
2211         (WebCore::HTMLObjectElement::appendFormData): Implemented.
2212         * plugins/PluginViewBase.h:
2213         (WebCore::PluginViewBase::getFormValue): Added.
2214
2215 2011-07-10  Anders Carlsson  <andersca@apple.com>
2216
2217         WebKit2 is leaking NSCursors created by leakNamedCursor
2218         https://bugs.webkit.org/show_bug.cgi?id=64241
2219         <rdar://problem/9507151>
2220
2221         Reviewed by Oliver Hunt.
2222
2223         * platform/mac/CursorMac.mm:
2224         (WebCore::createNamedCursor):
2225         Rename this from leakNamedCursor to createNamedCursor and make it return a
2226         RetainPtr<NSCursor> instead of a raw pointer.
2227
2228         (WebCore::Cursor::ensurePlatformCursor):
2229         Don't leak cursors here. We still won't deallocate cursors during shutdown (which leakNamedCursor
2230         was said to prevent) because the cursor singletons are all allocated from the heap and are never destroyed
2231         anyway.
2232
2233 2011-07-10  Yuta Kitamura  <yutak@chromium.org>
2234
2235         WebSocket: Add useHixie76Protocol flag to WebSocketChannel and WebSocketHandshake
2236         https://bugs.webkit.org/show_bug.cgi?id=64244
2237
2238         Reviewed by Kent Tamura.
2239
2240         Get the value of Settings::useHixie76WebSocketProtocol() and save it in
2241         WebSocketChannel and WebSocketHandshake instances. Obtained flag value
2242         is not used for now.
2243
2244         No behavior change, thus no new tests.
2245
2246         * websockets/WebSocketChannel.cpp:
2247         (WebCore::WebSocketChannel::WebSocketChannel):
2248         WebSocketChannel is always created in context of Document (see
2249         ThreadableWebSocketChannel::create()).
2250         Because m_useHixie76Protocol must be passed to WebSocketHandshake
2251         constructor, WebSocketHandshake instance is allocated dynamically
2252         and stored in OwnPtr.
2253         (WebCore::WebSocketChannel::connect):
2254         (WebCore::WebSocketChannel::fail):
2255         (WebCore::WebSocketChannel::disconnect):
2256         (WebCore::WebSocketChannel::didOpen):
2257         (WebCore::WebSocketChannel::didFail):
2258         (WebCore::WebSocketChannel::processBuffer):
2259         * websockets/WebSocketChannel.h:
2260         * websockets/WebSocketHandshake.cpp:
2261         (WebCore::WebSocketHandshake::WebSocketHandshake):
2262         * websockets/WebSocketHandshake.h:
2263
2264 2011-07-10  Tom Hudson  <tomhudson@google.com>
2265
2266         Reviewed by James Robinson.
2267
2268         GraphicsContextSkia::drawConvexPolygon doesn't pay attention to shouldAntialias
2269         https://bugs.webkit.org/show_bug.cgi?id=61369
2270
2271         * platform/graphics/skia/GraphicsContextSkia.cpp:
2272         (WebCore::GraphicsContext::drawConvexPolygon): Pass the
2273         shouldAntialias parameter on to Skia.
2274
2275 2011-07-10  Yuzo Fujishima  <yuzo@google.com>
2276
2277         Fix for Bug 63968 - Add comment to explain Vector usage in FontCache::purgeInactiveFontData
2278         https://bugs.webkit.org/show_bug.cgi?id=63968
2279
2280         Reviewed by Dan Bernstein.
2281
2282         No new tests because this changes comments only.
2283
2284         * platform/graphics/FontCache.cpp:
2285         (WebCore::FontCache::purgeInactiveFontData): Add explanation why SimpleFontData is not deleted in the iteration loop.
2286
2287 2011-07-10  Emil A Eklund  <eae@chromium.org>
2288
2289         Switch updateHitTestResult to to new layout types
2290         https://bugs.webkit.org/show_bug.cgi?id=64209
2291
2292         Reviewed by Eric Seidel.
2293
2294         No new tests, no functionality changes.
2295
2296         * rendering/EllipsisBox.cpp:
2297         (WebCore::EllipsisBox::nodeAtPoint):
2298         * rendering/RenderBlock.cpp:
2299         (WebCore::RenderBlock::hitTestFloats):
2300         (WebCore::RenderBlock::updateHitTestResult):
2301         * rendering/RenderBlock.h:
2302         * rendering/RenderInline.cpp:
2303         (WebCore::RenderInline::updateHitTestResult):
2304         * rendering/RenderInline.h:
2305         * rendering/RenderLineBoxList.cpp:
2306         (WebCore::RenderLineBoxList::hitTest):
2307         * rendering/RenderObject.cpp:
2308         (WebCore::RenderObject::updateHitTestResult):
2309         * rendering/RenderObject.h:
2310         * rendering/RenderView.cpp:
2311         (WebCore::RenderView::updateHitTestResult):
2312         * rendering/RenderView.h:
2313         * rendering/svg/RenderSVGContainer.cpp:
2314         (WebCore::RenderSVGContainer::nodeAtFloatPoint):
2315         * rendering/svg/RenderSVGImage.cpp:
2316         (WebCore::RenderSVGImage::nodeAtFloatPoint):
2317         * rendering/svg/RenderSVGPath.cpp:
2318         (WebCore::RenderSVGPath::nodeAtFloatPoint):
2319         * rendering/svg/RenderSVGRoot.cpp:
2320         (WebCore::RenderSVGRoot::nodeAtPoint):
2321
2322 2011-07-10  Patrick Gansterer  <paroga@webkit.org>
2323
2324         Reviewed by Adam Barth.
2325
2326         Fix member variable order of ContextMenuItem
2327         https://bugs.webkit.org/show_bug.cgi?id=59905
2328
2329         Use the same order at decleration and assignment to silence compiler warning.
2330
2331         * platform/ContextMenuItem.h:
2332
2333 2011-07-10  Dan Bernstein  <mitz@apple.com>
2334
2335         <rdar://problem/9750062> REGRESSION: Button text missing in many iTunes Store pages
2336         https://bugs.webkit.org/show_bug.cgi?id=64236
2337
2338         Reviewed by Maciej Stachowiak.
2339
2340         Test: fast/css/empty-display-none.html
2341
2342         When an :empty selector caused an element to not have a renderer, the check for empty style
2343         change when finishing parsing the elemenet did nothing, because it could not check if the
2344         element’s current style was affected by :empty. The fix is to record the fact that the style
2345         was affected by :empty in ElementRareData in the no-renderer case.
2346
2347         * dom/Element.cpp:
2348         (WebCore::Element::recalcStyle): Clear the m_styleAffectedByEmpty flag.
2349         (WebCore::checkForEmptyStyleChange): If the style is null (meaning there is no renderer), check
2350         Element::styleAffectedByEmpty().
2351         (WebCore::Element::setStyleAffectedByEmpty): Added. Sets the flag in rare data.
2352         (WebCore::Element::styleAffectedByEmpty): Added. Checks for the flag in rare data.
2353         * dom/Element.h:
2354         * dom/ElementRareData.h:
2355         (WebCore::ElementRareData::ElementRareData): Added m_styleAffectedByEmpty and initialized it
2356         to false.
2357         * dom/NodeRenderingContext.cpp:
2358         (WebCore::NodeRendererFactory::createRendererAndStyle): If an element doesn’t need a renderer
2359         and its style is affected by :empty, record this fact in the element by calling setStyleAffectedByEmpty().
2360
2361 2011-07-10  Mark Rowe  <mrowe@apple.com>
2362
2363         Fix the build.
2364
2365         * svg/properties/SVGAttributeToPropertyMap.h: Forward-declare SVGPropertyInfo as a struct
2366         since that's what it is.
2367
2368 2011-07-09  Patrick Gansterer  <paroga@webkit.org>
2369
2370         Unreviewed WinCE build fix for r90680.
2371
2372         Repeat the change done in r90681 for all other SVGAnimated*PropertyTearOff.h files.
2373
2374         * svg/properties/SVGAnimatedEnumerationPropertyTearOff.h: Make create public and remove friendship with SVGAnimatedProperty.
2375         * svg/properties/SVGAnimatedListPropertyTearOff.h: Ditto.
2376         * svg/properties/SVGAnimatedPathSegListPropertyTearOff.h: Ditto.
2377         * svg/properties/SVGAnimatedPropertyTearOff.h: Ditto.
2378         * svg/properties/SVGAnimatedTransformListPropertyTearOff.h: Ditto.
2379
2380 2011-07-09  Nikolas Zimmermann  <nzimmermann@rim.com>
2381
2382         Add a possibility to retrieve the associated SVGAnimatedProperty object for a certain XML attribute
2383         https://bugs.webkit.org/show_bug.cgi?id=63797
2384
2385         Fix WinCE build. Funny none other platform complained.
2386
2387         * svg/properties/SVGAnimatedStaticPropertyTearOff.h: Make create public, SVGAnimatedProperty needs it - remove friendship with it.
2388
2389 2011-07-09  Nikolas Zimmermann  <nzimmermann@rim.com>
2390
2391         Add a possibility to retrieve the associated SVGAnimatedProperty object for a certain XML attribute
2392         https://bugs.webkit.org/show_bug.cgi?id=63797
2393
2394         Reviewed by Dirk Schulze.
2395
2396         In order to prepare animVal support we need a way to map a given SVG DOM attribute to a SVGAnimatedProperty.
2397         eg. SVGNames::xAttr -> SVGRectElement::xAnimated(), etc. This will be needed to update the animVal of the
2398         SVGAnimatedProperty, if an animation is running. It would required adding a new method to all SVG* classes
2399         that define animated properties. Unfortunately we already have lots of repeated code in methods like
2400         synchronizeProperty / fillAttributeToPropertyTypeMap. Look at SVGRectElement for example:
2401
2402         void SVGRectElement::synchronizeProperty(const QualifiedName& attrName)
2403         {
2404             if (attrName == anyQName()) {
2405                 synchronizeX();
2406                 synchronizeY();
2407                  ...
2408               }
2409
2410             if (attrName == SVGNames::xAttr) {
2411                 synchronizeX();
2412                 return;
2413             }
2414
2415             if (attrName == SVGNames::yAttr) {
2416                 synchronizeY();
2417                 return;
2418             }
2419             ...
2420         }
2421
2422         or
2423
2424         void SVGRectElement::fillAttributeToPropertyTypeMap()
2425         {
2426             AttributeToPropertyTypeMap& attributeToPropertyTypeMap = this->attributeToPropertyTypeMap();
2427         
2428             SVGStyledTransformableElement::fillPassedAttributeToPropertyTypeMap(attributeToPropertyTypeMap);
2429             attributeToPropertyTypeMap.set(SVGNames::xAttr, AnimatedLength);
2430             attributeToPropertyTypeMap.set(SVGNames::yAttr, AnimatedLength);
2431             ...
2432         }
2433
2434         These lookups are all performed dynamically. Each synchronizeProperty() call does a lot of comparisons.
2435         fillAttributeToPropertyTypeMap() isn't that bad as the result is cached in a static HashMap per-SVGRectElement.
2436         There's no reason to do these things dynamically!
2437
2438         Inspired by JSC, I'm adding a "static const SVGPropertyInfo s_fooPropertyInfo" object for each animated SVG property.
2439         For example, for SVGRectElements SVGAnimatedLength x property we're storing:
2440         - "AnimatedPropertyType type" (AnimatedLength -- note the enum was named AnimatedAttributeType, I renamed it to AnimatedPropertyType for clarity)
2441         - "const QualifiedName& attributeName" (SVGNames::xAttr)
2442         - "const AtomicString& propertyIdentifier" (SVGNames::xAttr.localName() -- only different if N-wrappers map to a single XML DOM attribute, eg. orientAttr)
2443         - "SynchronizeProperty synchronizeProperty" (callback to SVGRectElement::synchronizeX)
2444         - "LookupOrCreateWrapperForAnimatedProperty lookupOrCreateWrapperForAnimatedProperty" (callback to SVGRectElement::xAnimated)
2445
2446         Using this information, we can replace all the various synchronizeProperty/fillAttributeToPropertyMap implementations, with a single one in SVGElement.
2447         All these are auto-generated, using the standard macros used to define/declare SVG animated properties. This required several changes to the macros.
2448         Here's a summary:
2449     
2450         #1) In all headers, wrap DECLARE_ANIMATED_* calls, in BEGIN_DECLARE_ANIMATED_PROPERTIES(ClassName) / END_DECLARE_ANIMATED_PROPERTIES blocks.
2451         
2452             Sample change for SVGRectElement:
2453             -    DECLARE_ANIMATED_LENGTH(X, x)
2454             -    DECLARE_ANIMATED_LENGTH(Y, y)
2455             -    ...
2456
2457             +    BEGIN_DECLARE_ANIMATED_PROPERTIES(SVGRectElement)
2458             +        DECLARE_ANIMATED_LENGTH(X, x)
2459             +        DECLARE_ANIMATED_LENGTH(Y, y)
2460             +         ...
2461             +    END_DECLARE_ANIMATED_PROPERTIES
2462
2463         #2) In all cpp files, add a new section wrapped in BEGIN_REGISTER_ANIMATED_PROPERTIES(ClassName / END_REGISTER_ANIMATED_PROPERTIES blocks:
2464
2465             Sample change for SVGRectElement:
2466             +BEGIN_REGISTER_ANIMATED_PROPERTIES(SVGRectElement)
2467             +    REGISTER_LOCAL_ANIMATED_PROPERTY(x)
2468             +    REGISTER_LOCAL_ANIMATED_PROPERTY(y)
2469             +    ...
2470             +    REGISTER_PARENT_ANIMATED_PROPERTIES(SVGStyledTransformableElement)
2471             +    REGISTER_PARENT_ANIMATED_PROPERTIES(SVGTests)
2472             +END_REGISTER_ANIMATED_PROPERTIES
2473
2474             This is the main piece of the logic that replaces the manual synchronizeProperty/fillAttributeToPropertyMap implementation. It expands to following:
2475
2476             SVGAttributeToPropertyMap& SVGRectElement::attributeToPropertyMap()
2477             {
2478                 DEFINE_STATIC_LOCAL(SVGAttributeToPropertyMap, s_attributeToPropertyMap, ());
2479             }
2480
2481             static void registerAnimatedPropertiesForSVGRectElement()
2482             {
2483                 SVGAttributeToPropertyMap& map = SVGRectElement::attributeToPropertyMap();
2484                 if (!map.isEmpty())
2485                     return;
2486                 map.addProperty(SVGRectElement::xPropertyInfo());
2487                 map.addProperty(SVGRectElement::yPropertyInfo());
2488                 ...
2489                 map.addProperties(SVGStyledTransformableElement::attributeToPropertyMap());
2490                 map.addProperties(SVGTests::attributeToPropertyMap());
2491             }
2492
2493             A single-instance of SVGAttributeToPropertyMap is created for each SVG*Element. The constructor of SVGRectElement is supposed to call
2494             registerAnimatedPropertiesForSVGRectElement(), which collects all properties of SVGRectElement and all its parent classes and stores them
2495             in a Vector<const SVGPropertyInfo*>. This Vector is stored in a HashMap<QualifiedName, Vector<const SVGPropertyInfo*> > where the key
2496             is the attribute name (eg. SVGNames::xAttr -> SVGRectElement::xPropertyInfo). This is only done _once_ per SVGRectElement.
2497
2498             SVGElement contains a "virtual SVGAttributeToPropertyMap& localAttributeToPropertyMap()" method, and SVGRectElement overrides it
2499             and returns SVGRectElement::attributeToPropertyMap() (which is static!) -- this is hidden again in the macros, no need to write any code.
2500
2501             SVGAttributeToPropertyMap provides following API:
2502             - bool synchronizeProperty(SVGElement* contextElement, const QualifiedName& attributeName)
2503             - void synchronizeProperties(SVGElement* contextElement)
2504             
2505                 A generic way to synchronize a SVGAnimatedProperty with its XML DOM attribute. Any SVG DOM change to eg. <rect>s x property will now trigger
2506                 contextElement->localAttributeToPropertyMap().synchronizeProperty(this, SVGNames::xAttr)
2507                 The SVGAttributeToPropertyMap will ask its HashMap for the Vector containing the properties for SVGNames::xAttr (in that case, just one xAnimated()).
2508
2509             - void animatedPropertyTypeForAttribute(const QualifiedName& attributeName, Vector<AnimatedPropertyType>& propertyTypes)
2510
2511                 This method replaces the fillAttributeToPropertyMap implementations everywhere.
2512         
2513             - void animatedPropertiesForAttribute(SVGElement* contextElement, const QualifiedName& attributeName, Vector<RefPtr<SVGAnimatedProperty> >& properties);
2514
2515                 This method is not used yet, but allows us to collect all SVGAnimatedProperties for a QualifiedName -- the initial goal for this patch.
2516
2517         #3) In all cpp files, add a call to "registerAnimatedPropertiesForClassName()" in the constructor. Forgetting this will result in a compile error.
2518
2519         Doesn't affect any tests.
2520
2521         * CMakeLists.txt:
2522         * GNUmakefile.list.am:
2523         * WebCore.gypi:
2524         * WebCore.pro:
2525         * WebCore.vcproj/WebCore.vcproj:
2526         * WebCore.xcodeproj/project.pbxproj:
2527         * bindings/scripts/CodeGeneratorJS.pm:
2528         (NativeToJSValue):
2529         * bindings/scripts/CodeGeneratorObjC.pm:
2530         (GenerateImplementation):
2531         * bindings/scripts/CodeGeneratorV8.pm:
2532         (GenerateNormalAttrGetter):
2533         * svg/SVGAElement.cpp:
2534         (WebCore::SVGAElement::SVGAElement):
2535         * svg/SVGAElement.h:
2536         (WebCore::SVGAElement::synchronizeRequiredFeatures):
2537         (WebCore::SVGAElement::synchronizeRequiredExtensions):
2538         (WebCore::SVGAElement::synchronizeSystemLanguage):
2539         * svg/SVGAltGlyphElement.cpp:
2540         (WebCore::SVGAltGlyphElement::SVGAltGlyphElement):
2541         * svg/SVGAltGlyphElement.h:
2542         * svg/SVGAnimateElement.cpp:
2543         (WebCore::SVGAnimateElement::SVGAnimateElement):
2544         (WebCore::SVGAnimateElement::hasValidAttributeType):
2545         (WebCore::SVGAnimateElement::determineAnimatedPropertyType):
2546         (WebCore::SVGAnimateElement::determinePropertyValueTypes):
2547         (WebCore::SVGAnimateElement::calculateAnimatedValue):
2548         (WebCore::SVGAnimateElement::calculateFromAndToValues):
2549         (WebCore::SVGAnimateElement::calculateFromAndByValues):
2550         (WebCore::SVGAnimateElement::resetToBaseValue):
2551         (WebCore::SVGAnimateElement::applyResultsToTarget):
2552         (WebCore::SVGAnimateElement::calculateDistance):
2553         (WebCore::SVGAnimateElement::ensureAnimator):
2554         * svg/SVGAnimateElement.h:
2555         * svg/SVGAnimateTransformElement.cpp:
2556         (WebCore::SVGAnimateTransformElement::hasValidAttributeType):
2557         (WebCore::SVGAnimateTransformElement::determineAnimatedPropertyType):
2558         (WebCore::SVGAnimateTransformElement::resetToBaseValue):
2559         (WebCore::SVGAnimateTransformElement::calculateAnimatedValue):
2560         (WebCore::SVGAnimateTransformElement::applyResultsToTarget):
2561         * svg/SVGAnimateTransformElement.h:
2562         * svg/SVGAnimatedAngle.h:
2563         * svg/SVGAnimatedBoolean.h:
2564         * svg/SVGAnimatedEnumeration.h:
2565         * svg/SVGAnimatedInteger.h:
2566         * svg/SVGAnimatedLength.h:
2567         * svg/SVGAnimatedLengthList.h:
2568         * svg/SVGAnimatedNumber.h:
2569         * svg/SVGAnimatedNumberList.h:
2570         * svg/SVGAnimatedPreserveAspectRatio.h:
2571         * svg/SVGAnimatedRect.h:
2572         * svg/SVGAnimatedString.h:
2573         * svg/SVGAnimatedTransformList.h:
2574         * svg/SVGAnimatedType.cpp:
2575         (WebCore::SVGAnimatedType::SVGAnimatedType):
2576         * svg/SVGAnimatedType.h:
2577         (WebCore::SVGAnimatedType::type):
2578         * svg/SVGAnimatedTypeAnimator.h:
2579         (WebCore::SVGAnimatedTypeAnimator::SVGAnimatedTypeAnimator):
2580         * svg/SVGAnimationElement.cpp:
2581         (WebCore::SVGAnimationElement::SVGAnimationElement):
2582         (WebCore::SVGAnimationElement::currentValuesForValuesAnimation):
2583         * svg/SVGAnimationElement.h:
2584         (WebCore::SVGAnimationElement::synchronizeRequiredFeatures):
2585         (WebCore::SVGAnimationElement::synchronizeRequiredExtensions):
2586         (WebCore::SVGAnimationElement::synchronizeSystemLanguage):
2587         * svg/SVGAnimatorFactory.h:
2588         (WebCore::SVGAnimatorFactory::create):
2589         * svg/SVGCircleElement.cpp:
2590         (WebCore::SVGCircleElement::SVGCircleElement):
2591         * svg/SVGCircleElement.h:
2592         (WebCore::SVGCircleElement::synchronizeRequiredFeatures):
2593         (WebCore::SVGCircleElement::synchronizeRequiredExtensions):
2594         (WebCore::SVGCircleElement::synchronizeSystemLanguage):
2595         * svg/SVGClipPathElement.cpp:
2596         (WebCore::SVGClipPathElement::SVGClipPathElement):
2597         * svg/SVGClipPathElement.h:
2598         (WebCore::SVGClipPathElement::synchronizeRequiredFeatures):
2599         (WebCore::SVGClipPathElement::synchronizeRequiredExtensions):
2600         (WebCore::SVGClipPathElement::synchronizeSystemLanguage):
2601         * svg/SVGComponentTransferFunctionElement.cpp:
2602         (WebCore::SVGComponentTransferFunctionElement::SVGComponentTransferFunctionElement):
2603         * svg/SVGComponentTransferFunctionElement.h:
2604         * svg/SVGCursorElement.cpp:
2605         (WebCore::SVGCursorElement::SVGCursorElement):
2606         * svg/SVGCursorElement.h:
2607         (WebCore::SVGCursorElement::synchronizeRequiredFeatures):
2608         (WebCore::SVGCursorElement::synchronizeRequiredExtensions):
2609         (WebCore::SVGCursorElement::synchronizeSystemLanguage):
2610         * svg/SVGDefsElement.cpp:
2611         (WebCore::SVGDefsElement::SVGDefsElement):
2612         * svg/SVGDefsElement.h:
2613         (WebCore::SVGDefsElement::synchronizeRequiredFeatures):
2614         (WebCore::SVGDefsElement::synchronizeRequiredExtensions):
2615         (WebCore::SVGDefsElement::synchronizeSystemLanguage):
2616         * svg/SVGElement.cpp:
2617         (WebCore::SVGElement::animatedPropertyTypeForAttribute):
2618         (WebCore::SVGElement::updateAnimatedSVGAttribute):
2619         (WebCore::SVGElement::localAttributeToPropertyMap):
2620         (WebCore::SVGElement::synchronizeRequiredFeatures):
2621         (WebCore::SVGElement::synchronizeRequiredExtensions):
2622         (WebCore::SVGElement::synchronizeSystemLanguage):
2623         * svg/SVGElement.h:
2624         (WebCore::SVGElement::svgAttributeChanged):
2625         (WebCore::SVGElement::synchronizeRequiredFeatures):
2626         (WebCore::SVGElement::synchronizeRequiredExtensions):
2627         (WebCore::SVGElement::synchronizeSystemLanguage):
2628         * svg/SVGEllipseElement.cpp:
2629         (WebCore::SVGEllipseElement::SVGEllipseElement):
2630         * svg/SVGEllipseElement.h:
2631         (WebCore::SVGEllipseElement::synchronizeRequiredFeatures):
2632         (WebCore::SVGEllipseElement::synchronizeRequiredExtensions):
2633         (WebCore::SVGEllipseElement::synchronizeSystemLanguage):
2634         * svg/SVGFEBlendElement.cpp:
2635         (WebCore::SVGFEBlendElement::SVGFEBlendElement):
2636         * svg/SVGFEBlendElement.h:
2637         * svg/SVGFEColorMatrixElement.cpp:
2638         (WebCore::SVGFEColorMatrixElement::SVGFEColorMatrixElement):
2639         * svg/SVGFEColorMatrixElement.h:
2640         * svg/SVGFEComponentTransferElement.cpp:
2641         (WebCore::SVGFEComponentTransferElement::SVGFEComponentTransferElement):
2642         * svg/SVGFEComponentTransferElement.h:
2643         * svg/SVGFECompositeElement.cpp:
2644         (WebCore::SVGFECompositeElement::SVGFECompositeElement):
2645         * svg/SVGFECompositeElement.h:
2646         * svg/SVGFEConvolveMatrixElement.cpp:
2647         (WebCore::SVGFEConvolveMatrixElement::SVGFEConvolveMatrixElement):
2648         * svg/SVGFEConvolveMatrixElement.h:
2649         * svg/SVGFEDiffuseLightingElement.cpp:
2650         (WebCore::SVGFEDiffuseLightingElement::SVGFEDiffuseLightingElement):
2651         * svg/SVGFEDiffuseLightingElement.h:
2652         * svg/SVGFEDisplacementMapElement.cpp:
2653         (WebCore::SVGFEDisplacementMapElement::SVGFEDisplacementMapElement):
2654         * svg/SVGFEDisplacementMapElement.h:
2655         * svg/SVGFEDropShadowElement.cpp:
2656         (WebCore::SVGFEDropShadowElement::SVGFEDropShadowElement):
2657         * svg/SVGFEDropShadowElement.h:
2658         * svg/SVGFEFloodElement.cpp:
2659         * svg/SVGFEFloodElement.h:
2660         * svg/SVGFEGaussianBlurElement.cpp:
2661         (WebCore::SVGFEGaussianBlurElement::SVGFEGaussianBlurElement):
2662         * svg/SVGFEGaussianBlurElement.h:
2663         * svg/SVGFEImageElement.cpp:
2664         (WebCore::SVGFEImageElement::SVGFEImageElement):
2665         * svg/SVGFEImageElement.h:
2666         * svg/SVGFELightElement.cpp:
2667         (WebCore::SVGFELightElement::SVGFELightElement):
2668         * svg/SVGFELightElement.h:
2669         * svg/SVGFEMergeElement.cpp:
2670         * svg/SVGFEMergeElement.h:
2671         * svg/SVGFEMergeNodeElement.cpp:
2672         (WebCore::SVGFEMergeNodeElement::SVGFEMergeNodeElement):
2673         * svg/SVGFEMergeNodeElement.h:
2674         * svg/SVGFEMorphologyElement.cpp:
2675         (WebCore::SVGFEMorphologyElement::SVGFEMorphologyElement):
2676         * svg/SVGFEMorphologyElement.h:
2677         * svg/SVGFEOffsetElement.cpp:
2678         (WebCore::SVGFEOffsetElement::SVGFEOffsetElement):
2679         * svg/SVGFEOffsetElement.h:
2680         * svg/SVGFESpecularLightingElement.cpp:
2681         (WebCore::SVGFESpecularLightingElement::SVGFESpecularLightingElement):
2682         * svg/SVGFESpecularLightingElement.h:
2683         * svg/SVGFETileElement.cpp:
2684         (WebCore::SVGFETileElement::SVGFETileElement):
2685         * svg/SVGFETileElement.h:
2686         * svg/SVGFETurbulenceElement.cpp:
2687         (WebCore::SVGFETurbulenceElement::SVGFETurbulenceElement):
2688         * svg/SVGFETurbulenceElement.h:
2689         * svg/SVGFilterElement.cpp:
2690         (WebCore::SVGFilterElement::SVGFilterElement):
2691         * svg/SVGFilterElement.h:
2692         * svg/SVGFilterPrimitiveStandardAttributes.cpp:
2693         (WebCore::SVGFilterPrimitiveStandardAttributes::SVGFilterPrimitiveStandardAttributes):
2694         * svg/SVGFilterPrimitiveStandardAttributes.h:
2695         * svg/SVGFitToViewBox.cpp:
2696         * svg/SVGFitToViewBox.h:
2697         * svg/SVGFontElement.cpp:
2698         (WebCore::SVGFontElement::SVGFontElement):
2699         * svg/SVGFontElement.h:
2700         (WebCore::SVGFontElement::rendererIsNeeded):
2701         * svg/SVGForeignObjectElement.cpp:
2702         (WebCore::SVGForeignObjectElement::SVGForeignObjectElement):
2703         * svg/SVGForeignObjectElement.h:
2704         (WebCore::SVGForeignObjectElement::synchronizeRequiredFeatures):
2705         (WebCore::SVGForeignObjectElement::synchronizeRequiredExtensions):
2706         (WebCore::SVGForeignObjectElement::synchronizeSystemLanguage):
2707         * svg/SVGGElement.cpp:
2708         (WebCore::SVGGElement::SVGGElement):
2709         * svg/SVGGElement.h:
2710         (WebCore::SVGGElement::synchronizeRequiredFeatures):
2711         (WebCore::SVGGElement::synchronizeRequiredExtensions):
2712         (WebCore::SVGGElement::synchronizeSystemLanguage):
2713         * svg/SVGGlyphElement.cpp:
2714         * svg/SVGGlyphElement.h:
2715         * svg/SVGGradientElement.cpp:
2716         (WebCore::SVGGradientElement::SVGGradientElement):
2717         (WebCore::SVGGradientElement::svgAttributeChanged):
2718         * svg/SVGGradientElement.h:
2719         * svg/SVGImageElement.cpp:
2720         (WebCore::SVGImageElement::SVGImageElement):
2721         * svg/SVGImageElement.h:
2722         (WebCore::SVGImageElement::synchronizeRequiredFeatures):
2723         (WebCore::SVGImageElement::synchronizeRequiredExtensions):
2724         (WebCore::SVGImageElement::synchronizeSystemLanguage):
2725         * svg/SVGLineElement.cpp:
2726         (WebCore::SVGLineElement::SVGLineElement):
2727         * svg/SVGLineElement.h:
2728         (WebCore::SVGLineElement::synchronizeRequiredFeatures):
2729         (WebCore::SVGLineElement::synchronizeRequiredExtensions):
2730         (WebCore::SVGLineElement::synchronizeSystemLanguage):
2731         * svg/SVGLinearGradientElement.cpp:
2732         (WebCore::SVGLinearGradientElement::SVGLinearGradientElement):
2733         * svg/SVGLinearGradientElement.h:
2734         * svg/SVGMPathElement.cpp:
2735         (WebCore::SVGMPathElement::SVGMPathElement):
2736         * svg/SVGMPathElement.h:
2737         * svg/SVGMarkerElement.cpp:
2738         (WebCore::SVGMarkerElement::orientTypePropertyInfo):
2739         (WebCore::SVGMarkerElement::SVGMarkerElement):
2740         (WebCore::SVGMarkerElement::setOrientToAuto):
2741         (WebCore::SVGMarkerElement::setOrientToAngle):
2742         (WebCore::SVGMarkerElement::synchronizeOrientType):
2743         (WebCore::SVGMarkerElement::lookupOrCreateOrientTypeWrapper):
2744         (WebCore::SVGMarkerElement::orientTypeAnimated):
2745         * svg/SVGMarkerElement.h:
2746         * svg/SVGMaskElement.cpp:
2747         (WebCore::SVGMaskElement::SVGMaskElement):
2748         * svg/SVGMaskElement.h:
2749         (WebCore::SVGMaskElement::synchronizeRequiredFeatures):
2750         (WebCore::SVGMaskElement::synchronizeRequiredExtensions):
2751         (WebCore::SVGMaskElement::synchronizeSystemLanguage):
2752         * svg/SVGMissingGlyphElement.cpp:
2753         * svg/SVGMissingGlyphElement.h:
2754         * svg/SVGPathElement.cpp:
2755         (WebCore::SVGPathElement::dPropertyInfo):
2756         (WebCore::SVGPathElement::SVGPathElement):
2757         (WebCore::SVGPathElement::svgAttributeChanged):
2758         (WebCore::SVGPathElement::lookupOrCreateDWrapper):
2759         (WebCore::SVGPathElement::synchronizeD):
2760         (WebCore::SVGPathElement::pathSegList):
2761         (WebCore::SVGPathElement::animatedPathSegList):
2762         * svg/SVGPathElement.h:
2763         (WebCore::SVGPathElement::pathByteStream):
2764         (WebCore::SVGPathElement::synchronizeRequiredFeatures):
2765         (WebCore::SVGPathElement::synchronizeRequiredExtensions):
2766         (WebCore::SVGPathElement::synchronizeSystemLanguage):
2767         * svg/SVGPathSegWithContext.h:
2768         (WebCore::SVGPathSegWithContext::animatedProperty):
2769         * svg/SVGPatternElement.cpp:
2770         (WebCore::SVGPatternElement::SVGPatternElement):
2771         * svg/SVGPatternElement.h:
2772         (WebCore::SVGPatternElement::synchronizeRequiredFeatures):
2773         (WebCore::SVGPatternElement::synchronizeRequiredExtensions):
2774         (WebCore::SVGPatternElement::synchronizeSystemLanguage):
2775         * svg/SVGPolyElement.cpp:
2776         (WebCore::SVGPolyElement::pointsPropertyInfo):
2777         (WebCore::SVGPolyElement::SVGPolyElement):
2778         (WebCore::SVGPolyElement::parseMappedAttribute):
2779         (WebCore::SVGPolyElement::synchronizePoints):
2780         (WebCore::SVGPolyElement::lookupOrCreatePointsWrapper):
2781         (WebCore::SVGPolyElement::points):
2782         (WebCore::SVGPolyElement::animatedPoints):
2783         * svg/SVGPolyElement.h:
2784         (WebCore::SVGPolyElement::synchronizeRequiredFeatures):
2785         (WebCore::SVGPolyElement::synchronizeRequiredExtensions):
2786         (WebCore::SVGPolyElement::synchronizeSystemLanguage):
2787         * svg/SVGRadialGradientElement.cpp:
2788         (WebCore::SVGRadialGradientElement::SVGRadialGradientElement):
2789         * svg/SVGRadialGradientElement.h:
2790         * svg/SVGRectElement.cpp:
2791         (WebCore::SVGRectElement::SVGRectElement):
2792         * svg/SVGRectElement.h:
2793         (WebCore::SVGRectElement::synchronizeRequiredFeatures):
2794         (WebCore::SVGRectElement::synchronizeRequiredExtensions):
2795         (WebCore::SVGRectElement::synchronizeSystemLanguage):
2796         * svg/SVGSVGElement.cpp:
2797         (WebCore::SVGSVGElement::SVGSVGElement):
2798         * svg/SVGSVGElement.h:
2799         (WebCore::SVGSVGElement::synchronizeRequiredFeatures):
2800         (WebCore::SVGSVGElement::synchronizeRequiredExtensions):
2801         (WebCore::SVGSVGElement::synchronizeSystemLanguage):
2802         * svg/SVGScriptElement.cpp:
2803         (WebCore::SVGScriptElement::SVGScriptElement):
2804         * svg/SVGScriptElement.h:
2805         * svg/SVGStopElement.cpp:
2806         (WebCore::SVGStopElement::SVGStopElement):
2807         * svg/SVGStopElement.h:
2808         * svg/SVGStyledElement.cpp:
2809         (WebCore::SVGStyledElement::SVGStyledElement):
2810         (WebCore::cssPropertyToTypeMap):
2811         (WebCore::SVGStyledElement::animatedPropertyTypeForAttribute):
2812         * svg/SVGStyledElement.h:
2813         * svg/SVGStyledTransformableElement.cpp:
2814         (WebCore::SVGStyledTransformableElement::SVGStyledTransformableElement):
2815         * svg/SVGStyledTransformableElement.h:
2816         * svg/SVGSwitchElement.cpp:
2817         (WebCore::SVGSwitchElement::SVGSwitchElement):
2818         * svg/SVGSwitchElement.h:
2819         (WebCore::SVGSwitchElement::synchronizeRequiredFeatures):
2820         (WebCore::SVGSwitchElement::synchronizeRequiredExtensions):
2821         (WebCore::SVGSwitchElement::synchronizeSystemLanguage):
2822         * svg/SVGSymbolElement.cpp:
2823         (WebCore::SVGSymbolElement::SVGSymbolElement):
2824         * svg/SVGSymbolElement.h:
2825         * svg/SVGTRefElement.cpp:
2826         (WebCore::SVGTRefElement::SVGTRefElement):
2827         * svg/SVGTRefElement.h:
2828         * svg/SVGTSpanElement.cpp:
2829         * svg/SVGTSpanElement.h:
2830         * svg/SVGTests.cpp:
2831         (WebCore::SVGTests::requiredFeaturesPropertyInfo):
2832         (WebCore::SVGTests::requiredExtensionsPropertyInfo):
2833         (WebCore::SVGTests::systemLanguagePropertyInfo):
2834         (WebCore::SVGTests::attributeToPropertyMap):
2835         (WebCore::SVGTests::synchronizeRequiredFeatures):
2836         (WebCore::SVGTests::synchronizeRequiredExtensions):
2837         (WebCore::SVGTests::synchronizeSystemLanguage):
2838         * svg/SVGTests.h:
2839         * svg/SVGTextContentElement.cpp:
2840         (WebCore::SVGTextContentElement::textLengthPropertyInfo):
2841         (WebCore::SVGTextContentElement::SVGTextContentElement):
2842         (WebCore::SVGTextContentElement::synchronizeTextLength):
2843         (WebCore::SVGTextContentElement::lookupOrCreateTextLengthWrapper):
2844         (WebCore::SVGTextContentElement::textLengthAnimated):
2845         * svg/SVGTextContentElement.h:
2846         (WebCore::SVGTextContentElement::synchronizeRequiredFeatures):
2847         (WebCore::SVGTextContentElement::synchronizeRequiredExtensions):
2848         (WebCore::SVGTextContentElement::synchronizeSystemLanguage):
2849         * svg/SVGTextElement.cpp:
2850         (WebCore::SVGTextElement::SVGTextElement):
2851         * svg/SVGTextElement.h:
2852         * svg/SVGTextPathElement.cpp:
2853         (WebCore::SVGTextPathElement::SVGTextPathElement):
2854         * svg/SVGTextPathElement.h:
2855         * svg/SVGTextPositioningElement.cpp:
2856         (WebCore::SVGTextPositioningElement::SVGTextPositioningElement):
2857         * svg/SVGTextPositioningElement.h:
2858         * svg/SVGTitleElement.cpp:
2859         * svg/SVGTitleElement.h:
2860         (WebCore::SVGTitleElement::rendererIsNeeded):
2861         * svg/SVGUseElement.cpp:
2862         (WebCore::SVGUseElement::SVGUseElement):
2863         * svg/SVGUseElement.h:
2864         (WebCore::SVGUseElement::synchronizeRequiredFeatures):
2865         (WebCore::SVGUseElement::synchronizeRequiredExtensions):
2866         (WebCore::SVGUseElement::synchronizeSystemLanguage):
2867         * svg/SVGViewElement.cpp:
2868         (WebCore::SVGViewElement::SVGViewElement):
2869         * svg/SVGViewElement.h:
2870         * svg/SVGViewSpec.cpp:
2871         (WebCore::SVGViewSpec::SVGViewSpec):
2872         * svg/SVGViewSpec.h:
2873         * svg/properties/SVGAnimatedProperty.h:
2874         (WebCore::SVGAnimatedProperty::lookupOrCreateWrapper):
2875         (WebCore::SVGAnimatedProperty::lookupWrapper):
2876         * svg/properties/SVGAnimatedPropertyMacros.h:
2877         * svg/properties/SVGAnimatedPropertySynchronizer.h:
2878         * svg/properties/SVGAttributeToPropertyMap.cpp: Added.
2879         (WebCore::SVGAttributeToPropertyMap::addProperties):
2880         (WebCore::SVGAttributeToPropertyMap::addProperty):
2881         (WebCore::SVGAttributeToPropertyMap::animatedPropertiesForAttribute):
2882         (WebCore::SVGAttributeToPropertyMap::animatedPropertyTypeForAttribute):
2883         (WebCore::SVGAttributeToPropertyMap::synchronizeProperties):
2884         (WebCore::SVGAttributeToPropertyMap::synchronizeProperty):
2885         (WebCore::SVGAttributeToPropertyMap::animatedProperty):
2886         * svg/properties/SVGAttributeToPropertyMap.h: Added.
2887         (WebCore::SVGAttributeToPropertyMap::SVGAttributeToPropertyMap):
2888         (WebCore::SVGAttributeToPropertyMap::~SVGAttributeToPropertyMap):
2889         (WebCore::SVGAttributeToPropertyMap::isEmpty):
2890         * svg/properties/SVGPropertyInfo.h: Added.
2891         (WebCore::SVGPropertyInfo::SVGPropertyInfo):
2892
2893 2011-07-09  Patrick Gansterer  <paroga@webkit.org>
2894
2895         Unreviewed build fix after r90676.
2896
2897         * platform/graphics/ImageBuffer.cpp:
2898
2899 2011-07-08  Dirk Schulze  <krit@webkit.org>
2900
2901         Refactoring luminance code in RenderSVGResourceMasker
2902         https://bugs.webkit.org/show_bug.cgi?id=64146
2903
2904         Reviewed by Simon Fraser.
2905
2906         Moved luminance calculcation code to ImageBuffer. The code is doing pixel manipulations and can now get replaced
2907         by platform specific algorithms in the ImmageBuffer*.cpp files.
2908
2909         No change of functionality. No new tests.
2910
2911         * WebCore.xcodeproj/project.pbxproj:
2912         * platform/graphics/ImageBuffer.cpp:
2913         (WebCore::ImageBuffer::transformColorSpace):
2914         (WebCore::ImageBuffer::genericConvertToLuminanceMask):
2915         (WebCore::ImageBuffer::convertToLuminanceMask):
2916         * platform/graphics/ImageBuffer.h:
2917         * rendering/svg/RenderSVGResourceMasker.cpp:
2918         (WebCore::RenderSVGResourceMasker::drawContentIntoMaskImage):
2919
2920 2011-07-08  Simon Fraser  <simon.fraser@apple.com>
2921
2922         Clean up RenderWidget::destroy() to share more code
2923         https://bugs.webkit.org/show_bug.cgi?id=64138
2924
2925         Reviewed by James Robinson.
2926
2927         RenderWidget::destroy() copied code from various other
2928         destroy() methods, which made code maintenance in this
2929         area very risky.
2930         
2931         Fix by adding a virtual willBeDestroyed() method, which
2932         replaces most instances of destroy(). Now, only RenderWidget
2933         and RenderObject implement destroy(), and each just calls
2934         willBeDestroyed(). Code duplication is averted.
2935         
2936         No behavior change, so no tests.
2937
2938         * rendering/RenderBlock.cpp:
2939         (WebCore::RenderBlock::willBeDestroyed):
2940         * rendering/RenderBlock.h:
2941         * rendering/RenderBox.cpp:
2942         (WebCore::RenderBox::willBeDestroyed):
2943         * rendering/RenderBox.h:
2944         * rendering/RenderBoxModelObject.cpp:
2945         (WebCore::RenderBoxModelObject::willBeDestroyed):
2946         * rendering/RenderBoxModelObject.h:
2947         * rendering/RenderFullScreen.cpp:
2948         (RenderFullScreenPlaceholder::willBeDestroyed):
2949         (RenderFullScreen::willBeDestroyed):
2950         * rendering/RenderFullScreen.h:
2951         * rendering/RenderInline.cpp:
2952         (WebCore::RenderInline::willBeDestroyed):
2953         * rendering/RenderInline.h:
2954         * rendering/RenderListItem.cpp:
2955         (WebCore::RenderListItem::willBeDestroyed):
2956         * rendering/RenderListItem.h:
2957         * rendering/RenderObject.cpp:
2958         (WebCore::RenderObject::willBeDestroyed):
2959         (WebCore::RenderObject::destroy):
2960         * rendering/RenderObject.h:
2961         * rendering/RenderReplaced.cpp:
2962         (WebCore::RenderReplaced::willBeDestroyed):
2963         * rendering/RenderReplaced.h:
2964         * rendering/RenderTableCell.cpp:
2965         (WebCore::RenderTableCell::willBeDestroyed):
2966         * rendering/RenderTableCell.h:
2967         * rendering/RenderTableRow.cpp:
2968         (WebCore::RenderTableRow::willBeDestroyed):
2969         * rendering/RenderTableRow.h:
2970         * rendering/RenderTableSection.cpp:
2971         (WebCore::RenderTableSection::willBeDestroyed):
2972         * rendering/RenderTableSection.h:
2973         * rendering/RenderText.cpp:
2974         (WebCore::RenderText::willBeDestroyed):
2975         * rendering/RenderText.h:
2976         * rendering/RenderTextFragment.cpp:
2977         (WebCore::RenderTextFragment::willBeDestroyed):
2978         * rendering/RenderTextFragment.h:
2979         * rendering/RenderWidget.cpp:
2980         (WebCore::RenderWidget::willBeDestroyed):
2981         (WebCore::RenderWidget::destroy):
2982         * rendering/RenderWidget.h:
2983         * rendering/svg/RenderSVGBlock.cpp:
2984         (WebCore::RenderSVGBlock::willBeDestroyed):
2985         * rendering/svg/RenderSVGBlock.h:
2986         * rendering/svg/RenderSVGInline.cpp:
2987         (WebCore::RenderSVGInline::willBeDestroyed):
2988         * rendering/svg/RenderSVGInline.h:
2989         * rendering/svg/RenderSVGInlineText.cpp:
2990         (WebCore::RenderSVGInlineText::willBeDestroyed):
2991         * rendering/svg/RenderSVGInlineText.h:
2992         * rendering/svg/RenderSVGModelObject.cpp:
2993         (WebCore::RenderSVGModelObject::willBeDestroyed):
2994         * rendering/svg/RenderSVGModelObject.h:
2995         * rendering/svg/RenderSVGResourceContainer.cpp:
2996         (WebCore::RenderSVGResourceContainer::willBeDestroyed):
2997         * rendering/svg/RenderSVGResourceContainer.h:
2998         * rendering/svg/RenderSVGRoot.cpp:
2999         (WebCore::RenderSVGRoot::willBeDestroyed):
3000         * rendering/svg/RenderSVGRoot.h:
3001         * rendering/svg/SVGResourcesCache.h:
3002
3003 2011-07-08  Adam Barth  <abarth@webkit.org>
3004
3005         Unreviewed, rolling out r90662.
3006         http://trac.webkit.org/changeset/90662
3007         https://bugs.webkit.org/show_bug.cgi?id=64210
3008
3009         Introduced regressions in Chromium browser tests (Requested by
3010         rniwa on #webkit).
3011
3012         * accessibility/AccessibilityRenderObject.cpp:
3013         (WebCore::AccessibilityRenderObject::selectedText):
3014         (WebCore::AccessibilityRenderObject::selectedTextRange):
3015         (WebCore::AccessibilityRenderObject::setSelectedTextRange):
3016         * html/HTMLFormControlElement.cpp:
3017         (WebCore::HTMLTextFormControlElement::setSelectionRange):
3018         (WebCore::HTMLTextFormControlElement::selectionStart):
3019         (WebCore::HTMLTextFormControlElement::selectionEnd):
3020         (WebCore::HTMLTextFormControlElement::selection):
3021         (WebCore::HTMLTextFormControlElement::restoreCachedSelection):
3022         (WebCore::HTMLTextFormControlElement::selectionChanged):
3023         * html/HTMLFormControlElement.h:
3024         * html/HTMLInputElement.cpp:
3025         (WebCore::HTMLInputElement::setValue):
3026         * rendering/RenderTextControl.cpp:
3027         (WebCore::RenderTextControl::selectionStart):
3028         (WebCore::RenderTextControl::selectionEnd):
3029         (WebCore::RenderTextControl::hasVisibleTextArea):
3030         (WebCore::setSelectionRange):
3031         (WebCore::setContainerAndOffsetForRange):
3032         (WebCore::RenderTextControl::selection):
3033         * rendering/RenderTextControl.h:
3034
3035 2011-07-08  Brian Salomon  <bsalomon@google.com>
3036
3037         Make GL context current before updating layer texture using skia-gpu
3038         https://bugs.webkit.org/show_bug.cgi?id=64206
3039
3040         Reviewed by James Robinson.
3041
3042         Covered by existing tests (when accelerated drawing and compositing are on).
3043
3044         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
3045         (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
3046
3047 2011-07-08  Tony Chang  <tony@chromium.org>
3048
3049         Refactor override size to be a size rather than just an int
3050         https://bugs.webkit.org/show_bug.cgi?id=64195
3051
3052         Reviewed by David Hyatt.
3053
3054         Also convert to LayoutSize and LayoutUnit.
3055
3056         Covered by existing tests.
3057
3058         * rendering/RenderBox.cpp:
3059         (WebCore::RenderBox::overrideSize): Pass in a LayoutSize.
3060         (WebCore::RenderBox::setOverrideSize):
3061         (WebCore::RenderBox::clearOverrideSize): New method for clearing the
3062             override size (previous we would pass in -1)
3063         (WebCore::RenderBox::overrideWidth):
3064         (WebCore::RenderBox::overrideHeight):
3065         (WebCore::RenderBox::computeLogicalWidth):
3066         (WebCore::RenderBox::computeLogicalHeight):
3067         (WebCore::RenderBox::computePercentageLogicalHeight):
3068         (WebCore::RenderBox::availableLogicalHeightUsing):
3069         * rendering/RenderBox.h:
3070         * rendering/RenderDeprecatedFlexibleBox.cpp:
3071         (WebCore::gatherFlexChildrenInfo):
3072         (WebCore::RenderDeprecatedFlexibleBox::layoutHorizontalBox):
3073         (WebCore::RenderDeprecatedFlexibleBox::layoutVerticalBox):
3074         (WebCore::RenderDeprecatedFlexibleBox::applyLineClamp):
3075         * rendering/RenderTableCell.cpp:
3076         (WebCore::RenderTableCell::setOverrideSizeFromRowHeight):
3077         * rendering/RenderTableCell.h: Remove setOverrideSize since it was
3078             only called in one place to clear the override size.  Inline this
3079             logic instead.
3080         * rendering/RenderTableSection.cpp:
3081         (WebCore::RenderTableSection::calcRowLogicalHeight):
3082         * rendering/RenderWidget.cpp:
3083         (WebCore::RenderWidget::destroy):
3084
3085 2011-07-08  Emil A Eklund  <eae@chromium.org>
3086
3087         Switch pointInContainer and accumulatedOffset to to new layout types
3088         https://bugs.webkit.org/show_bug.cgi?id=64112
3089
3090         Reviewed by Eric Seidel.
3091
3092         Convert remaining IntPoint versions of the pointInContainer and
3093         accumulatedOffset arguments to the new layout abstraction.
3094
3095         No new tests, no functionality changes.
3096
3097         * rendering/HitTestResult.cpp:
3098         (WebCore::HitTestResult::addNodeToRectBasedTestResult):
3099         * rendering/HitTestResult.h:
3100         * rendering/RenderBlock.cpp:
3101         (WebCore::RenderBlock::isPointInOverflowControl):
3102         * rendering/RenderBlock.h:
3103         * rendering/RenderBox.cpp:
3104         (WebCore::RenderBox::pushContentsClip):
3105         (WebCore::RenderBox::popContentsClip):
3106         * rendering/RenderBox.h:
3107         * rendering/RenderEmbeddedObject.cpp:
3108         (WebCore::RenderEmbeddedObject::getReplacementTextGeometry):
3109         * rendering/RenderEmbeddedObject.h:
3110         * rendering/RenderLineBoxList.cpp:
3111         (WebCore::RenderLineBoxList::hitTest):
3112         * rendering/RenderLineBoxList.h:
3113         * rendering/RenderListBox.cpp:
3114         (WebCore::RenderListBox::isPointInOverflowControl):
3115         * rendering/RenderListBox.h:
3116         * rendering/RenderObject.cpp:
3117         (WebCore::RenderObject::hitTest):
3118         * rendering/RenderObject.h:
3119         * rendering/RenderTextControl.cpp:
3120         (WebCore::RenderTextControl::hitInnerTextElement):
3121         * rendering/RenderTextControl.h:
3122         * rendering/RenderTextControlSingleLine.cpp:
3123         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
3124
3125 2011-07-07  Ryosuke Niwa  <rniwa@webkit.org>
3126
3127         Move selection related code from RenderTextControl to HTMLTextFormControlElement
3128         https://bugs.webkit.org/show_bug.cgi?id=64133
3129
3130         Reviewed by Dimitri Glazkov.
3131
3132         Moved selectionStart, selectionEnd, hasVisibleTextArea, setSelectionRange, setContainerAndOffsetForRange
3133         and selection from RenderTextControl.cpp to HTMLFormControlElement.cpp.
3134
3135         This refactoring removes RenderTextControl's dependency on FrameSelection.
3136
3137         * accessibility/AccessibilityRenderObject.cpp:
3138         (WebCore::AccessibilityRenderObject::selectedText): Calls HTMLTextFromControl::selectedText.
3139         (WebCore::AccessibilityRenderObject::selectedTextRange): Calls selectionStart and selectionEnd.
3140         (WebCore::AccessibilityRenderObject::setSelectedTextRange): Ditto.
3141         * html/HTMLFormControlElement.cpp:
3142         (WebCore::HTMLTextFormControlElement::selectedText): Extracted from AccessibilityRenderObject::selectedText.
3143         (WebCore::hasVisibleTextArea):
3144         (WebCore::HTMLTextFormControlElement::setSelectionRange): Merged with the function of the same name in
3145         RenderTextControl.
3146         (WebCore::HTMLTextFormControlElement::selectionStart): Ditto.
3147         (WebCore::HTMLTextFormControlElement::selectionEnd): Ditto.
3148         (WebCore::setContainerAndOffsetForRange): Moved from RenderTextControl.cpp
3149         (WebCore::HTMLTextFormControlElement::selection): Merged with the function of the same name in RenderTextControl.
3150         (WebCore::HTMLTextFormControlElement::selectionChanged): Calls selectionStart and selectionEnd.
3151         * html/HTMLFormControlElement.h:
3152         (WebCore::HTMLTextFormControlElement::restoreCachedSelection): Moved from HTMLFormControlElement.cpp now that
3153         all functions are self-contained in HTMLTextFormControlElement.
3154         * html/HTMLInputElement.cpp:
3155         (WebCore::HTMLInputElement::setValue): Calls setSelectionRange.
3156         * rendering/RenderTextControl.cpp:
3157         (WebCore::RenderTextControl::textFormControlElement): Added.
3158         * rendering/RenderTextControl.h:
3159
3160 2011-07-08  Mike Reed  <reed@google.com>
3161
3162         remove (empty) indirection between GraphicsContextPlatformPrivate and PlatformContextSkia
3163         https://bugs.webkit.org/show_bug.cgi?id=64178
3164
3165         Reviewed by Stephen White.
3166
3167         No new tests. no functionality change, other than removing an indirection that is not needed
3168
3169         * platform/graphics/GraphicsContext.h:
3170         * platform/graphics/skia/GraphicsContextPlatformPrivate.h: Removed.
3171         * platform/graphics/skia/GraphicsContextSkia.cpp:
3172         (WebCore::GraphicsContext::platformInit):
3173         (WebCore::GraphicsContext::platformDestroy):
3174         (WebCore::GraphicsContext::platformContext):
3175
3176 2011-07-08  Jeffrey Pfau  <jpfau@apple.com>
3177
3178         Add framework for a new/dummy XMLDocumentParser
3179         https://bugs.webkit.org/show_bug.cgi?id=63955
3180
3181         Reviewed by Adam Barth.
3182
3183         Added a dummy framework NewXMLDocumentParser
3184
3185         * WebCore.xcodeproj/project.pbxproj:
3186         * dom/Document.cpp:
3187         (WebCore::Document::createParser):
3188         * xml/parser/NewXMLDocumentParser.cpp: Added.
3189         (WebCore::NewXMLDocumentParser::NewXMLDocumentParser):
3190         (WebCore::NewXMLDocumentParser::textPosition):
3191         (WebCore::NewXMLDocumentParser::lineNumber):
3192         (WebCore::NewXMLDocumentParser::insert):
3193         (WebCore::NewXMLDocumentParser::append):
3194         (WebCore::NewXMLDocumentParser::finish):
3195         (WebCore::NewXMLDocumentParser::detach):
3196         (WebCore::NewXMLDocumentParser::hasInsertionPoint):
3197         (WebCore::NewXMLDocumentParser::finishWasCalled):
3198         (WebCore::NewXMLDocumentParser::processingData):
3199         (WebCore::NewXMLDocumentParser::prepareToStopParsing):
3200         (WebCore::NewXMLDocumentParser::stopParsing):
3201         (WebCore::NewXMLDocumentParser::isWaitingForScripts):
3202         (WebCore::NewXMLDocumentParser::isExecutingScript):
3203         (WebCore::NewXMLDocumentParser::executeScriptsWaitingForStylesheets):
3204         * xml/parser/NewXMLDocumentParser.h: Added.
3205         (WebCore::NewXMLDocumentParser::create):
3206
3207 2011-07-08  David Reveman  <reveman@chromium.org>
3208
3209         Remove unused function parameters.
3210
3211         Reviewed by Ryosuke Niwa.
3212
3213         * platform/graphics/gpu/TilingData.cpp:
3214         (WebCore::TilingData::textureOffset):
3215
3216 2011-07-08  David Reveman  <reveman@chromium.org>
3217
3218         Reviewed by Stephen White.
3219
3220         [Chromium] Edge anti-aliasing for composited layers.
3221         https://bugs.webkit.org/show_bug.cgi?id=61388
3222
3223         Add transparent outer border to tiled layers and adjust vertex
3224         coordinates so that use of a bilinear filter creates a smooth
3225         layer edge.
3226
3227         Tests: platform/chromium/compositing/tiny-layer-rotated.html
3228                platform/chromium/compositing/huge-layer-rotated.html (existing)
3229                TilingDataTest in webkit_unit_tests
3230
3231         * platform/graphics/chromium/ContentLayerChromium.cpp:
3232         Change maxUntiledSize to 510 to ensure that tiles are not greater
3233         than 512 with outer borders.
3234         (WebCore::ContentLayerChromium::updateLayerSize): We can't use the
3235         layer size as tile size when we want to avoid tiling as this will
3236         not be enough space to include possible outer borders. We instead use
3237         an empty size, which allows the tiler to automatically adjust the
3238         tile size to be large enough for the layer to fit in one tile.
3239         (WebCore::ContentLayerChromium::createTilerIfNeeded):
3240         (WebCore::ContentLayerChromium::setIsMask): Don't use border texels
3241         for layer used as mask.
3242
3243         * platform/graphics/chromium/ContentLayerChromium.h:
3244         (WebCore::ContentLayerChromium::m_borderTexels) Added.
3245
3246         * platform/graphics/chromium/LayerTilerChromium.cpp:
3247         (WebCore::LayerTilerChromium::tileTexRect): Added.
3248         (WebCore::LayerTilerChromium::tileLayerRect): m_tileSize is no
3249         longer the correct layer size. Size of bounds with border should
3250         be the correct layer size.
3251         (WebCore::LayerTilerChromium::growLayerToContain): Adjust texture
3252         size to include outer borders and handle empty m_tileSize.
3253         (WebCore::LayerTilerChromium::invalidateRect): Use size of rectangle
3254         returned by tileTexRect instead of m_tileSize for texture size.
3255         (WebCore::LayerTilerChromium::prepareToUpdate): Ditto.
3256         (WebCore::LayerTilerChromium::draw): Compute and intersect tile edges
3257         instead of using tile coordinates directly. Edges are adjusted to
3258         include outer borders and make sure all partially covered pixels are
3259         processed.
3260         (WebCore::LayerTilerChromium::drawTexturedQuad): Pass quad to
3261         shader using point uniform.
3262         (WebCore::LayerTilerChromium::invalidateRect): Invalidate old layer
3263         area to clear any contents left from previous layer size.
3264
3265         * platform/graphics/chromium/LayerTilerChromium.h:
3266         (WebCore::LayerTilerChromium::tileTexRect) Added.
3267         (WebCore::LayerTilerChromium::drawTexturedQuad): Add quad parameter.
3268
3269         * platform/graphics/chromium/ShaderChromium.cpp:
3270         (WebCore::VertexShaderPosTexTransform::getShaderString) Get X/Y vertex
3271         components from point uniform.
3272         (WebCore::VertexShaderPosTexTransform::VertexShaderPosTexTransform)
3273         Added point uniform.
3274         (WebCore::VertexShaderPosTexTransform::init) Ditto.
3275         (WebCore::VertexShaderPosTexTransform::pointLocation) Added.
3276
3277         * platform/graphics/chromium/ShaderChromium.h:
3278         (WebCore::VertexShaderPosTexTransform::pointLocation) Added.
3279
3280         * platform/graphics/gpu/TilingData.cpp:
3281         (WebCore::TilingData::tileBoundsWithOuterBorder): Added.
3282         (WebCore::TilingData::computeNumTiles): Adjust for outer border.
3283         (WebCore::TilingData::tileXIndexFromSrcCoord): Ditto.
3284         (WebCore::TilingData::tileYIndexFromSrcCoord): Ditto.
3285         (WebCore::TilingData::tileSizeX): Ditto.
3286         (WebCore::TilingData::tileSizeY): Ditto.
3287         (WebCore::TilingData::intersectDrawQuad): Ditto.
3288         (WebCore::TilingData::textureOffset): Ditto.
3289
3290         * platform/graphics/gpu/TilingData.h:
3291         (WebCore::TilingData::tileBoundsWithOuterBorder): Added.
3292
3293 2011-07-08  Mike Reed  <reed@google.com>
3294
3295         [skia] don't rely on lockPixels failure to detect gpu-backed device (in prep for skia roll)
3296         https://bugs.webkit.org/show_bug.cgi?id=64162
3297
3298         Reviewed by Stephen White.
3299
3300         No new tests. preparing for skia roll, where lockPixels always succeeds (but slowly for gpu-backed)
3301
3302         * platform/graphics/skia/ImageBufferSkia.cpp:
3303         (WebCore::putImageData):
3304
3305 2011-07-08  Chang Shu  <cshu@webkit.org>
3306
3307         Update calling sites after function renamed.
3308         https://bugs.webkit.org/show_bug.cgi?id=59114
3309
3310         Reviewed by Alexey Proskuryakov.
3311
3312         No new tests, just refactoring.
3313
3314         * editing/visible_units.cpp:
3315         (WebCore::previousBoundary):
3316         (WebCore::nextBoundary):
3317         * rendering/RenderText.cpp:
3318         (WebCore::RenderText::setTextInternal):
3319
3320 2011-07-08  Mihnea Ovidenie  <mihnea@adobe.com>
3321
3322         [CSSRegions]Parse content: -webkit-from-flow
3323         https://bugs.webkit.org/show_bug.cgi?id=63133
3324
3325         Reviewed by David Hyatt.
3326
3327         Test: fast/regions/content-webkit-from-flow-parsing.html
3328
3329         * css/CSSComputedStyleDeclaration.cpp:
3330         (WebCore::contentToCSSValue):
3331         * css/CSSParser.cpp:
3332         (WebCore::CSSParser::parseContent):
3333         (WebCore::CSSParser::parseFromFlowContent):
3334         * css/CSSParser.h:
3335         * css/CSSPrimitiveValue.cpp:
3336         (WebCore::CSSPrimitiveValue::cleanup):
3337         (WebCore::CSSPrimitiveValue::getStringValue):
3338         (WebCore::CSSPrimitiveValue::cssText):
3339         * css/CSSPrimitiveValue.h:
3340         * css/CSSStyleSelector.cpp:
3341         (WebCore::CSSStyleSelector::applyProperty):
3342         * rendering/style/RenderStyle.cpp:
3343         (WebCore::RenderStyle::diff):
3344         * rendering/style/RenderStyle.h:
3345         (WebCore::InheritedFlags::regionThread):
3346         (WebCore::InheritedFlags::setRegionThread):
3347         (WebCore::InheritedFlags::initialRegionThread):
3348         * rendering/style/StyleRareNonInheritedData.cpp:
3349         (WebCore::StyleRareNonInheritedData::StyleRareNonInheritedData):
3350         (WebCore::StyleRareNonInheritedData::operator==):
3351         * rendering/style/StyleRareNonInheritedData.h:
3352
3353 2011-07-08  Ilya Tikhonovsky  <loislo@chromium.org>
3354
3355         Web Inspector: NetworkPanel search failed if the matched sting is in the query part of url
3356         https://bugs.webkit.org/show_bug.cgi?id=64167
3357
3358         Reviewed by Yury Semikhatsky.
3359
3360         * inspector/front-end/NetworkPanel.js:
3361         (WebInspector.NetworkPanel.prototype._matchResource):
3362         (WebInspector.NetworkPanel.prototype._highlightNthMatchedResource):
3363         (WebInspector.NetworkDataGridNode.prototype._refreshNameCell):
3364         * inspector/front-end/Resource.js:
3365         (WebInspector.Resource.prototype.get folder):
3366
3367 2011-07-08  Benjamin Poulain  <benjamin@webkit.org>
3368
3369         [Qt] Enable HTTP Pipelining by default
3370         https://bugs.webkit.org/show_bug.cgi?id=64169
3371
3372         Reviewed by Andreas Kling.
3373
3374         QNetworkAccessManager disables HTTP pipelining by default. We enable it by
3375         setting an attribute on the request.
3376
3377         * platform/network/qt/ResourceRequestQt.cpp:
3378         (WebCore::ResourceRequest::toNetworkRequest):
3379
3380 2011-07-08  Alexander Pavlov  <apavlov@chromium.org>
3381
3382         Web Inspector: CSS inspector gets confused about specificity of !important properties
3383         https://bugs.webkit.org/show_bug.cgi?id=64074
3384
3385         Reviewed by Yury Semikhatsky.
3386
3387         * inspector/front-end/StylesSidebarPane.js:
3388         (WebInspector.StylesSidebarPane.prototype._markUsedProperties):
3389
3390 2011-07-08  Alexander Pavlov  <apavlov@chromium.org>
3391
3392         [Chromium] Unreviewed, clang build fix.
3393
3394         * inspector/InspectorStyleTextEditor.h:
3395
3396 2011-07-08  Pavel Feldman  <pfeldman@google.com>
3397
3398         Web Inspector: add support for drag'n'drop of non-elements (comments, text, etc.)
3399         https://bugs.webkit.org/show_bug.cgi?id=64163
3400
3401         Reviewed by Yury Semikhatsky.
3402
3403         * inspector/Inspector.json:
3404         * inspector/InspectorDOMAgent.cpp:
3405         (WebCore::InspectorDOMAgent::moveTo):
3406         * inspector/front-end/ElementsTreeOutline.js:
3407         (WebInspector.ElementsTreeOutline.prototype._isValidDragSourceOrTarget):
3408
3409 2011-07-08  Andrey Kosyakov  <caseq@chromium.org>
3410
3411         Web Inspector: secure access to extensions API
3412         https://bugs.webkit.org/show_bug.cgi?id=64080
3413
3414         Reviewed by Pavel Feldman.
3415
3416         * inspector/front-end/ExtensionAPI.js:
3417         (WebInspector.injectedExtensionAPI.Panels.prototype.create):
3418         (WebInspector.injectedExtensionAPI.ExtensionSidebarPaneImpl.prototype.setPage):
3419         * inspector/front-end/ExtensionPanel.js:
3420         (WebInspector.ExtensionPanel):
3421         * inspector/front-end/ExtensionServer.js:
3422         (WebInspector.ExtensionServer):
3423         (WebInspector.ExtensionServer.prototype._onCreatePanel):
3424         (WebInspector.ExtensionServer.prototype._onSetSidebarPage):
3425         (WebInspector.ExtensionServer.prototype._addExtensions):
3426         (WebInspector.ExtensionServer.prototype._onWindowMessage):
3427         (WebInspector.ExtensionServer.prototype._registerSubscriptionHandler):
3428         (WebInspector.ExtensionServer.prototype._expandResourcePath):
3429         (WebInspector.ExtensionServer.prototype._normalizePath):
3430
3431 2011-07-08  Adam Barth  <abarth@webkit.org>
3432
3433         Unreviewed, rolling out r90615.
3434         http://trac.webkit.org/changeset/90615
3435         https://bugs.webkit.org/show_bug.cgi?id=64158
3436
3437         broke inspector/extensions/extensions.html (Requested by caseq