<rdar://problem/9084761> REGRESSION (r73993): Default Arabic line spacing has gotten...
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-04-06  Dan Bernstein  <mitz@apple.com>
2
3         Reviewed by Darin Adler.
4
5         <rdar://problem/9084761> REGRESSION (r73993): Default Arabic line spacing has gotten very loose when the specified font is not Arabic
6         https://bugs.webkit.org/show_bug.cgi?id=58002
7
8         * platform/graphics/mac/SimpleFontDataMac.mm:
9         (WebCore::SimpleFontData::platformInit): The version of Geeza Pro in Snow Leopard
10         does not require the vertical metrics tweaks that were needed in Leopard. That the
11         tweaks were being applied went mostly unnoticed until r73993, because until then it
12         only affected cases where Geeza Pro was specified, not when it occurred as a fallback
13         font.
14
15 2011-04-06  Roland Steiner  <rolandsteiner@chromium.org>
16
17         Reviewed by Dimitri Glazkov.
18
19         Bug 57994 - Move guardRef functionality back to Document
20         https://bugs.webkit.org/show_bug.cgi?id=57994
21
22         Move the relevant code parts from TreeScope back into Document.
23
24         No new tests. (no new functionality)
25
26         * dom/Document.cpp:
27         (WebCore::Document::removedLastRef):
28         * dom/Document.h:
29         * dom/TreeScope.cpp:
30         (WebCore::TreeScope::destroyTreeScopeData):
31         * dom/TreeScope.h:
32
33 2011-04-06  Ian Henderson  <ianh@apple.com>
34
35         Reviewed by Simon Fraser, Antti Koivisto.
36
37         Fast path for parsing simple CSS values
38         https://bugs.webkit.org/show_bug.cgi?id=57964
39
40         Add functions to parse simple color or dimension values, skipping the
41         overhead of full CSS parsing.
42
43         Change parseValue to a static method to avoid unnecessary allocation
44         of a CSSParser in the fast case.
45
46         * css/CSSMutableStyleDeclaration.cpp:
47         (WebCore::CSSMutableStyleDeclaration::setProperty):
48         Changed to use the new, static parseValue method.
49         * css/CSSParser.cpp:
50         (WebCore::isColorPropertyID):
51         (WebCore::parseColorValue):
52         Parses any color accepted by the existing parseColor() static method.
53         We must handle color identifiers separately, since parseColor() will
54         change 'red' into 'rgb(255, 0, 0)'.
55         (WebCore::isSimpleLengthPropertyID):
56         (WebCore::parseSimpleLengthValue):
57         Parses a value of the form 'NNpx', 'NN%', or 'NN' (when strict is
58         false, or 'NN' is '0').  Returns false to fall back to the slow path.
59         (WebCore::CSSParser::parseValue):
60         * css/CSSParser.h:
61         * css/WebKitCSSMatrix.cpp:
62         (WebCore::WebKitCSSMatrix::setMatrixValue):
63         Changed to use the new, static parseValue method.
64
65 2011-04-06  Kevin Ollivier  <kevino@theolliviers.com>
66
67         Reviewed by Darin Adler.
68
69         Make sure JS_EXPORT_PRIVATE is an empty define when we aren't using the export macros.
70
71         https://bugs.webkit.org/show_bug.cgi?id=27551
72
73         * config.h:
74
75 2011-04-06  Simon Fraser  <simon.fraser@apple.com>
76
77         Reviewed by Antti Koivisto.
78
79         Some minor style resolution optimizations
80         https://bugs.webkit.org/show_bug.cgi?id=57996
81
82         A couple of minor optimizations to style-related code.
83
84         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
85         (WebCore::isCSSPropertyName):
86         (WebCore::JSCSSStyleDeclaration::putDelegate):
87         Avoid calling cssPropertyName() twice when setting style on an element.
88         
89         * css/CSSStyleSelector.cpp:
90         (WebCore::useSVGZoomRules):
91         (WebCore::CSSStyleSelector::applyProperty):
92         Avoid calling isSVGElement() for every property, since only a two properties
93         care about it.
94
95 2011-04-06  Ian Henderson  <ianh@apple.com>
96
97         Reviewed by Antti Koivisto.
98
99         Unnecessary string allocation in CSSStyleDeclaration::setProperty
100         https://bugs.webkit.org/show_bug.cgi?id=57995
101
102         Pass the bool representing the property's importance directly instead
103         of constructing a string.
104
105         * css/CSSStyleDeclaration.cpp:
106         (WebCore::CSSStyleDeclaration::setProperty):
107
108 2011-04-06  Leandro Gracia Gil  <leandrogracia@chromium.org>
109
110         Reviewed by Steve Block.
111
112         Make the style of createFunctionOnlyCallback in V8 consistent with the JavaScriptCore version.
113         https://bugs.webkit.org/show_bug.cgi?id=57963
114
115         No new tests. LayoutTests/fast/dom/Geolocation/argument-types.html
116
117         * bindings/v8/V8Utilities.h:
118         (WebCore::createFunctionOnlyCallback):
119         * bindings/v8/custom/V8GeolocationCustom.cpp:
120         (WebCore::V8Geolocation::getCurrentPositionCallback):
121         (WebCore::V8Geolocation::watchPositionCallback):
122
123 2011-04-06  Brian Weinstein  <bweinstein@apple.com>
124
125         Reviewed by Adam Roben.
126
127         WebKit2: Support Windows 7 Gestures
128         https://bugs.webkit.org/show_bug.cgi?id=49824
129         <rdar://problem/8689728>
130         
131         Move WindowTouch.h from WebKit/win, so it can be used in both WebKit and WebKit2.
132
133         * WebCore.vcproj/WebCore.vcproj:
134         * platform/win/WindowsTouch.h: Copied from WebKit/win/WindowsTouch.h.
135
136 2011-04-06  Alexis Menard  <alexis.menard@openbossa.org>
137
138         Reviewed by Andreas Kling.
139
140         [Qt] We should use USE(QT_MULTIMEDIA) rather than ENABLE(QT_MULTIMEDIA).
141         https://bugs.webkit.org/show_bug.cgi?id=57974
142
143         We should use USE(QT_MULTIMEDIA) rather than ENABLE(QT_MULTIMEDIA).
144
145         No new tests needed, just a config flag rename.
146
147         * features.pri:
148
149 2011-04-06  Tyler Close  <tjclose@chromium.org>
150
151         Reviewed by Nate Chapin.
152
153         run-bindings-tests reference files out of sync with CodeGenerator*.pm
154         https://bugs.webkit.org/show_bug.cgi?id=57967
155
156         * bindings/scripts/test/V8/V8TestCallback.cpp:
157
158 2011-04-06  Asanka Herath  <asanka@chromium.org>
159
160         Reviewed by Darin Fisher.
161
162         Add new TargetType: TargetIsFavicon
163
164         https://bugs.webkit.org/show_bug.cgi?id=57659
165
166         No new functionality added, so no additional tests.
167
168         * platform/network/ResourceRequestBase.h:
169
170 2011-04-06  David Hyatt  <hyatt@apple.com>
171
172         Reviewed by Simon Fraser.
173
174         https://bugs.webkit.org/show_bug.cgi?id=57981
175         
176         Update the column count and width computation algorithm for CSS3 multi-column layout 
177         to match the revised pseudo-algorithm in the latest draft of the spec.
178
179         * rendering/RenderBlock.cpp:
180         (WebCore::RenderBlock::calcColumnWidth):
181
182 2011-04-06  Ryosuke Niwa  <rniwa@webkit.org>
183
184         Reviewed by Eric Seidel.
185
186         borderPaddingMarginStart and borderPaddingMarginEnd should take RenderInline
187         https://bugs.webkit.org/show_bug.cgi?id=57965
188
189         Changed the argument types of borderPaddingMarginStart and borderPaddingMarginEnd
190         from RenderBoxModelObject to RenderInline since they call marginStart and marginEnd
191         instead of marginStartForChild and marginEndForChild respectively.
192
193         Calling these two functions on RenderInline is okay because writing-mode cannot differ
194         from that of the containing block.
195
196         * rendering/RenderBlockLineLayout.cpp:
197         (WebCore::borderPaddingMarginStart):
198         (WebCore::borderPaddingMarginEnd):
199         (WebCore::inlineLogicalWidth):
200
201 2011-04-06  Sheriff Bot  <webkit.review.bot@gmail.com>
202
203         Unreviewed, rolling out r83039.
204         http://trac.webkit.org/changeset/83039
205         https://bugs.webkit.org/show_bug.cgi?id=57978
206
207         introduced a new regression in conjunction to
208         ReplaceSelectionCommand (Requested by rniwa on #webkit).
209
210         * editing/EditingStyle.cpp:
211         (WebCore::EditingStyle::init):
212         * editing/InsertParagraphSeparatorCommand.cpp:
213         (WebCore::InsertParagraphSeparatorCommand::doApply):
214
215 2011-04-06  Naoki Takano  <takano.naoki@gmail.com>
216
217         Reviewed by David Levin.
218
219         Webkit ignores PgUp/PgDown/Home/End in SELECT tag objects
220         https://bugs.webkit.org/show_bug.cgi?id=27658
221
222         Test: fast/events/select-element.html
223
224         * dom/SelectElement.cpp:
225         (WebCore::nextValidIndex): Moved from elsewhere in the file to be used by other routines.
226         (WebCore::nextSelectableListIndexPageAway): Returns a selectable index one page away from the given index.
227         (WebCore::nextSelectableListIndex): Implemented with nextValidIndex.
228         And converted to a normal static function from a private function of SelectElement.
229         (WebCore::previousSelectableListIndex): Implemented with nextValidIndex.
230         And converted to a normal static function from a private function of SelectElement.
231         (WebCore::firstSelectableListIndex): Returns the first selectable index.
232         (WebCore::lastSelectableListIndex): Returns the last selectable index.
233         (WebCore::SelectElement::menuListDefaultEventHandler): Converted from C cast to C++ cast.
234         (WebCore::SelectElement::listBoxDefaultEventHandler): Adds support for PageUp/PageDown/Home/End with both single and multiple selection.
235
236         * dom/SelectElement.h:
237         (WebCore::SelectElement::): Remove nextSelectableListIndex() and previousSelectableListIndex().
238
239         * rendering/RenderListBox.h: Makes RenderListBox::size public so that PageUp/PageDown behavior can use the actual list size rather than that specified in HTML.
240         They can differ due to the minimum size imposed by RenderListBox.
241
242 2011-04-06  David Hyatt  <hyatt@apple.com>
243
244         Reviewed by Dan Bernstein.
245
246         https://bugs.webkit.org/show_bug.cgi?id=57975
247
248         The "More..." link for line clamping no longer shows up in Safari RSS. Fix the isLink() check
249         to just look at the style, so that it can find the InlineTextBox and not care that it's a child
250         of the link element and not the line box for the link element itself (since that line box got
251         culled).
252
253         * rendering/RenderFlexibleBox.cpp:
254         (WebCore::RenderFlexibleBox::applyLineClamp):
255
256 2011-04-06  Brady Eidson  <beidson@apple.com>
257
258         Reviewed by Anders Carlsson.
259
260         https://bugs.webkit.org/show_bug.cgi?id=57973 and https://bugs.webkit.org/show_bug.cgi?id=57973
261         WK2 icon database should be able to get a CGImage of a specific size
262
263         * platform/graphics/BitmapImage.h:
264         * platform/graphics/Image.h:
265         (WebCore::Image::getFirstCGImageRefOfSize):
266         
267         * platform/graphics/cg/ImageCG.cpp:
268         (WebCore::BitmapImage::getFirstCGImageRefOfSize): Walk the frames of the image until reaching the
269           first frame of the requested size.
270
271 2011-04-06  Malcolm MacLeod  <malcolm.macleod@tshwanedje.com>
272
273         Reviewed by Kevin Ollivier.
274
275         [wx] Fix cursor handling so that we always call the chrome to set it.
276         
277         https://bugs.webkit.org/show_bug.cgi?id=57972
278
279         * platform/wx/WidgetWx.cpp:
280         (WebCore::Widget::setCursor):
281
282 2011-04-06  David Hyatt  <hyatt@apple.com>
283
284         Reviewed by Dan Bernstein.
285
286         https://bugs.webkit.org/show_bug.cgi?id=41445
287         
288         Visited links painting with black background. Make sure that if the visited style has
289         the initial background color (transparent) set that we just use the unvisited color.
290
291         Added fast/history/visited-link-background-color.html
292
293         * rendering/style/RenderStyle.cpp:
294         (WebCore::RenderStyle::visitedDependentColor):
295
296 2011-04-06  Csaba Osztrogonác  <ossy@webkit.org>
297
298         Unreviewed Qt buildfix after r83079.
299
300         * WebCore.pro:
301
302 2011-04-06  Dean Jackson  <dino@apple.com>
303
304         Reviewed by Chris Marrin.
305
306         https://bugs.webkit.org/show_bug.cgi?id=56936
307         Crash in ImplicitAnimation::~ImplicitAnimation
308
309         Make sure the style and start time waiting lists
310         are cleared in the CompositeAnimation destructor. This
311         way, no running transitions can be left in a state
312         where they are destroyed as the AnimationControllerPrivate
313         cleans up.
314
315         * page/animation/CompositeAnimation.cpp:
316         (WebCore::CompositeAnimation::~CompositeAnimation):
317
318 2011-04-06  Robert Sesek  <rsesek@chromium.org>
319
320         Reviewed by Alexey Proskuryakov.
321
322         Move code duplicated between the WebKit/mac and WebKit2 down to WebCore because Chromium will need it too
323         https://bugs.webkit.org/show_bug.cgi?id=54969
324
325         No change in behavior; no new tests.
326
327         * editing/TextIterator.cpp:
328         (WebCore::TextIterator::locationAndLengthFromRange): New method from duplicated code in WebKits
329         * editing/TextIterator.h:
330         * page/Frame.cpp:
331         (WebCore::Frame::rangeForPoint): New method from duplicated code in WebKits
332
333 2011-04-06  Leandro Gracia Gil  <leandrogracia@chromium.org>
334
335         Reviewed by Steve Block.
336
337         Factoring the creation of 'FunctionOnly' callbacks in JavaScriptCore.
338         https://bugs.webkit.org/show_bug.cgi?id=57770
339
340         Create a template from an existing functionality in JSGeolocationCustom.cpp
341         to be used by the custom bindings of both Geolocation and the Media Stream API.
342         V8 version of this bug: https://bugs.webkit.org/show_bug.cgi?id=57760
343
344         No new tests. LayoutTests/fast/dom/Geolocation/argument-types.html
345
346         * Android.jscbindings.mk:
347         * CMakeLists.txt:
348         * GNUmakefile.am:
349         * WebCore.gypi:
350         * WebCore.pro:
351         * WebCore.vcproj/WebCore.vcproj:
352         * WebCore.xcodeproj/project.pbxproj:
353         * bindings/js/CallbackFunction.cpp: Added.
354         (WebCore::checkFunctionOnlyCallback):
355         * bindings/js/CallbackFunction.h: Added.
356         (WebCore::createFunctionOnlyCallback):
357         * bindings/js/JSBindingsAllInOne.cpp:
358         * bindings/js/JSGeolocationCustom.cpp:
359         (WebCore::JSGeolocation::getCurrentPosition):
360         (WebCore::JSGeolocation::watchPosition):
361
362 2011-04-06  Alexis Menard  <alexis.menard@openbossa.org>
363
364         Reviewed by Andreas Kling.
365
366         [Qt] Implement fullscreen playback for the GStreamer backend.
367         https://bugs.webkit.org/show_bug.cgi?id=56826
368
369         Implement support for fullscreen playback when building the
370         Qt port with the GStreamer backend (DEFINES+=USE_GSTREAMER=1).
371         The implementation is done in FullScreenVideoQt alongside with
372         the Qt Multimedia support.
373
374         No new tests because layout tests cover it. They are not yet activated
375         but will be any time soon.
376
377         * platform/graphics/gstreamer/PlatformVideoWindowPrivate.h:
378         * platform/graphics/gstreamer/PlatformVideoWindowQt.cpp:
379         (FullScreenVideoWindow::FullScreenVideoWindow):
380         (FullScreenVideoWindow::setVideoElement):
381         (FullScreenVideoWindow::closeEvent):
382         (FullScreenVideoWindow::keyPressEvent):
383         (FullScreenVideoWindow::event):
384         (FullScreenVideoWindow::showFullScreen):
385         (FullScreenVideoWindow::hideCursor):
386         (FullScreenVideoWindow::showCursor):
387
388 2011-04-06  Ryosuke Niwa  <rniwa@webkit.org>
389
390         Reviewed by Dimitri Glazkov.
391
392         Bundle lineLeftOffset and lineRightOffset as a class
393         https://bugs.webkit.org/show_bug.cgi?id=57851
394
395         Added a new class LineOffsets that encapsulates lineLeftOffset and lineRightOffset.
396         The patch makes clear that lineLeftOffset and lineRightOffset are never read individually
397         and only the difference is used to compute the width.
398
399         * rendering/RenderBlock.h:
400         * rendering/RenderBlockLineLayout.cpp:
401         (WebCore::RenderBlock::skipLeadingWhitespace): Takes LineOffsets instead of two integers.
402         (WebCore::LineOffsets::LineOffsets): Added.
403         (WebCore::LineOffsets::width): Added.
404         (WebCore::LineOffsets::setLeft): Added.
405         (WebCore::LineOffsets::setRight): Added.
406         (WebCore::RenderBlock::findNextLineBreak): Calls skipLeadingWhitespace and positionNewFloatOnLine.
407         (WebCore::RenderBlock::positionNewFloatOnLine): Takes LineOffsets instead of two integers.
408
409 2011-04-06  David Hyatt  <hyatt@apple.com>
410
411         Reviewed by Dan Bernstein.
412
413         https://bugs.webkit.org/show_bug.cgi?id=57916
414         
415         Implement an optimization to the line box tree to cull out most of the intermediate
416         line boxes that can occur between the root line box and the leaves of the tree (images
417         and text).
418
419         RenderInlines now have a boolean member, m_alwaysCreateLineBoxes,
420         that starts off as false. Only if it gets flipped to true will there be any line boxes
421         created for that RenderInline.
422         
423         * page/FocusController.cpp:
424         (WebCore::FocusController::advanceFocusDirectionally):
425         Adjust the ordering of updateLayout calls to make sure rects aren't queried unless layout
426         is up to date.
427
428         * page/SpatialNavigation.cpp:
429         (WebCore::hasOffscreenRect):
430         (WebCore::nodeRectInAbsoluteCoordinates):
431         Add asserts in spatial navigation code to catch any future bad queries that might be made
432         for rectangles without layout being up to date.
433
434         * platform/graphics/FloatRect.cpp:
435         (WebCore::FloatRect::uniteIfNonZero):
436         * platform/graphics/FloatRect.h:
437         * platform/graphics/IntRect.cpp:
438         (WebCore::IntRect::uniteIfNonZero):
439         * platform/graphics/IntRect.h:
440         Add a new unite function that is useful for the render tree to FloatRect and IntRect.  This
441         version allows rect unites to happen if either width or height is nonzero.
442
443         * rendering/HitTestResult.cpp:
444         (WebCore::HitTestResult::addNodeToRectBasedTestResult):
445         Make sure rect-based hit testing properly adds in culled inline ancestors to the set of nodes
446         if content inside those inlines is hit.
447
448         * rendering/InlineBox.h:
449         (WebCore::InlineBox::logicalFrameRect):
450         Fix a bug in this function for obtaining the logical frame rect of an inline box.
451
452         * rendering/InlineFlowBox.cpp:
453         (WebCore::InlineFlowBox::addToLine):
454         addToLine now also checks line gap in the line box tree optimization checks.
455     
456         (WebCore::InlineFlowBox::addTextBoxVisualOverflow):
457         (WebCore::InlineFlowBox::computeOverflow):
458         * rendering/InlineFlowBox.h:
459         Rewritten to add the text box overflow to the text box itself.
460
461          * rendering/InlineTextBox.cpp:
462         (WebCore::InlineTextBox::destroy):
463         Destroy has been changed to call a helper function to remove and destroy the line boxes that
464         is now called from one additional spot.
465
466         (WebCore::InlineTextBox::logicalOverflowRect):
467         (WebCore::InlineTextBox::setLogicalOverflowRect):
468         Text boxes now cache their own overflow in a global hash table.
469
470         (WebCore::InlineTextBox::baselinePosition):
471         (WebCore::InlineTextBox::lineHeight):
472         Changed to not assume that the parent line box's renderer is the RenderText's immediate
473         parent, since intermediate line boxes may have been culled.
474
475         (WebCore::InlineTextBox::paint):
476         Paint now properly checks only the text box overflow instead of the parent line box's overflow.
477
478         * rendering/InlineTextBox.h:
479         (WebCore::InlineTextBox::logicalTopVisualOverflow):
480         (WebCore::InlineTextBox::logicalBottomVisualOverflow):
481         (WebCore::InlineTextBox::logicalLeftVisualOverflow):
482         (WebCore::InlineTextBox::logicalRightVisualOverflow):
483         New accessors to obtain overflow for inline text boxes.
484
485         * rendering/RenderBlock.cpp:
486         (WebCore::RenderBlock::updateFirstLetter):
487         updateFirstLetter now removes text boxes from the line box tree before it destroys them, since those
488         text boxes may not have anything in between them and the block that contains the inline first letter
489         container.
490
491         * rendering/RenderBlockLineLayout.cpp:
492         (WebCore::RenderBlock::createLineBoxes):
493         The culling optimization is done here.  Only if the RenderInline says that boxes are allowed will they
494         be created.
495
496         (WebCore::RenderBlock::layoutInlineChildren):
497         The state of the RenderInline is updated here, in case it is discovered that line boxes are now needed.
498         This is done before any lines are built.
499
500         * rendering/RenderInline.cpp:
501         (WebCore::RenderInline::RenderInline):
502         The new m_alwaysCreateLineBoxes flag has been added to the constructor.
503
504         (WebCore::RenderInline::styleDidChange):
505         An initial update of the m_alwaysCreateLineBoxes happens here for things that can be checked immediately
506         (like having a layer, borders, padding, margins or backgrounds).  Some checks that depend on examining
507         the RenderInline's parent (including first line styles) happen later in layoutInlineChildren.
508
509         (WebCore::RenderInline::updateAlwaysCreateLineBoxes):
510         The function called by layoutInlineChildren to check parent and child style differences (e.g., font,
511         vertical alignment, line height, etc.).
512
513         (WebCore::RenderInline::absoluteRects):
514         (WebCore::RenderInline::culledInlineAbsoluteRects):
515         absoluteRects calls culledInlineAbsoluteRects when m_alwaysCreateLineBoxes is false.
516
517         (WebCore::RenderInline::absoluteQuads):
518         (WebCore::RenderInline::culledInlineAbsoluteQuads):
519         absoluteQuads calls culledInlineAbsoluteQuads when m_alwaysCreateLineBoxes is false.
520
521         (WebCore::RenderInline::offsetLeft):
522         (WebCore::RenderInline::offsetTop):
523         offsetLeft and offsetTop now check descendant renderers when m_alwaysCreateLineBoxes is false.
524
525         (WebCore::RenderInline::linesBoundingBox):
526         (WebCore::RenderInline::culledInlineBoundingBox):
527         lineBoundingBox calls culledInlineBoundingBox when m_alwaysCreateLineBoxes is false.
528
529         (WebCore::RenderInline::culledInlineFirstLineBox):
530         (WebCore::RenderInline::culledInlineLastLineBox):
531         Helpers that return the first and last line box descendants. Used by firstLineBoxIncludingCulling and
532         lastLineBoxIncludingCulling (which are in turn called by offsetLeft and offsetTop).
533
534         (WebCore::RenderInline::culledInlineVisualOverflowBoundingBox):
535         (WebCore::RenderInline::linesVisualOverflowBoundingBox):
536         linesVisualOverflowBoundingBox calls culledInlineVisualOverflowBoundingBox when m_alwaysCreateLineBoxes is false.
537
538         (WebCore::RenderInline::clippedOverflowRectForRepaint):
539         The initial bailout check is now done using firstLineBoxIncludingCulling instead of just firstLineBox.
540
541         (WebCore::RenderInline::dirtyLineBoxes):
542         dirtyLineBoxes now crawls into descendants to figure out which root lines to dirty when
543         m_alwaysCreateLineBoxes is false.
544
545         (WebCore::RenderInline::createAndAppendInlineFlowBox):
546         Clear the m_alwaysCreateLineBoxes if a box gets added anyway. This happens for leaf inline flows and also
547         when line-box-contain is set to an unusual value.
548
549         (WebCore::RenderInline::addFocusRingRects):
550         Used culledInlineAbsoluteRects in place of the line box walk when m_alwaysCreateLineBoxes is false.
551
552         * rendering/RenderInline.h:
553         (WebCore::RenderInline::firstLineBoxIncludingCulling):
554         (WebCore::RenderInline::lastLineBoxIncludingCulling):
555         Helpers used in a few places (like offsetLeft and offsetTop), mostly in places where the existence of a box
556         is all that needs checking.
557
558         (WebCore::RenderInline::alwaysCreateLineBoxes):
559         (WebCore::RenderInline::setAlwaysCreateLineBoxes):
560         Functions for getting and setting the m_alwaysCreateLineBoxes flag.
561
562         * rendering/RenderLineBoxList.cpp:
563         (WebCore::RenderLineBoxList::dirtyLinesFromChangedChild):
564         Modified to use firstLineBoxIncludingCulling and lastLineBoxIncludingCulling to ensure the right set of
565         lines get dirtied.
566
567         * rendering/RenderText.cpp:
568         (WebCore::RenderText::removeAndDestroyTextBoxes):
569         New helper invoked by destroy and also from updateFirstLetter.
570
571         (WebCore::RenderText::destroy):
572         Changed to call removeAndDestroyTextBoxes.
573
574         (WebCore::RenderText::absoluteRects):
575         Fixed to be properly physical instead of logical.
576
577         (WebCore::RenderText::linesVisualOverflowBoundingBox):
578         New implementation for RenderText that gives the bounding box of the text boxes including overflow from
579         shadows, glyphs, text-stroke, etc.  Used by RenderInline::culledInlineVisualOverflowBoundingBox.
580
581         * rendering/RenderText.h:
582         * rendering/svg/RenderSVGInline.cpp:
583         (WebCore::RenderSVGInline::RenderSVGInline):
584         RenderSVGInline always sets m_alwaysCreateLineBoxes to true so that SVG is unaffected by this optimization.
585
586         * rendering/svg/SVGRootInlineBox.cpp:
587         (WebCore::SVGRootInlineBox::layoutCharactersInTextBoxes):
588         (WebCore::SVGRootInlineBox::layoutChildBoxes):
589         Move the isInlineFlowBox asserts to after the generated content skips, since the generated content boxes are
590         now InlineTextBoxes (the enclosing InlineFlowBoxes got culled).
591
592 2011-04-05  Enrica Casucci  <enrica@apple.com>
593
594         Reviewed by Darin Adler.
595
596         REGRESSION: Drag & Drop Gmail Attachments doesn't work.
597         https://bugs.webkit.org/show_bug.cgi?id=57909
598         <rdar://problem/9103220>
599
600         In WebKit2 we cannot rely on the value returned by platformData() that
601         on Mac returns an NSDraggingInfo object. This is available only in the UI
602         process. Therefore we should use m_pasteboard instead.
603         We cannot change what platformData() returns on Mac, since there are
604         delegate methods that receive a NSDraggingInfo object (only in WebKit).
605         
606         * platform/DragData.h:
607         (WebCore::DragData::pasteboard): Added.
608         * platform/mac/ClipboardMac.mm:
609         (WebCore::Clipboard::create): Changed to use pasteboard() instead of platformData().
610         * platform/mac/DragDataMac.mm:
611         (WebCore::DragData::asColor): Replaced references to m_platformData with m_pasteboard.
612         (WebCore::DragData::asURL): Same as above.
613
614 2011-04-06  Benjamin Poulain  <benjamin.poulain@nokia.com>
615
616         Reviewed by Darin Adler.
617
618         ClipboardWin has unused variables "ExceptionCode ec"
619         https://bugs.webkit.org/show_bug.cgi?id=57952
620
621         Remove the unused variable.
622
623         * platform/win/ClipboardWin.cpp:
624         (WebCore::ClipboardWin::declareAndWriteDragImage):
625         (WebCore::ClipboardWin::writePlainText):
626
627 2011-04-06  Ryosuke Niwa  <rniwa@webkit.org>
628
629         Reviewed by Dimitri Glazkov.
630
631         Split getBorderPaddingMargin into two functions
632         https://bugs.webkit.org/show_bug.cgi?id=57947
633
634         * rendering/RenderBlockLineLayout.cpp:
635         (WebCore::borderPaddingMarginStart): Extracted from getBorderPaddingMargin.
636         (WebCore::borderPaddingMarginEnd): Ditto.
637         (WebCore::inlineLogicalWidth): Calls borderPaddingMarginStart and borderPaddingMarginEnd.
638         (WebCore::RenderBlock::findNextLineBreak): Ditto.
639
640 2011-04-06  MORITA Hajime  <morrita@google.com>
641
642         Reviewed by Dimitri Glazkov.
643
644         [Refactoring] <progress> should not have manual layout code.
645         https://bugs.webkit.org/show_bug.cgi?id=57801
646
647         - Simplified RenderProgress, removing its custom layout code
648         - Introducing ProgressValueElement and ProgressBarElement, replacing
649           ProgressBarValueElement. 
650         
651         Now the structure is almost identical to <meter>, 
652         other than:
653         - RenderProgress has animated painting, thus manages its own timer.
654         - Both ProgressValueElement and ProgressBarElement has pseudo classes
655           which don't changes during its lifetime.
656        
657         * Android.mk:
658         * CMakeLists.txt:
659         * GNUmakefile.am:
660         * WebCore.gypi:
661         * WebCore.pro:
662         * WebCore.vcproj/WebCore.vcproj:
663         * WebCore.xcodeproj/project.pbxproj:
664         * css/html.css:
665         (progress):
666         (progress::-webkit-progress-bar):
667         (progress::-webkit-progress-value):
668         * html/HTMLProgressElement.cpp:
669         (WebCore::HTMLProgressElement::~HTMLProgressElement):
670         (WebCore::HTMLProgressElement::create):
671         (WebCore::HTMLProgressElement::attach):
672         (WebCore::HTMLProgressElement::didElementStateChange):
673         (WebCore::HTMLProgressElement::createShadowSubtree):
674         * html/HTMLProgressElement.h:
675         * html/shadow/ProgressShadowElement.cpp: Copied from Source/WebCore/html/shadow/ProgressBarValueElement.h.
676         (WebCore::ProgressShadowElement::ProgressShadowElement):
677         (WebCore::ProgressShadowElement::progressElement):
678         (WebCore::ProgressShadowElement::rendererIsNeeded):
679         (WebCore::ProgressBarElement::shadowPseudoId):
680         (WebCore::ProgressValueElement::shadowPseudoId):
681         (WebCore::ProgressValueElement::setWidthPercentage):
682         * html/shadow/ProgressShadowElement.h: Renamed from Source/WebCore/html/shadow/ProgressBarValueElement.h.
683         (WebCore::ProgressBarElement::ProgressBarElement):
684         (WebCore::ProgressBarElement::create):
685         (WebCore::ProgressValueElement::ProgressValueElement):
686         (WebCore::ProgressValueElement::create):
687         * rendering/RenderProgress.cpp:
688         (WebCore::RenderProgress::RenderProgress):
689         (WebCore::RenderProgress::updateFromElement):
690         (WebCore::RenderProgress::animationTimerFired):
691         * rendering/RenderProgress.h:
692         (WebCore::RenderProgress::requiresForcedStyleRecalcPropagation):
693         (WebCore::RenderProgress::canHaveChildren):
694
695 2011-04-06  Mario Sanchez Prada  <msanchez@igalia.com>
696
697         Reviewed by Chris Fleizach.
698
699         [GTK] Do not reference AccessibilityRenderObject from platform dependent code
700         https://bugs.webkit.org/show_bug.cgi?id=57955
701
702         Do not reference AccessibilityRenderObject from platform specific code
703
704         Added new virtual functions to AccessibilityObject.h and removed
705         explicit references to AccessibilityRenderObject from GTK code.
706
707         * accessibility/AccessibilityObject.h:
708         (WebCore::AccessibilityObject::renderer): New virtual method,
709         returning 0 by default. Overriden by AccessibilityRenderObject.
710         (WebCore::AccessibilityObject::correspondingLabelForControlElement):
711         New virtual method, returning 0 by default. It complements the
712         already present method correspondingControlForLabelElement().
713
714         * accessibility/AccessibilityRenderObject.h:
715         (WebCore::AccessibilityRenderObject::renderer): Made virtual.
716
717         * accessibility/gtk/AXObjectCacheAtk.cpp:
718         (WebCore::emitTextChanged): Reference  AccessibilityObject,
719         instead of AccessibilityRenderObject.
720         (WebCore::AXObjectCache::nodeTextChangePlatformNotification):
721         Ditto.
722
723         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
724         (webkit_accessible_get_name): Do not reference
725         AccessibilityRenderObject.
726         (webkit_accessible_get_description): Ditto.
727         (setAtkRelationSetFromCoreObject): Ditto.
728         (optionFromList): Ditto.
729         (optionFromSelection): Ditto.
730         (webkit_accessible_selection_clear_selection): Ditto.
731         (webkit_accessible_selection_get_selection_count): Ditto.
732         (webkit_accessible_selection_select_all_selection): Ditto.
733         (textForObject): Ditto.
734         (webkit_accessible_text_get_text): Ditto.
735         (getPangoLayoutForAtk): Ditto.
736         (webkit_accessible_text_get_caret_offset): Ditto.
737         (baselinePositionForRenderObject): Ditto.
738         (getAttributeSetForAccessibilityObject): Ditto.
739         (accessibilityObjectLength): Ditto.
740         (getSelectionOffsetsForObject): Ditto.
741         (webkit_accessible_text_set_selection): Ditto.
742         (webkit_accessible_text_set_caret_offset): Ditto.
743         (webkit_accessible_table_get_caption): Ditto.
744         (getInterfaceMaskFromObject): Ditto.
745
746         * accessibility/gtk/WebKitAccessibleHyperlink.cpp:
747         (getRangeLengthForObject): Ditto.
748
749         Removed unused renderer() method from AccessibilityMenuList.
750
751         * accessibility/AccessibilityMenuList.h: Removed unused method.
752         * accessibility/AccessibilityMenuList.cpp: Removed unused method.
753
754 2011-04-06  Alexander Pavlov  <apavlov@chromium.org>
755
756         Reviewed by Pavel Feldman.
757
758         Web Inspector: Javascipt warning link expand and overlap with icons in js console
759         https://bugs.webkit.org/show_bug.cgi?id=57939
760
761         * inspector/front-end/inspector.js:
762         (WebInspector.linkifyURLAsNode):
763
764 2011-04-06  Alexander Pavlov  <apavlov@chromium.org>
765
766         Reviewed by Pavel Feldman.
767
768         Web Inspector: Beautify parameter names in Inspector.json (CSS domain)
769         https://bugs.webkit.org/show_bug.cgi?id=57931
770
771         * inspector/Inspector.json:
772
773 2011-04-06  Jia Pu  <jpu@apple.com>
774
775         Reviewed by Darin Adler.
776
777         [Mac] WebCore need to notify AppKit spell checker after user has modified autocorrected text.
778         https://bugs.webkit.org/show_bug.cgi?id=57665
779         <rdar://problem/7350477>
780
781         We need to track how user modified an autocorrected word. If he changed it back to original
782         text, we want to record AutocorrectionReverted response. And if he changed it to something
783         else, we want to record AutocorrectionEdited response.
784
785         To achieve this, we need to distringuish between text replacement caused by autocorrection
786         from that due to other causes, such as reversion, text substitution, etc. So we added a new
787         marker type "Autocorrected". We also need to be able to check for correction, even when we
788         don't intend to actually carry out replacement. For this, we introduced a new TextCheckingOption
789         value, "CheckForCorrection".
790
791         We also added DocumentMarkerController::markersInRange() to retrieve a vector of markers in
792         specified range, and of specified type.
793
794         * dom/DocumentMarker.h:
795         * dom/DocumentMarkerController.cpp:
796         (WebCore::DocumentMarkerController::markersInRange):
797         (WebCore::DocumentMarkerController::hasMarkers):
798         * dom/DocumentMarkerController.h:
799         * editing/Editor.cpp:
800         (WebCore::markerTypesForAutocorrection):
801         (WebCore::markersHaveIdenticalDescription):
802         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
803         (WebCore::Editor::recordSpellcheckerResponseForModifiedCorrection):
804         (WebCore::Editor::changeBackToReplacedString):
805         (WebCore::Editor::markMisspellingsAndBadGrammar):
806         (WebCore::Editor::applyCorrectionPanelInfo):
807         (WebCore::Editor::unappliedSpellCorrection):
808         (WebCore::Editor::textCheckingTypeMaskFor):
809         * editing/Editor.h:
810         * editing/SpellingCorrectionCommand.cpp:
811         (WebCore::SpellingCorrectionCommand::doApply):
812
813 2011-04-06  Sheriff Bot  <webkit.review.bot@gmail.com>
814
815         Unreviewed, rolling out r83045.
816         http://trac.webkit.org/changeset/83045
817         https://bugs.webkit.org/show_bug.cgi?id=57953
818
819         Broke win layout tests (Requested by podivilov on #webkit).
820
821         * GNUmakefile.am:
822         * inspector/front-end/DebuggerPresentationModel.js:
823         (WebInspector.DebuggerPresentationModel.prototype._addScript):
824         (WebInspector.DebuggerPresentationModel.prototype.toggleFormatSourceFiles):
825
826 2011-04-06  Ryosuke Niwa  <rniwa@webkit.org>
827
828         Moved the declaration of positionNewFloatOnLine in RenderBlock.h after r83042.
829
830         * rendering/RenderBlock.h:
831
832 2011-03-27  Diego Gonzalez  <diegohcg@webkit.org>
833
834         Reviewed by Kenneth Rohde Christiansen.
835
836         [Qt] Re-draw the <input> fields for Qt Mobile Theme to do not override elements already styled.
837         https://bugs.webkit.org/show_bug.cgi?id=57007
838
839         * CodeGenerators.pri:
840         * css/themeQtMobile.css: Removed.
841         * platform/qt/QtMobileWebStyle.cpp:
842         (drawRectangularControlBackground):
843         (QtMobileWebStyle::drawPrimitive):
844         (QtMobileWebStyle::drawComplexControl):
845         * platform/qt/QtMobileWebStyle.h:
846         * platform/qt/RenderThemeQt.cpp:
847         (WebCore::RenderThemeQt::isControlStyled):
848         (WebCore::RenderThemeQt::paintTextField):
849
850 2011-04-06  Jia Pu  <jpu@apple.com>
851
852         Reviewed by Darin Adler.
853
854         [Mac] When autocorrection occurs without showing correction panel, WebCore need to post accessibility notification.
855         https://bugs.webkit.org/show_bug.cgi?id=57800
856         <rdar://problem/9218223>
857
858         Defined a new accessibility notification type, AXAutocorrectionOccured. Editor::markAllMisspellingsAndBadGrammarInRanges()
859         now posts said notification when any autocorrection or text replacement (e.g. replacing "(c)" with copyright mark) takes place.
860
861         * accessibility/AXObjectCache.h:
862         * accessibility/chromium/AXObjectCacheChromium.cpp:
863         (WebCore::AXObjectCache::postPlatformNotification):
864         * accessibility/mac/AXObjectCacheMac.mm:
865         (WebCore::AXObjectCache::postPlatformNotification):
866         * editing/Editor.cpp:
867         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
868
869 2011-04-06  Martin Robinson  <mrobinson@igalia.com>
870
871         Build fix for debug Cairo builds.
872
873         * platform/graphics/cairo/PlatformContextCairo.cpp:
874         (WebCore::PlatformContextCairo::pushImageMask): Update the reference to m_maskInformation.
875
876 2011-04-06  Diego Gonzalez  <diegohcg@webkit.org>
877
878         Reviewed by Antonio Gomes.
879
880         [Qt] Style fix for QtMobileWebStyle.h
881         https://bugs.webkit.org/show_bug.cgi?id=57708
882
883         * platform/qt/QtMobileWebStyle.h:
884
885 2011-04-06  Andras Becsi  <abecsi@webkit.org>
886
887         Reviewed by Darin Adler.
888
889         Invalid color #{predefined colorName} is accepted by the CSS parser.
890         https://bugs.webkit.org/show_bug.cgi?id=15360
891
892         Test: fast/css/invalid-predefined-color.html
893
894         * css/CSSGrammar.y: Remove superfluous hexcolor production.
895         * css/tokenizer.flex: A hexadecimal number should consist of [a-fA-F0-9] values ({h}).
896
897 2011-03-30  Pavel Podivilov  <podivilov@chromium.org>
898
899         Reviewed by Pavel Feldman.
900
901         Web Inspector: add test for script formatter worker.
902         https://bugs.webkit.org/show_bug.cgi?id=57447
903
904         Test: inspector/debugger/script-formatter.html
905
906         * GNUmakefile.am:
907         * inspector/front-end/DebuggerPresentationModel.js:
908         (WebInspector.DebuggerPresentationModel):
909         (WebInspector.DebuggerPresentationModel.prototype.toggleFormatSourceFiles):
910
911 2011-04-06  Martin Robinson  <mrobinson@igalia.com>
912
913         Reviewed by Xan Lopez.
914
915         [Cairo] Hide the details of image masking in PlatformContextCairo
916         https://bugs.webkit.org/show_bug.cgi?id=57878
917
918         No new tests. This is just a refactor.
919
920         * platform/graphics/GraphicsContext.h:
921         * platform/graphics/cairo/GraphicsContextCairo.cpp:
922         (WebCore::GraphicsContext::savePlatformState): Call into PlatformContextCairo now to
923         do the actual cairo_save. Remove information about image masking.
924         (WebCore::GraphicsContext::restorePlatformState): Call into PlatformContextCairo now to
925         do the actual cairo_restore. Remove information about image masking.
926         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h:
927         * platform/graphics/cairo/ImageBufferCairo.cpp:
928         (WebCore::ImageBuffer::clip): Use PlatformContextCairo here now.
929         * platform/graphics/cairo/PlatformContextCairo.cpp:
930         (WebCore::PlatformContextCairo::restore): Added.
931         (WebCore::PlatformContextCairo::save): Added.
932         (WebCore::PlatformContextCairo::pushImageMask): Added.
933         * platform/graphics/cairo/PlatformContextCairo.h:
934         (WebCore::ImageMaskInformation::update): Moved from GraphicsContextPlatformPrivateCairo.h.
935         (WebCore::ImageMaskInformation::isValid): Ditto.
936         (WebCore::ImageMaskInformation::maskSurface): Ditto.
937         (WebCore::ImageMaskInformation::maskRect): Ditto.
938
939 2011-04-02  Diego Gonzalez  <diegohcg@webkit.org>
940
941         Reviewed by Csaba Osztrogonác.
942
943         [Qt] Radio buttons are showing wrong with mobile theme
944         https://bugs.webkit.org/show_bug.cgi?id=57706
945
946         * platform/qt/QtMobileWebStyle.cpp:
947         (QtMobileWebStyle::drawRadio):
948
949 2011-04-06  Ryosuke Niwa  <rniwa@webkit.org>
950
951         Reviewed by Eric Seidel.
952
953         Move RenderBlock::positionNewFloatOnLine to RenderBlockLineLayout.cpp
954         https://bugs.webkit.org/show_bug.cgi?id=57943
955
956         * rendering/RenderBlock.cpp: Removed positionNewFloatOnLine.
957         * rendering/RenderBlockLineLayout.cpp:
958         (WebCore::RenderBlock::positionNewFloatOnLine): Moved from RenderBlock.cpp
959
960 2011-04-05  Diego Gonzalez  <diegohcg@webkit.org>
961
962         Buildfix after r82125.
963
964         [Qt] QtWebKit will not compile with QT_ASCII_CAST_WARNINGS enabled
965         https://bugs.webkit.org/show_bug.cgi?id=57087
966
967         * platform/qt/QtMobileWebStyle.cpp:
968         (QtMobileWebStyle::findChecker):
969         (QtMobileWebStyle::findRadio):
970         (QtMobileWebStyle::findComboButton):
971
972 2011-04-06  Pavel Podivilov  <podivilov@chromium.org>
973
974         Reviewed by Yury Semikhatsky.
975
976         Web Inspector: inline script imports in ScriptFormatterWorker.js so it works in Safari release.
977         https://bugs.webkit.org/show_bug.cgi?id=57641
978
979         * WebCore.xcodeproj/project.pbxproj:
980         * gyp/streamline-inspector-source.sh:
981         * inspector/combine-javascript-resources.pl: Renamed from Source/WebCore/combine-javascript-resources.
982         * inspector/inline-javascript-imports.py: Added.
983
984 2011-04-06  Ryosuke Niwa  <rniwa@webkit.org>
985
986         Reviewed by Eric Seidel.
987
988         REGRESSION (r46914, r48764): When typing in Mail, line wrapping frequently occurs in the middle of words
989         https://bugs.webkit.org/show_bug.cgi?id=57872
990
991         r46914 initially introduced a regression by replacing calls to styleAtPosition by editingStyleAtPosition
992         because editingStyleAtPosition did not avoid tab span to obtain the computed style unlike styleAtPosition.
993
994         r46914 also introduced a regression by cloning hierarchy under new block at the insertion position without
995         avoiding the tab span.
996
997         Fixed the both regressions by avoiding tab spans when computing the editing style and when cloning hierarchy.
998
999         Test: editing/inserting/insert-paragraph-separator-tab-span.html
1000
1001         * editing/EditingStyle.cpp:
1002         (WebCore::EditingStyle::init): Always avoid a tab span when computing the editing style.
1003         * editing/InsertParagraphSeparatorCommand.cpp:
1004         (WebCore::InsertParagraphSeparatorCommand::doApply): Avoid cloning tab spans and inserting a paragraph
1005         separator into a paragraph separator.
1006
1007 2011-04-06  Levi Weintraub  <leviw@chromium.org>
1008
1009         Reviewed by Ryosuke Niwa.
1010
1011         Add member functions for determining line/paragraph separation to InlineIterator
1012         https://bugs.webkit.org/show_bug.cgi?id=57938
1013
1014         Adding atTextParagraphSeparator and atParagraphSeparator inline convenience functions to
1015         InlineIterator, where it makes far more sense for them to be. Also moving
1016         shouldPreserveNewline to RenderObject and renaming it preservesNewline.
1017
1018         No new tests as this provides no new functionality.
1019
1020         * rendering/InlineIterator.h:
1021         (WebCore::InlineIterator::atTextParagraphSeparator):
1022         (WebCore::InlineIterator::atParagraphSeparator):
1023         * rendering/RenderBlockLineLayout.cpp:
1024         (WebCore::RenderBlock::requiresLineBox):
1025         (WebCore::RenderBlock::findNextLineBreak):
1026         * rendering/RenderObject.h:
1027         (WebCore::RenderObject::preservesNewline):
1028
1029 2011-04-05  Alexander Pavlov  <apavlov@chromium.org>
1030
1031         Reviewed by Pavel Feldman.
1032
1033         Web Inspector: Range insertNode function does not update content in the inspector
1034         https://bugs.webkit.org/show_bug.cgi?id=57829
1035
1036         * inspector/InspectorDOMAgent.cpp:
1037         (WebCore::InspectorDOMAgent::pushChildNodesToFrontend):
1038         (WebCore::InspectorDOMAgent::buildArrayForContainerChildren):
1039
1040 2011-04-06  Alejandro G. Castro  <alex@igalia.com>
1041
1042         Fix GTK3 compilation after r82962.
1043
1044         * platform/gtk/RenderThemeGtk3.cpp:
1045         (WebCore::paintToggle):
1046         (WebCore::renderButton):
1047         (WebCore::RenderThemeGtk::paintMenuList):
1048         (WebCore::RenderThemeGtk::paintTextField):
1049         (WebCore::RenderThemeGtk::paintSliderTrack):
1050         (WebCore::RenderThemeGtk::paintSliderThumb):
1051         (WebCore::RenderThemeGtk::paintProgressBar):
1052         (WebCore::paintSpinArrowButton):
1053         * platform/gtk/ScrollbarThemeGtk3.cpp:
1054         (WebCore::ScrollbarThemeGtk::paintTrackBackground):
1055         (WebCore::ScrollbarThemeGtk::paintScrollbarBackground):
1056         (WebCore::ScrollbarThemeGtk::paintThumb):
1057         (WebCore::ScrollbarThemeGtk::paintButton):
1058
1059 2011-04-06  Andrey Kosyakov  <caseq@chromium.org>
1060
1061         Reviewed by Yury Semikhatsky.
1062
1063         Web Inspector: [Extensions API] remove inspectedPage.* events
1064         https://bugs.webkit.org/show_bug.cgi?id=57763
1065
1066         - Removed webInspector.inspectedPage.* events
1067         - moved onNavigated to webInspector.resources
1068
1069         * inspector/front-end/ExtensionAPI.js:
1070         (WebInspector.injectedExtensionAPI):
1071         (WebInspector.injectedExtensionAPI.InspectedWindow):
1072         * inspector/front-end/ExtensionAPISchema.json:
1073         * inspector/front-end/ExtensionServer.js:
1074         (WebInspector.ExtensionServer.prototype.notifyInspectedURLChanged):
1075         * inspector/front-end/inspector.js:
1076         (WebInspector.domContentEventFired):
1077         (WebInspector.loadEventFired):
1078         (WebInspector.inspectedURLChanged):
1079
1080 2011-04-06  Joseph Pecoraro  <joepeck@webkit.org>
1081
1082         Reviewed by Antti Koivisto.
1083
1084         Add <head> to the simpleUserAgentStyleSheet
1085         https://bugs.webkit.org/show_bug.cgi?id=57915
1086
1087         * css/CSSStyleSelector.cpp:
1088         (WebCore::elementCanUseSimpleDefaultStyle): add head to the
1089         simple stylesheet, display:none.
1090
1091 2011-04-05  Mikhail Naganov  <mnaganov@chromium.org>
1092
1093         Reviewed by Pavel Feldman.
1094
1095         Web Inspector: [Chromium] Add layout test for Summary view of detailed heap snapshots.
1096         https://bugs.webkit.org/show_bug.cgi?id=57856
1097
1098         Test: inspector/profiler/detailed-heapshots-summary.html
1099
1100         * inspector/front-end/DataGrid.js:
1101         (WebInspector.DataGrid):
1102         * inspector/front-end/DetailedHeapshotGridNodes.js:
1103         (WebInspector.HeapSnapshotGridNode.prototype._populate.doPopulate):
1104         (WebInspector.HeapSnapshotGridNode.prototype._populate):
1105         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren):
1106         (WebInspector.HeapSnapshotGridNode.prototype.sort.doSort):
1107         (WebInspector.HeapSnapshotGridNode.prototype.sort):
1108         (WebInspector.HeapSnapshotDiffNode.prototype.populateChildren):
1109         * inspector/front-end/DetailedHeapshotView.js:
1110         (WebInspector.HeapSnapshotSortableDataGrid.prototype.sortingChanged):
1111         * inspector/front-end/ProfilesPanel.js:
1112         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot.doParse):
1113         (WebInspector.ProfilesPanel.prototype._finishHeapSnapshot):
1114
1115 2011-04-06  Anders Bakken  <agbakken@gmail.com>
1116
1117         Reviewed by David Levin.
1118
1119         [Qt] SmartReplaceQt.cpp has coding-style errors
1120         https://bugs.webkit.org/show_bug.cgi?id=40261
1121
1122         This patch does not require new test cases.
1123
1124         * editing/qt/SmartReplaceQt.cpp:
1125         (WebCore::isCharacterSmartReplaceExempt):
1126
1127 2011-04-06  Naoki Takano  <takano.naoki@gmail.com>
1128
1129         Reviewed by Ryosuke Niwa.
1130
1131         REGRESSION(r81328): Null pointer crash in canAppendNewLineFeed when selection isn't inside an editable element
1132         https://bugs.webkit.org/show_bug.cgi?id=57755
1133
1134         Test: editing/execCommand/insert-line-break-onload.html
1135
1136         * editing/TypingCommand.cpp:
1137         (WebCore::canAppendNewLineFeed): Added null pointer check for rootEditableElement().
1138
1139 2011-04-05  Antti Koivisto  <antti@apple.com>
1140
1141         Reviewed by Cameron Zwarich.
1142
1143         Avoid calling currentTime() from FrameView::adjustedDeferredRepaintDelay() when repaints are deferred
1144         https://bugs.webkit.org/show_bug.cgi?id=57914
1145
1146         Don't call adjustedDeferredRepaintDelay unnecessarily.
1147
1148         * page/FrameView.cpp:
1149         (WebCore::FrameView::repaintContentRectangle):
1150         (WebCore::FrameView::adjustedDeferredRepaintDelay):
1151
1152 2011-04-05  Steve VanDeBogart  <vandebo@chromium.org>
1153
1154         Reviewed by David Levin.
1155
1156         Update call to SkAdvancedTypefaceMetrics to new API.
1157         https://bugs.webkit.org/show_bug.cgi?id=57887
1158
1159         * platform/graphics/chromium/FontPlatformDataLinux.cpp:
1160         (WebCore::FontPlatformData::emSizeInFontUnits):
1161
1162 2011-04-05  Alexey Proskuryakov  <ap@apple.com>
1163
1164         Reviewed by Darin Adler.
1165
1166         Rename event dispatching functions after form event removal
1167         https://bugs.webkit.org/show_bug.cgi?id=57908
1168
1169         * dom/InputElement.cpp:
1170         (WebCore::InputElement::setValueFromRenderer):
1171         * dom/Node.cpp:
1172         (WebCore::Node::dispatchChangeEvent):
1173         (WebCore::Node::dispatchInputEvent):
1174         (WebCore::Node::defaultEventHandler):
1175         * dom/Node.h:
1176         * html/HTMLFormControlElement.cpp:
1177         (WebCore::HTMLFormControlElement::dispatchFormControlChangeEvent):
1178         (WebCore::HTMLFormControlElement::dispatchFormControlInputEvent):
1179         (WebCore::HTMLTextFormControlElement::dispatchFormControlChangeEvent):
1180         Renamed "events" to "event", since there is only one event to dispatch now.
1181
1182 2011-04-05  Anders Bakken  <agbakken@gmail.com>
1183
1184         Reviewed by David Levin.
1185
1186         [Qt] DragControllerQt.cpp has coding-style errors
1187         https://bugs.webkit.org/show_bug.cgi?id=40258
1188
1189         This patch does not require new test cases.
1190
1191         * page/qt/DragControllerQt.cpp:
1192         (WebCore::DragController::dragOperation):
1193
1194 2011-04-05  Steve VanDeBogart  <vandebo@chromium.org>
1195
1196         Reviewed by David Levin.
1197
1198         Update deprecated include: platform_canvas_win.h to platform_canvas.h.
1199         https://bugs.webkit.org/show_bug.cgi?id=57896
1200
1201         * platform/graphics/chromium/FontChromiumWin.cpp:
1202
1203 2011-04-05  Darin Adler  <darin@apple.com>
1204
1205         Try to fix Leopard bots.
1206
1207         * platform/mac/HTMLConverter.mm: Fix #if back the way Alexey seems
1208         to have intended it.
1209
1210 2011-04-05  Darin Adler  <darin@apple.com>
1211
1212         Try to fix Leopard bots.
1213
1214         * platform/mac/HTMLConverter.mm: Move declarations of new functions
1215         inside the appropriate #if.
1216
1217 2011-04-05  Adrienne Walker  <enne@google.com>
1218
1219         Reviewed by Tony Chang.
1220
1221         Correctly set color when using skia's fillRoundedRect.
1222         https://bugs.webkit.org/show_bug.cgi?id=57907
1223
1224         * platform/graphics/skia/GraphicsContextSkia.cpp:
1225         (WebCore::GraphicsContext::fillRoundedRect):
1226
1227 2011-04-05  Alexey Proskuryakov  <ap@apple.com>
1228
1229         Reviewed by Darin Adler.
1230
1231         Move attributedStringFromRange down to WebCore
1232         https://bugs.webkit.org/show_bug.cgi?id=57905
1233
1234         No change in behavior, so no new tests.
1235
1236         Also tweaked HTMLConverter to not use methods defined in WebKit.
1237
1238         * WebCore.exp.in:
1239         * WebCore.xcodeproj/project.pbxproj:
1240         * platform/mac/HTMLConverter.h:
1241         * platform/mac/HTMLConverter.mm:
1242         (-[WebHTMLConverter _newTabForElement:]):
1243         (-[WebHTMLConverter _addAttachmentForElement:URL:needsParagraph:usePlaceholder:]):
1244         (+[WebHTMLConverter editingAttributedStringFromRange:]):
1245         (fileWrapperForURL):
1246         (fileWrapperForElement):
1247         * platform/mac/PasteboardMac.mm:
1248         (WebCore::Pasteboard::writeSelection):
1249         * platform/mac/WebNSAttributedStringExtras.h: Copied from Source/WebKit/mac/Misc/WebNSAttributedStringExtras.h.
1250         * platform/mac/WebNSAttributedStringExtras.mm: Copied from Source/WebKit/mac/Misc/WebNSAttributedStringExtras.mm.
1251         (WebCore::attributedStringByStrippingAttachmentCharacters):
1252
1253 2011-04-05  Simon Fraser  <simon.fraser@apple.com>
1254
1255         Reviewed by Darin Adler.
1256
1257         Rename variables in border drawing code for readability
1258         https://bugs.webkit.org/show_bug.cgi?id=57894
1259
1260         * rendering/RenderObject.cpp:
1261         (WebCore::RenderObject::drawLineForBoxSide):
1262         (WebCore::RenderObject::drawBoxSideFromPath):
1263         (WebCore::RenderObject::drawArcForBoxSide):
1264
1265 2011-04-05  Antti Koivisto  <antti@apple.com>
1266
1267         Reviewed by Darin Adler.
1268
1269         Defer repaints during style recalc
1270         https://bugs.webkit.org/show_bug.cgi?id=57886
1271
1272         This reduces the need to do (often expensive) platform surface invalidation.
1273         We already do this during layout but style recalculation may trigger
1274         invalidation as well.
1275     
1276         * dom/Document.cpp:
1277         (WebCore::Document::recalcStyle):
1278
1279 2011-04-05  Jer Noble  <jer.noble@apple.com>
1280
1281         Reviewed by Darin Adler.
1282
1283         HTML5 Player Has no Fullscreen Mode
1284         https://bugs.webkit.org/show_bug.cgi?id=57795
1285
1286         * html/HTMLVideoElement.cpp:
1287         (WebCore::HTMLVideoElement::supportsFullscreen): Call the new ChromeClient API
1288             supportsFullScreenForElement() before the old supportsFullScreenForNode() API.
1289
1290 2011-04-05  Vsevolod Vlasov  <vsevik@chromium.org>
1291
1292         Reviewed by Pavel Feldman.
1293
1294         Web Inspector: fix data url's status and timing the network panel.
1295         https://bugs.webkit.org/show_bug.cgi?id=53066
1296
1297         Added data url support for status of network resources.
1298
1299         * English.lproj/localizedStrings.js:
1300         * inspector/front-end/NetworkPanel.js:
1301         (WebInspector.NetworkDataGridNode.prototype._refreshStatusCell):
1302         * inspector/front-end/Resource.js:
1303         (WebInspector.Resource.prototype.isDataURL):
1304
1305 2011-04-04  Vitaly Repeshko  <vitalyr@chromium.org>
1306
1307         Reviewed by Adam Barth.
1308
1309         [V8] Keep dirty primitive CSS values alive.
1310         https://bugs.webkit.org/show_bug.cgi?id=57810
1311
1312         * bindings/v8/V8GCController.cpp:
1313         (WebCore::GrouperVisitor::visitDOMWrapper):
1314
1315 2011-04-05  Simon Fraser  <simon.fraser@apple.com>
1316
1317         Reviewed by Adele Peterson.
1318
1319         Add a fast path for simple color backgrounds
1320         https://bugs.webkit.org/show_bug.cgi?id=57773
1321
1322         Add a fast path for drawing simple color backgrounds. It's
1323         faster to fill a path or rect than it is to set up a clip,
1324         and then paint the rect.
1325         
1326         No visible behavior change so no new tests.
1327
1328         * rendering/RenderBoxModelObject.cpp:
1329         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
1330
1331 2011-04-05  Patrick Gansterer  <paroga@webkit.org>
1332
1333         Unreviewed EFL build fix for r82962.
1334
1335         * CMakeListsEfl.txt:
1336
1337 2011-04-05  Chris Rogers  <crogers@google.com>
1338
1339         Reviewed by Kenneth Russell.
1340
1341         Add support for offline audio rendering to AudioContext API
1342         https://bugs.webkit.org/show_bug.cgi?id=57676
1343
1344         No new tests since audio API is not yet implemented.
1345
1346         * DerivedSources.make:
1347         * WebCore.gypi:
1348         * WebCore.xcodeproj/project.pbxproj:
1349         * bindings/js/JSAudioContextCustom.cpp:
1350         (WebCore::JSAudioContextConstructor::constructJSAudioContext):
1351         * bindings/js/JSEventCustom.cpp:
1352         (WebCore::toJS):
1353         * bindings/js/JSEventTarget.cpp:
1354         (WebCore::toJS):
1355         * bindings/v8/V8DOMWrapper.cpp:
1356         (WebCore::V8DOMWrapper::convertEventTargetToV8Object):
1357         * bindings/v8/custom/V8AudioContextCustom.cpp:
1358         (WebCore::V8AudioContext::constructorCallback):
1359         * bindings/v8/custom/V8EventCustom.cpp:
1360         (WebCore::toV8):
1361         * dom/Event.cpp:
1362         (WebCore::Event::isOfflineAudioCompletionEvent):
1363         * dom/Event.h:
1364         * dom/EventTarget.cpp:
1365         (WebCore::EventTarget::toAudioContext):
1366         * dom/EventTarget.h:
1367         * platform/audio/HRTFDatabaseLoader.cpp:
1368         (WebCore::HRTFDatabaseLoader::waitForLoaderThreadCompletion):
1369         * platform/audio/HRTFDatabaseLoader.h:
1370         (WebCore::HRTFDatabaseLoader::loader):
1371         * webaudio/AudioContext.cpp:
1372         (WebCore::AudioContext::createOfflineContext):
1373         (WebCore::AudioContext::AudioContext):
1374         (WebCore::AudioContext::constructCommon):
1375         (WebCore::AudioContext::document):
1376         (WebCore::AudioContext::scriptExecutionContext):
1377         (WebCore::AudioContext::toAudioContext):
1378         (WebCore::AudioContext::startRendering):
1379         (WebCore::AudioContext::fireCompletionEvent):
1380         * webaudio/AudioContext.h:
1381         (WebCore::AudioContext::isOfflineContext):
1382         (WebCore::AudioContext::eventTargetData):
1383         (WebCore::AudioContext::ensureEventTargetData):
1384         (WebCore::AudioContext::refEventTarget):
1385         (WebCore::AudioContext::derefEventTarget):
1386         * webaudio/AudioContext.idl:
1387         * webaudio/AudioDestinationNode.cpp:
1388         (WebCore::AudioDestinationNode::AudioDestinationNode):
1389         * webaudio/AudioDestinationNode.h:
1390         (WebCore::AudioDestinationNode::reset):
1391         (WebCore::AudioDestinationNode::numberOfChannels):
1392         * webaudio/ConvolverNode.cpp:
1393         (WebCore::ConvolverNode::setBuffer):
1394         * webaudio/DefaultAudioDestinationNode.cpp: Added.
1395         (WebCore::DefaultAudioDestinationNode::DefaultAudioDestinationNode):
1396         (WebCore::DefaultAudioDestinationNode::~DefaultAudioDestinationNode):
1397         (WebCore::DefaultAudioDestinationNode::initialize):
1398         (WebCore::DefaultAudioDestinationNode::uninitialize):
1399         (WebCore::DefaultAudioDestinationNode::startRendering):
1400         * webaudio/DefaultAudioDestinationNode.h: Added.
1401         (WebCore::DefaultAudioDestinationNode::create):
1402         (WebCore::DefaultAudioDestinationNode::sampleRate):
1403         * webaudio/OfflineAudioCompletionEvent.cpp: Added.
1404         (WebCore::OfflineAudioCompletionEvent::create):
1405         (WebCore::OfflineAudioCompletionEvent::OfflineAudioCompletionEvent):
1406         (WebCore::OfflineAudioCompletionEvent::~OfflineAudioCompletionEvent):
1407         (WebCore::OfflineAudioCompletionEvent::isOfflineAudioCompletionEvent):
1408         * webaudio/OfflineAudioCompletionEvent.h: Added.
1409         (WebCore::OfflineAudioCompletionEvent::renderedBuffer):
1410         * webaudio/OfflineAudioCompletionEvent.idl: Added.
1411         * webaudio/OfflineAudioDestinationNode.cpp: Added.
1412         (WebCore::OfflineAudioDestinationNode::OfflineAudioDestinationNode):
1413         (WebCore::OfflineAudioDestinationNode::~OfflineAudioDestinationNode):
1414         (WebCore::OfflineAudioDestinationNode::initialize):
1415         (WebCore::OfflineAudioDestinationNode::uninitialize):
1416         (WebCore::OfflineAudioDestinationNode::startRendering):
1417         (WebCore::OfflineAudioDestinationNode::renderEntry):
1418         (WebCore::OfflineAudioDestinationNode::render):
1419         (WebCore::OfflineAudioDestinationNode::notifyCompleteDispatch):
1420         (WebCore::OfflineAudioDestinationNode::notifyComplete):
1421         * webaudio/OfflineAudioDestinationNode.h: Added.
1422         (WebCore::OfflineAudioDestinationNode::create):
1423         (WebCore::OfflineAudioDestinationNode::sampleRate):
1424
1425 2011-04-05  Martin Robinson  <mrobinson@igalia.com>
1426
1427         Reviewed by Eric Seidel.
1428
1429         [Cairo] Better separate the concerns of GraphicsContextCairo
1430         https://bugs.webkit.org/show_bug.cgi?id=55150
1431
1432         Add a PlatformContextCairo which right now stores the cairo_t* for a
1433         GraphicsContextCairo. Later patches will move logic for tracking ContextShadow
1434         and image masking layers into this PlatformContextCairo class.
1435
1436         No new tests. This patch is only a code cleanup.
1437
1438         * GNUmakefile.am:
1439         * platform/graphics/GraphicsContext.h: The platform context is no longer a
1440         cairo_t, but our new class the PlatformContextCairo.
1441         * platform/graphics/cairo/ContextShadowCairo.cpp: Updated to reflect new class.j
1442         * platform/graphics/cairo/FontCairo.cpp: Ditto.
1443         * platform/graphics/cairo/GradientCairo.cpp: Ditto.
1444         * platform/graphics/cairo/GraphicsContextCairo.cpp: Mostly mechanical
1445         changes which now reference platformContext()->cr() to get the cairo_t.
1446         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h: Now hold the
1447         PlatformContextCairo instead of the cairo_t.
1448         * platform/graphics/cairo/ImageBufferCairo.cpp: Update to reflect new class.
1449         * platform/graphics/cairo/ImageCairo.cpp: Ditto.
1450         * platform/graphics/cairo/PathCairo.cpp: Ditto.
1451         * platform/graphics/cairo/PlatformContextCairo.cpp: Added.
1452         * platform/graphics/cairo/PlatformContextCairo.h: Added.
1453         * platform/graphics/gtk/FontGtk.cpp: Update to reflect new class.
1454         * platform/graphics/gtk/IconGtk.cpp: Ditto.
1455         * platform/graphics/win/GraphicsContextCairoWin.cpp: Now fill out
1456         m_data with a private section containing the platform context instead of
1457         just a cairo_t.
1458         * platform/gtk/RenderThemeGtk.cpp: Update to reflect new class.
1459         * platform/gtk/WidgetRenderingContext.cpp: Ditto.
1460         (WebCore::WidgetRenderingContext::~WidgetRenderingContext): Ditto.
1461         * plugins/gtk/PluginViewGtk.cpp: Ditto.
1462
1463 2011-04-05  David Dorwin  <ddorwin@chromium.org>
1464
1465         Reviewed by David Levin.
1466
1467         Fullscreen code assumes all layers use GPU compositing when USE(ACCELERATED_COMPOSITING)
1468         https://bugs.webkit.org/show_bug.cgi?id=57400
1469
1470         Check whether the full screen renderer layer is being composited by the GPU before assuming that the backing is valid. 
1471         Accelerated compositing may be compiled in but disabled at runtime or for some elements.
1472
1473         Tests: Fullscreen layout tests on Chromium.
1474
1475         * dom/Document.cpp:
1476         (WebCore::Document::webkitWillEnterFullScreenForElement):
1477         (WebCore::Document::webkitDidEnterFullScreenForElement):
1478         (WebCore::Document::webkitWillExitFullScreenForElement):
1479
1480 2011-04-05  Nikolas Zimmermann  <nzimmermann@rim.com>
1481
1482         Reviewed by Dirk Schulze.
1483
1484         Regression: Invalid write in SVGTextLayoutEngine
1485         https://bugs.webkit.org/show_bug.cgi?id=57721
1486
1487         Properly stop layout if all metrics object refer to zero-width/height characters,
1488         which can happen for instance when using <text font-size="0">.
1489
1490         Test: svg/text/font-size-null-assertion.svg
1491
1492         * rendering/svg/SVGTextLayoutEngine.cpp:
1493         (WebCore::SVGTextLayoutEngine::currentLogicalCharacterAttributes):
1494         (WebCore::SVGTextLayoutEngine::currentLogicalCharacterMetrics):
1495
1496 2011-04-04 MORITA Hajime  <morrita@google.com>
1497
1498         Reviewed by Ryosuke Niwa.
1499
1500         [Refactoring] SpellCheckingResult should be replaced with TextCheckingResult
1501         https://bugs.webkit.org/show_bug.cgi?id=56085
1502         
1503         Removed WebCore::SpellCheckingResult and replaced it with TextCheckingResult.
1504         This change also added TextCheckerClient::requestCheckingOfString() should have
1505         TextCheckingTypeMask as a parameter to control text checking type.
1506
1507         * WebCore.exp.in:
1508         * editing/Editor.cpp:
1509         (WebCore::Editor::replaceSelectionWithFragment):
1510         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges):
1511         (WebCore::Editor::textCheckingTypeMaskFor): Extracted from markAllMisspellingsAndBadGrammarInRanges()
1512         * editing/SpellChecker.cpp:
1513         (WebCore::SpellChecker::requestCheckingFor): Added a parameter.
1514         (WebCore::SpellChecker::markAt): Extracted from didCheck(), Added a check for the GrammarDetail object.
1515         (WebCore::SpellChecker::didCheck):
1516         * editing/SpellChecker.h:
1517         * loader/EmptyClients.h:
1518         (WebCore::EmptyTextCheckerClient::checkTextOfParagraph):
1519         (WebCore::EmptyTextCheckerClient::requestCheckingOfString):
1520         * platform/text/TextCheckerClient.h:
1521
1522 2011-04-04  Antti Koivisto  <antti@apple.com>
1523
1524         Reviewed by Sam Weinig.
1525
1526         Print stylesheet on nytimes.com loads too early
1527         https://bugs.webkit.org/show_bug.cgi?id=57814
1528
1529         Don't load resources with Very Low priority until there are no other resources to 
1530         load for the host (or until document is complete enough that we stop limiting requests).
1531
1532         No tests, this is  difficult to observe reliably with our current testing infrastructure.
1533         Verified working with Wireshark.
1534
1535         * loader/ResourceLoadScheduler.cpp:
1536         (WebCore::ResourceLoadScheduler::servePendingRequests):
1537         (WebCore::ResourceLoadScheduler::HostInformation::limitRequests):
1538         * loader/ResourceLoadScheduler.h:
1539
1540 2011-04-04  Steve Block  <steveblock@google.com>
1541
1542         Reviewed by Dimitri Glazkov.
1543
1544         JavaInstance should be a pure interface
1545         https://bugs.webkit.org/show_bug.cgi?id=55383
1546
1547         This patch fixes JavaInstance for V8 only.
1548
1549         It factors out a JavaInstance interface which does not use JNI
1550         types. This will allow the Java bridge to be used with objects
1551         that don't use JNI directly. The existing jobject-backed
1552         implementation is moved to a new JavaInstanceJobject class which
1553         implements the interface.
1554
1555         No new tests, refactoring only.
1556
1557         * Android.v8bindings.mk:
1558         * WebCore.gypi:
1559         * bridge/jni/JobjectWrapper.h:
1560         * bridge/jni/v8/JNIUtilityPrivate.cpp:
1561         (JSC::Bindings::jvalueToJavaValue):
1562         (JSC::Bindings::javaValueToJvalue):
1563         * bridge/jni/v8/JavaInstanceJobjectV8.cpp:
1564         (JavaInstanceJobject::JavaInstanceJobject):
1565         (JavaInstanceJobject::~JavaInstanceJobject):
1566         (JavaInstanceJobject::begin):
1567         (JavaInstanceJobject::end):
1568         (JavaInstanceJobject::getClass):
1569         (JavaInstanceJobject::invokeMethod):
1570         (JavaInstanceJobject::getField):
1571         * bridge/jni/v8/JavaInstanceJobjectV8.h: Copied from Source/WebCore/bridge/jni/v8/JavaInstanceV8.h.
1572         (JSC::Bindings::JavaInstanceJobject::javaInstance):
1573         * bridge/jni/v8/JavaInstanceV8.h:
1574         (JSC::Bindings::JavaInstance::~JavaInstance):
1575
1576 2011-04-05  Dimitri Glazkov  <dglazkov@chromium.org>
1577
1578        Reviewed by Darin Adler.
1579
1580         Move MouseEvent-dispatching logic into MouseEventDispatchMediator.
1581         https://bugs.webkit.org/show_bug.cgi?id=57639
1582
1583         Refactoring, covered by existing tests.
1584
1585         * dom/EventDispatcher.cpp:
1586         (WebCore::EventDispatcher::dispatchEvent): Moved useful assertion here
1587             from dispatchMouseEvent.
1588         (WebCore::EventDispatcher::adjustRelatedTarget): Converted into a method.
1589         * dom/EventDispatcher.h: Adjusted decls.
1590         (WebCore::EventDispatcher::node): Added.
1591         * dom/MouseEvent.cpp:
1592         (WebCore::MouseEvent::create): Moved useful assertion here from
1593             dispatchMouseEvent.
1594         (WebCore::MouseEventDispatchMediator::MouseEventDispatchMediator): Added.
1595         (WebCore::MouseEventDispatchMediator::event): Added.
1596         (WebCore::MouseEventDispatchMediator::dispatchEvent): Added.
1597         * dom/MouseEvent.h:
1598         (WebCore::MouseEvent::setRelatedTarget): Added.
1599         * dom/Node.cpp:
1600         (WebCore::Node::dispatchMouseEvent): Changed to use MouseEventDispatchMediator.
1601
1602 2011-04-05  Nikolas Zimmermann  <nzimmermann@rim.com>
1603
1604         Reviewed by Adam Roben & Dirk Schulze.
1605
1606         text-tspan-02-b.svg from SVG 1.1 2nd edition fails
1607         https://bugs.webkit.org/show_bug.cgi?id=57831
1608
1609         We were not spanning rotation values correcty accross text children, which resulted in text-span-02-b.svg misrendering.
1610         While rewriting the rotation specific code, it came apparent that the LayoutScope concept is flawed in general and
1611         should be replaced by a global list of x/y/dx/dy/rotate values for the whole text subtree. This makes it much simpler
1612         to implement the demand that the last rotation value spans the whole scope. A follow-up patch will optimize the
1613         required memory.
1614
1615         Example:
1616         <text rotate="10,20,999,50">AB<tspan rotate="30">CDE</>FGH</text>
1617     
1618         text:   A  B  C  D  E  F  G  H
1619         rotate="10 20 30 30 30 50 50 50"
1620
1621         Tests: svg/W3C-SVG-1.1-SE/text-tspan-02-b.svg
1622                svg/text/text-midpoint-split-bug.svg
1623
1624         * rendering/RenderBlockLineLayout.cpp:     Move SVG specific midpoint creation after the non-SVG specific code that may mutate the midpoints. otherwhise we end up in an
1625         (WebCore::RenderBlock::findNextLineBreak): inconsistent state. We were intereferring with the ignoreSpaces code resulting in wrong truncations - covered by new testcase.
1626         * rendering/svg/SVGTextLayoutAttributes.cpp:
1627         (WebCore::SVGTextLayoutAttributes::reserveCapacity): Also reserveCapacity for the text metrics list (minor optimization).
1628         (WebCore::SVGTextLayoutAttributes::fillWithEmptyValue): Added helper function for use from SVGTextLayoutAttributesBuilder.
1629         (WebCore::SVGTextLayoutAttributes::appendEmptyValue): Ditto.
1630         (WebCore::safeValueAtPosition): Ditto. (Inline helper)
1631         (WebCore::SVGTextLayoutAttributes::appendSingleValueFromAttribute): Ditto.
1632         * rendering/svg/SVGTextLayoutAttributes.h: Ditto.
1633         * rendering/svg/SVGTextLayoutAttributesBuilder.cpp: Rewrite code, see explaination above.
1634         (WebCore::SVGTextLayoutAttributesBuilder::buildLayoutAttributesForTextSubtree):
1635         (WebCore::processRenderSVGInlineText):
1636         (WebCore::SVGTextLayoutAttributesBuilder::collectTextPositioningElements):
1637         (WebCore::SVGTextLayoutAttributesBuilder::buildLayoutAttributesForAllCharacters):
1638         (WebCore::SVGTextLayoutAttributesBuilder::propagateLayoutAttributes):
1639         (WebCore::fillListAtPosition):
1640         (WebCore::SVGTextLayoutAttributesBuilder::fillAttributesAtPosition):
1641         * rendering/svg/SVGTextLayoutAttributesBuilder.h:
1642         (WebCore::SVGTextLayoutAttributesBuilder::TextPosition::TextPosition):
1643
1644 2011-04-05  Levi Weintraub  <leviw@chromium.org>
1645
1646         Reviewed by Ryosuke Niwa.
1647
1648         DeleteButtonController is given invalid style
1649         https://bugs.webkit.org/show_bug.cgi?id=57853
1650
1651         DeleteButtonController was assigned an invalid style that can lead to assertions
1652         in debug builds. This matches up the code with its intent.
1653
1654         No new tests as this changes nothing on release builds.
1655
1656         * editing/DeleteButtonController.cpp:
1657         (WebCore::DeleteButtonController::createDeletionUI):
1658
1659 2011-04-05  Anders Bakken  <agbakken@gmail.com>
1660
1661         Reviewed by Laszlo Gombos.
1662
1663         [Qt] EditorQt.cpp has coding-style errors
1664         https://bugs.webkit.org/show_bug.cgi?id=40260
1665         
1666         This patch does not require new test cases.
1667
1668         * editing/qt/EditorQt.cpp:
1669
1670 2011-04-05  Pavel Podivilov  <podivilov@chromium.org>
1671
1672         Reviewed by Pavel Feldman.
1673
1674         Web Inspector: go to line dialog highlights wrong line.
1675         https://bugs.webkit.org/show_bug.cgi?id=57845
1676
1677         * inspector/front-end/GoToLineDialog.js:
1678         (WebInspector.GoToLineDialog.prototype._highlightSelectedLine):
1679
1680 2011-04-05  Luke Macpherson   <macpherson@chromium.org>
1681
1682         Reviewed by Dimitri Glazkov.
1683
1684         Implement CSSPropertyDirection in CSSStyleApplyProperty
1685         https://bugs.webkit.org/show_bug.cgi?id=57608
1686
1687         No new tests required as no new functionality introduced.
1688
1689         * css/CSSStyleApplyProperty.cpp:
1690         Add implementation class for CSSPropertyDirection
1691         * css/CSSStyleSelector.cpp:
1692         Remove existing implementation for CSSPropertyDirection
1693         * css/CSSStyleSelector.h:
1694         Add getter for element
1695
1696 2011-04-05  Leandro Gracia Gil  <leandrogracia@chromium.org>
1697
1698         Reviewed by Steve Block.
1699
1700         Factoring the creation of 'FunctionOnly' callbacks in V8.
1701         https://bugs.webkit.org/show_bug.cgi?id=57760
1702
1703         This method creates a template from an existing functionality in V8GeolocationCustom.cpp
1704         to V8Utilities to be used by the custom bindings of both Geolocation and the Media Stream API.
1705
1706         No new tests. LayoutTests/fast/dom/Geolocation/argument-types.html
1707
1708         * bindings/v8/V8Utilities.cpp:
1709         (WebCore::throwTypeMismatchException):
1710         * bindings/v8/V8Utilities.h:
1711         (WebCore::createFunctionOnlyCallback):
1712         * bindings/v8/custom/V8GeolocationCustom.cpp:
1713         (WebCore::V8Geolocation::getCurrentPositionCallback):
1714         (WebCore::V8Geolocation::watchPositionCallback):
1715
1716 2011-04-05  Nikolas Zimmermann  <nzimmermann@rim.com>
1717
1718         Reviewed by Andreas Kling.
1719
1720         Switch from Vector<UChar> to StringBuilder in bindings/
1721         https://bugs.webkit.org/show_bug.cgi?id=57838
1722
1723         * bindings/js/JSCSSStyleDeclarationCustom.cpp:
1724         (WebCore::cssPropertyName):
1725         * bindings/v8/custom/V8CSSStyleDeclarationCustom.cpp:
1726         (WebCore::cssPropertyInfo):
1727
1728 2011-04-05  Nikolas Zimmermann  <nzimmermann@rim.com>
1729
1730         Reviewed by Andreas Kling.
1731
1732         Switch from Vector<UChar> to StringBuilder in accessibility/
1733         https://bugs.webkit.org/show_bug.cgi?id=57837
1734
1735         * accessibility/AccessibilityObject.cpp:
1736         (WebCore::AccessibilityObject::listMarkerTextForNodeAndPosition):
1737         (WebCore::AccessibilityObject::stringForVisiblePositionRange):
1738         * accessibility/AccessibilityRenderObject.cpp:
1739         (WebCore::AccessibilityRenderObject::accessibilityDescriptionForElements):
1740
1741 2011-04-05  Andrey Adaikin  <aandrey@google.com>
1742
1743         Reviewed by Pavel Feldman.
1744
1745         Web Inspector: Scripts with syntax errors are cropped in the UI
1746         https://bugs.webkit.org/show_bug.cgi?id=57828
1747
1748         * inspector/front-end/SourceFrame.js:
1749         (WebInspector.SourceFrame.prototype.addMessageToSource):
1750
1751 2011-04-05  Alexey Proskuryakov  <ap@apple.com>
1752
1753         Reviewed by Darin Adler.
1754
1755         Remove onformchange and onforminput events/event handlers
1756         https://bugs.webkit.org/show_bug.cgi?id=55755
1757         <rdar://problem/9087969>
1758
1759         Covered by existing tests.
1760
1761         * dom/Document.h:
1762         * dom/Document.idl:
1763         * dom/Element.h:
1764         * dom/Element.idl:
1765         * dom/Event.cpp:
1766         (WebCore::Event::fromUserGesture):
1767         * dom/EventNames.h:
1768         * html/FormAssociatedElement.h:
1769         * html/HTMLAttributeNames.in:
1770         * html/HTMLElement.cpp:
1771         (WebCore::HTMLElement::parseMappedAttribute):
1772         * html/HTMLElement.h:
1773         * html/HTMLFormControlElement.h:
1774         (WebCore::HTMLFormControlElement::isEnumeratable):
1775         * html/HTMLFormElement.cpp:
1776         * html/HTMLFormElement.h:
1777         * html/HTMLFormElement.idl:
1778         * html/HTMLInputElement.h:
1779         * html/HTMLKeygenElement.h:
1780         * html/HTMLObjectElement.h:
1781         (WebCore::HTMLObjectElement::isEnumeratable):
1782         * html/HTMLOutputElement.h:
1783         (WebCore::HTMLOutputElement::isEnumeratable):
1784         * html/HTMLSelectElement.h:
1785         (WebCore::HTMLSelectElement::isEnumeratable):
1786         * html/HTMLTextAreaElement.h:
1787         (WebCore::HTMLTextAreaElement::isEnumeratable):
1788         * page/DOMWindow.h:
1789         * page/DOMWindow.idl:
1790
1791 2011-04-05  Sheriff Bot  <webkit.review.bot@gmail.com>
1792
1793         Unreviewed, rolling out r82915.
1794         http://trac.webkit.org/changeset/82915
1795         https://bugs.webkit.org/show_bug.cgi?id=57825
1796
1797         Broke 270 chromium tests on win and linux (Requested by
1798         podivilov on #webkit).
1799
1800         * rendering/RenderThemeChromiumSkia.cpp:
1801         (WebCore::RenderThemeChromiumSkia::defaultGUIFont):
1802
1803 2011-04-05  James Simonsen  <simonjam@chromium.org>
1804
1805         Reviewed by Adam Barth.
1806
1807         Stop preload scanning CSS when it&apos;s impossible to have another @import.
1808         https://bugs.webkit.org/show_bug.cgi?id=57664
1809
1810         @import statements are only allowed at the beginning of a CSS file.
1811         Only comments or @charset can precede them. After seeing anything else,
1812         abort early so that we:
1813         - don't have to parse the rest of the CSS.
1814         - don't preload something that the regular parser won't load.
1815
1816         * html/parser/CSSPreloadScanner.cpp:
1817         (WebCore::CSSPreloadScanner::scan): Terminate early if we're done with @imports.
1818         (WebCore::CSSPreloadScanner::tokenize): Terminate early if we see a {} or any style rule.
1819         (WebCore::CSSPreloadScanner::emitRule): Only @charset or @import are allowed to precede @import.
1820         * html/parser/CSSPreloadScanner.h: Add DoneParsingImportRules state.
1821
1822 2011-04-05  Takayoshi Kochi <kochi@chromium.org>
1823
1824         Reviewed by Tony Chang.
1825
1826         [chromium] Specify 'sans-serif' as a fallback to the default UI font
1827         'Arial' for non-latin UI scripts (e.g. CJK).
1828         https://bugs.webkit.org/show_bug.cgi?id=55035
1829
1830         No new tests, because it may still fail if the system is not configured
1831         properly to resolve 'sans-serif' to existing real font file, thus even
1832         manual test is hard to systematically tell it is working properly.
1833
1834         * rendering/RenderThemeChromiumSkia.cpp
1835
1836 2011-04-05  Kent Tamura  <tkent@chromium.org>
1837
1838         Reviewed by Dimitri Glazkov.
1839
1840         Setting defaultValue on a textarea with a modified value still clobbers the value
1841         https://bugs.webkit.org/show_bug.cgi?id=57636
1842
1843         If the dirty flag is true, we shouldn't update the value when the
1844         defaultValue is updated
1845
1846         Test: fast/forms/textarea-set-defaultvalue-after-value.html
1847
1848         * html/HTMLTextAreaElement.cpp:
1849         (WebCore::HTMLTextAreaElement::childrenChanged):
1850         (WebCore::HTMLTextAreaElement::setDefaultValue):
1851
1852 2011-04-04  Kent Tamura  <tkent@chromium.org>
1853
1854         Add a case label which was unexpectedly removed in r82899.
1855         https://bugs.webkit.org/show_bug.cgi?id=50661
1856
1857         * css/CSSSelector.cpp:
1858         (WebCore::CSSSelector::extractPseudoType):
1859
1860 2011-04-04  Dan Bernstein  <mitz@apple.com>
1861
1862         Reviewed by Simon Fraser.
1863
1864         <rdar://problem/7709452> Implement Default Ruby Overhang Behavior
1865         https://bugs.webkit.org/show_bug.cgi?id=49334
1866
1867         Tests: fast/ruby/overhang-horizontal.html
1868                fast/ruby/overhang-vertical.html
1869
1870         This is a first cut at ruby overhang. It allows ruby text to hang over other
1871         text of equal or smaller size. Two notable omissions are that max preferred
1872         width computation was not patched, so it will overshoot, and that overhang
1873         ignores the width of the adjoining text runs.
1874
1875         * rendering/RenderBlock.h:
1876         * rendering/RenderBlockLineLayout.cpp:
1877         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Adjust margins
1878         of ruby runs for overhang.
1879         (WebCore::RenderBlock::fitBelowFloats): Maintain the increase in line width to
1880         compensate for overhang.
1881         (WebCore::RenderBlock::findNextLineBreak): When encountering
1882         a ruby run, increase the line width to account for the fact that overhang will be
1883         collapsed.
1884         * rendering/RenderRubyRun.cpp:
1885         (WebCore::RenderRubyRun::getOverhang): Added. Allows ruby to overhang if
1886         the adjoining renderer is text with equal or smaller font size.
1887         * rendering/RenderRubyRun.h:
1888         (WebCore::toRenderRubyRun):
1889
1890 2011-04-04  David Kilzer  <ddkilzer@apple.com>
1891
1892         <http://webkit.org/b/57384> CFNetwork and WebCore load priorities should match
1893
1894         Reviewed by Alexey Proskuryakov.
1895
1896         * WebCore.exp.in: Export wkSetHTTPPipeliningMaximumPriority().
1897         * platform/mac/WebCoreSystemInterface.h:
1898         (wkSetHTTPPipeliningMaximumPriority): Added function pointer
1899         declaration.
1900         * platform/mac/WebCoreSystemInterface.mm:
1901         (wkSetHTTPPipeliningMaximumPriority): Added function pointer.
1902         * platform/network/cf/ResourceRequestCFNet.cpp:
1903         (WebCore::initializeMaximumHTTPConnectionCountPerHost): Call
1904         wkSetHTTPPipeliningMaximumPriority() to set the maximum HTTP
1905         pipelining priority.
1906         * platform/network/cf/ResourceRequestCFNet.h:
1907         (WebCore::toResourceLoadPriority): Renamed from
1908         mapHTTPPipeliningPriorityToResourceLoadPriority().  Updated to
1909         to handle Unresolved case.
1910         (WebCore::toHTTPPipeliningPriority): Renamed from
1911         mapResourceLoadPriorityToHTTPPipeliningPriority().  Updated to
1912         handle Unresolved case.
1913         * platform/network/mac/ResourceRequestMac.mm:
1914         (WebCore::ResourceRequest::doUpdateResourceRequest): Switched to
1915         use toResourceLoadPriority().
1916         (WebCore::ResourceRequest::doUpdatePlatformRequest): Switched to
1917         use toHTTPPipeliningPriority().  Moved
1918         shouldForceHTTPPipeliningPriorityHigh() check into the argument
1919         of toHTTPPipeliningPriority() instead of hard-coding a
1920         now-incorrect value.
1921
1922 2011-04-04  MORITA Hajime  <morrita@google.com>
1923
1924         Reviewed by Kent Tamura.
1925
1926         Convert <meter> shadow DOM to a DOM-based shadow.
1927         https://bugs.webkit.org/show_bug.cgi?id=50661
1928         
1929         Eliminated a large part of <meter> custom layout code,
1930         which is replaced by a shadow tree.
1931         Note that the shadow tree is created on construction time and
1932         will remain during the host HTMLMeterElement lifecycle.
1933         
1934         * Android.mk:
1935         * CMakeLists.txt:
1936         * GNUmakefile.am:
1937         * WebCore.gypi:
1938         * WebCore.pro:
1939         * WebCore.vcproj/WebCore.vcproj:
1940         * WebCore.xcodeproj/project.pbxproj:
1941         * css/CSSMutableStyleDeclaration.cpp:
1942         (WebCore::CSSMutableStyleDeclaration::setProperty):
1943         * css/CSSMutableStyleDeclaration.h:
1944         * css/CSSSelector.cpp:
1945         (WebCore::CSSSelector::pseudoId):
1946         (WebCore::nameToPseudoTypeMap):
1947         (WebCore::CSSSelector::extractPseudoType):
1948         * css/CSSSelector.h:
1949         * css/html.css:
1950         (meter):
1951         (meter::-webkit-meter-bar):
1952         (meter::-webkit-meter-optimum-value):
1953         (meter::-webkit-meter-suboptimum-value):
1954         (meter::-webkit-meter-even-less-good-value):
1955         * html/HTMLMeterElement.cpp:
1956         (WebCore::HTMLMeterElement::~HTMLMeterElement):
1957         (WebCore::HTMLMeterElement::parseMappedAttribute):
1958         (WebCore::HTMLMeterElement::attach):
1959         (WebCore::HTMLMeterElement::valueRatio):
1960         (WebCore::HTMLMeterElement::didElementStateChange):
1961         (WebCore::HTMLMeterElement::createShadowSubtree):
1962         * html/HTMLMeterElement.h:
1963         * html/shadow/MeterShadowElement.cpp: Added.
1964         (WebCore::MeterShadowElement::MeterShadowElement):        
1965         (WebCore::MeterShadowElement::meterElement):
1966         (WebCore::MeterShadowElement::rendererIsNeeded):
1967         (WebCore::MeterBarElement::shadowPseudoId):
1968         (WebCore::MeterValueElement::shadowPseudoId):
1969         (WebCore::MeterValueElement::setWidthPercentage):
1970         * html/shadow/MeterShadowElement.h: Added.
1971         (WebCore::MeterBarElement::MeterBarElement):
1972         (WebCore::MeterBarElement::create):
1973         (WebCore::MeterValueElement::MeterValueElement):
1974         (WebCore::MeterValueElement::create):
1975         * rendering/RenderMeter.cpp:
1976         (WebCore::RenderMeter::RenderMeter):
1977         (WebCore::RenderMeter::~RenderMeter):
1978         (WebCore::RenderMeter::valueRatio):
1979         * rendering/RenderMeter.h:
1980         (WebCore::RenderMeter::renderName):
1981         (WebCore::RenderMeter::isMeter):
1982         (WebCore::RenderMeter::requiresForcedStyleRecalcPropagation):
1983         (WebCore::RenderMeter::canHaveChildren):
1984
1985 2011-04-04  Dimitri Glazkov  <dglazkov@chromium.org>
1986
1987         Reviewed by Adam Barth.
1988
1989         Introduce EventDispatchMediator abstraction, which encapsulate all
1990         non-trivial logic around firing a specific type of an event.
1991         https://bugs.webkit.org/show_bug.cgi?id=57562
1992
1993         Refactoring, covered by existing tests.
1994
1995         * dom/Event.cpp:
1996         (WebCore::EventDispatchMediator::EventDispatchMediator): Added.
1997         (WebCore::EventDispatchMediator::~EventDispatchMediator): Added.
1998         (WebCore::EventDispatchMediator::dispatchEvent): Added.
1999         (WebCore::EventDispatchMediator::event): Added.
2000         * dom/Event.h: Added decl.
2001         * dom/EventDispatcher.cpp:
2002         (WebCore::EventDispatcher::dispatchEvent): Changed to use EventDispatchMediator.
2003         * dom/EventDispatcher.h: Updated decls.
2004         * dom/KeyboardEvent.cpp:
2005         (WebCore::KeyboardEventDispatchMediator::KeyboardEventDispatchMediator): Added.
2006         (WebCore::KeyboardEventDispatchMediator::dispatchEvent): Added.
2007         * dom/KeyboardEvent.h: Updated decls
2008         * dom/Node.cpp:
2009         (WebCore::Node::dispatchEvent): Changed to use EventDispatchMediator.
2010         (WebCore::Node::dispatchKeyEvent): Changed to use KeyboardEventDispatchMediator.
2011
2012 2011-04-04  Martin Robinson  <mrobinson@igalia.com>
2013
2014         Reviewed by Xan Lopez.
2015
2016         [Cairo] Memory leak in RefPtrCairo
2017         https://bugs.webkit.org/show_bug.cgi?id=57758
2018
2019         No new tests. This just fixes a memory leak.
2020
2021         * platform/graphics/cairo/RefPtrCairo.cpp:
2022         (WTF::derefIfNotNull): Deref should unref the cairo_font_fact_t, not reference it.
2023
2024 2011-04-04  Adrienne Walker  <enne@google.com>
2025
2026         Unreviewed, rolling out r82880.
2027         http://trac.webkit.org/changeset/82880
2028         https://bugs.webkit.org/show_bug.cgi?id=50661
2029
2030         Meter elements not rendered in Chromium Linux layout tests
2031
2032         * Android.mk:
2033         * CMakeLists.txt:
2034         * GNUmakefile.am:
2035         * WebCore.gypi:
2036         * WebCore.pro:
2037         * WebCore.vcproj/WebCore.vcproj:
2038         * WebCore.xcodeproj/project.pbxproj:
2039         * css/CSSMutableStyleDeclaration.cpp:
2040         * css/CSSMutableStyleDeclaration.h:
2041         * css/CSSSelector.cpp:
2042         (WebCore::CSSSelector::pseudoId):
2043         (WebCore::nameToPseudoTypeMap):
2044         (WebCore::CSSSelector::extractPseudoType):
2045         * css/CSSSelector.h:
2046         * css/html.css:
2047         (meter):
2048         (meter::-webkit-meter):
2049         (meter::-webkit-meter-bar):
2050         (meter::-webkit-meter-optimum-value):
2051         (meter::-webkit-meter-suboptimal-value):
2052         (meter::-webkit-meter-even-less-good-value):
2053         * html/HTMLMeterElement.cpp:
2054         (WebCore::HTMLMeterElement::create):
2055         (WebCore::HTMLMeterElement::parseMappedAttribute):
2056         (WebCore::HTMLMeterElement::attach):
2057         * html/HTMLMeterElement.h:
2058         * html/shadow/MeterShadowElement.cpp: Removed.
2059         * html/shadow/MeterShadowElement.h: Removed.
2060         * rendering/RenderMeter.cpp:
2061         (WebCore::RenderMeter::RenderMeter):
2062         (WebCore::RenderMeter::~RenderMeter):
2063         (WebCore::RenderMeter::createPart):
2064         (WebCore::RenderMeter::updateFromElement):
2065         (WebCore::RenderMeter::layoutParts):
2066         (WebCore::RenderMeter::styleDidChange):
2067         (WebCore::RenderMeter::shouldHaveParts):
2068         (WebCore::RenderMeter::valueRatio):
2069         (WebCore::RenderMeter::barPartRect):
2070         (WebCore::RenderMeter::valuePartRect):
2071         (WebCore::RenderMeter::valuePseudoId):
2072         (WebCore::RenderMeter::barPseudoId):
2073         (WebCore::RenderMeter::detachShadows):
2074         (WebCore::RenderMeter::updateShadows):
2075         * rendering/RenderMeter.h:
2076         (WebCore::RenderMeter::renderName):
2077         (WebCore::RenderMeter::isMeter):
2078         (WebCore::RenderMeter::shadowAttached):
2079
2080 2011-04-04  Chang Shu  <cshu@webkit.org>
2081
2082         Reviewed by Ryosuke Niwa.
2083
2084         setContentEditable with true/false/inherit string is not working properly
2085         https://bugs.webkit.org/show_bug.cgi?id=52058
2086
2087         Move isContentEditable from HTMLElement to Node. Thus, Node provides two functions for
2088         checking editability: rendererIsEditable and isContentEdiable. The former is a fast path,
2089         which does NOT trigger layout and only checks the render style of usermodify. The latter
2090         updates the layout first to make sure the render style syncs with DOM contenteditable 
2091         attribute. Certain call sites that need to call isContentEditable rather than rendererIsEditable
2092         are also updated in the patch. But a complete fix will follow up in bug 57244.
2093
2094         This patch fixes all the failed layout tests related to set contenteditable.
2095
2096         * accessibility/AccessibilityRenderObject.cpp:
2097         (WebCore::AccessibilityRenderObject::isReadOnly):
2098         * dom/Node.cpp:
2099         (WebCore::Node::isContentEditable):
2100         (WebCore::Node::shouldUseInputMethod):
2101         * dom/Node.h:
2102         * html/HTMLElement.cpp:
2103         * html/HTMLElement.h:
2104
2105 2011-04-04  Roland Steiner  <rolandsteiner@chromium.org>
2106
2107         Reviewed by Dimitri Glazkov.
2108
2109         Bug 57689 - Extract scoping functionality from Document
2110         https://bugs.webkit.org/show_bug.cgi?id=57689
2111
2112         Moved selfOnlyRef (renamed to guardRef), element ID, image map
2113         and accesss key functionalities from Document to a new base
2114         class TreeScope.
2115
2116         TreeShared: made removedLastRef protected
2117
2118         No new tests. (refactoring)
2119
2120         * Android.mk:
2121         * CMakeLists.txt:
2122         * GNUmakefile.am:
2123         * WebCore.gypi:
2124         * WebCore.pro:
2125         * WebCore.vcproj/WebCore.vcproj:
2126         * WebCore.xcodeproj/project.pbxproj:
2127         * dom/Document.cpp:
2128         (WebCore::Document::Document):
2129         (WebCore::Document::destroyScope):
2130         (WebCore::Document::getElementById):
2131         (WebCore::Document::childrenChanged):
2132         (WebCore::Document::scheduleStyleRecalc):
2133         (WebCore::Document::attach):
2134         (WebCore::Document::detach):
2135         * dom/Document.h:
2136         (WebCore::Node::Node):
2137         * dom/DocumentOrderedMap.cpp:
2138         (WebCore::DocumentOrderedMap::get):
2139         (WebCore::DocumentOrderedMap::getElementById):
2140         (WebCore::DocumentOrderedMap::getElementByMapName):
2141         (WebCore::DocumentOrderedMap::getElementByLowercasedMapName):
2142         * dom/DocumentOrderedMap.h:
2143         * dom/DOMAllInOne.cpp:
2144         * dom/Node.cpp:
2145         (WebCore::Node::~Node):
2146         (WebCore::Node::setDocument):
2147         * dom/Node.h:
2148         * dom/TreeScope.cpp: Added.
2149         * dom/TreeScope.h: Added.
2150         * platform/TreeShared.h:
2151         (WebCore::TreeShared::removedLastRef): made protected
2152
2153 2011-04-04  MORITA Hajime  <morrita@google.com>
2154
2155         Reviewed by Dimitri Glazkov.
2156
2157         Convert <meter> shadow DOM to a DOM-based shadow.
2158         https://bugs.webkit.org/show_bug.cgi?id=50661
2159         
2160         Eliminated a large part of <meter> custom layout code,
2161         which is replaced by a shadow tree.
2162         Note that the shadow tree is created on construction time and
2163         will remain during the host HTMLMeterElement lifecycle.
2164         
2165         * Android.mk:
2166         * CMakeLists.txt:
2167         * GNUmakefile.am:
2168         * WebCore.gypi:
2169         * WebCore.pro:
2170         * WebCore.vcproj/WebCore.vcproj:
2171         * WebCore.xcodeproj/project.pbxproj:
2172         * css/CSSMutableStyleDeclaration.cpp:
2173         (WebCore::CSSMutableStyleDeclaration::setProperty):
2174         * css/CSSMutableStyleDeclaration.h:
2175         * css/CSSSelector.cpp:
2176         (WebCore::CSSSelector::pseudoId):
2177         (WebCore::nameToPseudoTypeMap):
2178         (WebCore::CSSSelector::extractPseudoType):
2179         * css/CSSSelector.h:
2180         * css/html.css:
2181         (meter):
2182         (meter::-webkit-meter-bar):
2183         (meter::-webkit-meter-optimum-value):
2184         (meter::-webkit-meter-suboptimum-value):
2185         (meter::-webkit-meter-even-less-good-value):
2186         * html/HTMLMeterElement.cpp:
2187         (WebCore::HTMLMeterElement::~HTMLMeterElement):
2188         (WebCore::HTMLMeterElement::parseMappedAttribute):
2189         (WebCore::HTMLMeterElement::attach):
2190         (WebCore::HTMLMeterElement::valueRatio):
2191         (WebCore::HTMLMeterElement::didElementStateChange):
2192         (WebCore::HTMLMeterElement::createShadowSubtree):
2193         * html/HTMLMeterElement.h:
2194         * html/shadow/MeterShadowElement.cpp: Added.
2195         (WebCore::MeterShadowElement::MeterShadowElement):        
2196         (WebCore::MeterShadowElement::meterElement):
2197         (WebCore::MeterShadowElement::rendererIsNeeded):
2198         (WebCore::MeterBarElement::shadowPseudoId):
2199         (WebCore::MeterValueElement::shadowPseudoId):
2200         (WebCore::MeterValueElement::setWidthPercentage):
2201         * html/shadow/MeterShadowElement.h: Added.
2202         (WebCore::MeterBarElement::MeterBarElement):
2203         (WebCore::MeterBarElement::create):
2204         (WebCore::MeterValueElement::MeterValueElement):
2205         (WebCore::MeterValueElement::create):
2206         * rendering/RenderMeter.cpp:
2207         (WebCore::RenderMeter::RenderMeter):
2208         (WebCore::RenderMeter::~RenderMeter):
2209         (WebCore::RenderMeter::valueRatio):
2210         * rendering/RenderMeter.h:
2211         (WebCore::RenderMeter::renderName):
2212         (WebCore::RenderMeter::isMeter):
2213         (WebCore::RenderMeter::requiresForcedStyleRecalcPropagation):
2214         (WebCore::RenderMeter::canHaveChildren):
2215
2216 2011-04-04  Martin Robinson  <mrobinson@igalia.com>
2217
2218         Reviewed by Gustavo Noronha Silva.
2219
2220         [GTK] WebGL support
2221         https://bugs.webkit.org/show_bug.cgi?id=31517
2222
2223         Add WebGL support for the GTK+ bits of WebCore.
2224
2225         No new tests. This will be covered by the existing WebGL tests once
2226         the bots are capable of running WebGL tests.
2227
2228         * GNUmakefile.am: Added new files required for WebGL support.
2229         * html/HTMLCanvasElement.cpp:
2230         (WebCore::HTMLCanvasElement::getContext): Extend #ifdef to cover GTK+ as well, which does not
2231         yet support accelerated compositing.
2232         * platform/graphics/ANGLEWebKitBridge.h: Update to reflect the fact that ANGLE isn't compiled as
2233         a framework for GTK+.
2234         * platform/graphics/GraphicsContext3D.h:
2235         (WebCore::GraphicsContext3D::platformTexture): Added a declaration of this method for Cairo.
2236         (WebCore::GraphicsContext3D::paintsIntoCanvasBuffer): Ditto.
2237         * platform/graphics/cairo/GraphicsContext3DCairo.cpp: Added.
2238         (WebCore::GraphicsContext3D::getImageData): Added.
2239         (WebCore::GraphicsContext3D::paintToCanvas): Added.
2240         * platform/graphics/cairo/OpenGLShims.cpp: Added. This file controls loading of GL extension
2241         functions dynamically. They have different names across the different vendors' GL implementations.
2242         (WebCore::lookupOpenGLFunctionAddress): Added
2243         (WebCore::openGLFunctionTable): Added
2244         (WebCore::initializeOpenGLShims): Added
2245         * platform/graphics/cairo/OpenGLShims.h: Added.
2246         * platform/graphics/gtk/DrawingBufferGtk.cpp: Added.
2247         (WebCore::DrawingBuffer::DrawingBuffer): Very generic implementation for Cairo.
2248         (WebCore::DrawingBuffer::~DrawingBuffer): Ditto.
2249         (WebCore::DrawingBuffer::didReset): Ditto.
2250         (WebCore::DrawingBuffer::platformColorBuffer): Ditto.
2251         * platform/graphics/gtk/GraphicsContext3DGtk.cpp: Added.
2252         (WebCore::GraphicsContext3D::create): Initial implementation.
2253         (WebCore::GraphicsContext3D::GraphicsContext3D): Ditto.
2254         (WebCore::GraphicsContext3D::~GraphicsContext3D): Ditto.
2255         (WebCore::GraphicsContext3D::makeContextCurrent): Ditto.
2256         (WebCore::GraphicsContext3D::platformGraphicsContext3D): Ditto.
2257         (WebCore::GraphicsContext3D::isGLES2Compliant): Ditto.
2258         * platform/graphics/gtk/GraphicsContext3DInternal.cpp: Added.
2259         (sharedDisplay): Added this shared display which is required by some
2260         display drivers.
2261         (WebCore::activeGraphicsContexts): This method keeps track of all active GraphicsContext3D
2262         contexts, in order to clean them up at exit. This prevents crashes on certain OpenGL drivers.
2263         (WebCore::GraphicsContext3DInternal::addActiveGraphicsContext): Ditto.
2264         (WebCore::GraphicsContext3DInternal::removeActiveGraphicsContext): Ditto.
2265         (WebCore::GraphicsContext3DInternal::cleanupActiveContextsAtExit): Ditto.
2266         (WebCore::GraphicsContext3DInternal::create): Figure out the best way to create an OpenGL
2267         context given the current environment.
2268         (WebCore::GraphicsContext3DInternal::createPbufferContext): Pbuffer context initializer.
2269         (WebCore::GraphicsContext3DInternal::createPixmapContext): Pixmap context initializer.
2270         (WebCore::GraphicsContext3DInternal::GraphicsContext3DInternal): Initial implementation.
2271         (WebCore::GraphicsContext3DInternal::~GraphicsContext3DInternal): Ditto.
2272         (WebCore::GraphicsContext3DInternal::makeContextCurrent): Ditto.
2273         * platform/graphics/gtk/GraphicsContext3DInternal.h: Added.
2274         * platform/graphics/opengl/Extensions3DOpenGL.cpp: Added generic implementation.
2275         (WebCore::Extensions3DOpenGL::ensureEnabled): Ditto.
2276         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
2277         (WebCore::GraphicsContext3D::reshape): Test for the context using the public API rather than
2278         the private bits that are specific to the Apple port.
2279
2280 2011-04-04  Alexey Proskuryakov  <ap@apple.com>
2281
2282         Reviewed by Dan Bernstein.
2283
2284         REGRESSION (WebKit2): Caps-Lock indicator sometimes doesn't appear in WebKit2
2285         https://bugs.webkit.org/show_bug.cgi?id=51230
2286         <rdar://problem/8780989>
2287
2288         <rdar://problem/9015250> REGRESSION (WebKit2): Key events not fired for modifier keys
2289
2290         * page/EventHandler.cpp: (WebCore::EventHandler::keyEvent): Moved Caps Lock handling from
2291         WebKits to WebCore, because WebKit shouldn't be smart.
2292
2293 2011-04-04  Steve Falkenburg  <sfalken@apple.com>
2294
2295         Fix Windows build warning.
2296
2297         * WebCore.vcproj/WebCore.vcproj: Exclude EventQueue.cpp in Debug_All build.
2298
2299 2011-04-04  Adam Roben  <aroben@apple.com>
2300
2301         Attempted Mac build fix, part III
2302
2303         * WebCore.exp.in: Export PlatformCALayer::setGeometryFlipped. Also resorted some symbols.
2304
2305 2011-04-04  Andy Estes  <aestes@apple.com>
2306
2307         Fix the Mac build.
2308
2309         * WebCore.exp.in:
2310
2311 2011-04-04  David Dorwin  <ddorwin@chromium.org>
2312
2313         Reviewed by David Levin.
2314
2315         Chromium Mac crashes when entering fullscreen
2316         https://bugs.webkit.org/show_bug.cgi?id=57483
2317
2318         Override extraFullScreenStyleSheet in RenderThemeChromiumMac to avoid hitting the ASSERT_NOT_REACHED in RenderThemeMac.
2319
2320         * WebCore.gyp/WebCore.gyp:
2321         * rendering/RenderThemeChromiumMac.h:
2322         * rendering/RenderThemeChromiumMac.mm:
2323         (WebCore::RenderThemeChromiumMac::extraFullScreenStyleSheet):
2324
2325 2011-04-04  Adam Roben  <aroben@apple.com>
2326
2327         Attempted Mac build fix, part II
2328
2329         * WebCore.xcodeproj/project.pbxproj: Marked PlatformCALayerClient.h and
2330         PlatformCAAnimation.h as private so that WebKit2 can #include them (transitively).
2331
2332 2011-04-04  Steve Falkenburg  <sfalken@apple.com>
2333
2334         Reviewed by Adam Roben.
2335
2336         Remove unused AnalyzeWithLargeStack code from Windows build files
2337         https://bugs.webkit.org/show_bug.cgi?id=57771
2338         
2339         This was used for us to build with prefast automatically,
2340         but it is out-of-date and hasn't been used for some time.
2341         Removing completely for now.
2342
2343         * WebCore.vcproj/WebCore.vcproj:
2344         * WebCore.vcproj/WebCorePreBuild.cmd:
2345
2346 2011-04-01  Matthew Delaney  <mdelaney@apple.com>
2347
2348         Reviewed by Simon Fraser.
2349
2350         [CG] Do not accelerate small canvases
2351         https://bugs.webkit.org/show_bug.cgi?id=57596
2352
2353         No new tests. No outward behavior changes.
2354
2355         * platform/graphics/cg/ImageBufferCG.cpp:
2356
2357 2011-04-04  Adam Roben  <aroben@apple.com>
2358
2359         Attempted Mac build fix
2360
2361         * WebCore.xcodeproj/project.pbxproj: Marked PlatformCALayer.h and GraphicsLayerCA.h private
2362         so that WebKit can #include them.
2363
2364 2011-04-04  Malcolm MacLeod  <mmacleod@webmail.co.za>
2365
2366         Reviewed by Kevin Ollivier.
2367
2368         [wx] Implement support for temporary files.
2369         
2370         https://bugs.webkit.org/show_bug.cgi?id=57772
2371
2372         * platform/FileSystem.h:
2373         * platform/wx/FileSystemWx.cpp:
2374         (WebCore::getFileModificationTime):
2375         (WebCore::openTemporaryFile):
2376         (WebCore::closeFile):
2377         (WebCore::writeToFile):
2378
2379 2011-04-01  Oliver Hunt  <oliver@apple.com>
2380
2381         Reviewed by Geoffrey Garen.
2382
2383         Make StructureChain GC allocated
2384         https://bugs.webkit.org/show_bug.cgi?id=56695
2385
2386         Update for new Structure marking function
2387
2388         * bindings/js/JSDOMGlobalObject.cpp:
2389         (WebCore::JSDOMGlobalObject::markChildren):
2390
2391 2011-04-04  Pavel Feldman  <pfeldman@google.com>
2392
2393         Reviewed by Yury Semikhatsky.
2394
2395         Web Inspector: add support for the enumerated types in the protocol.
2396         https://bugs.webkit.org/show_bug.cgi?id=57761
2397
2398         * inspector/Inspector.json:
2399         * inspector/InspectorDebuggerAgent.cpp:
2400         (WebCore::InspectorDebuggerAgent::setPauseOnExceptions):
2401         * inspector/InspectorDebuggerAgent.h:
2402         * inspector/InspectorInstrumentation.cpp:
2403         (WebCore::InspectorInstrumentation::resourceRetrievedByXMLHttpRequestImpl):
2404         (WebCore::InspectorInstrumentation::scriptImportedImpl):
2405         * inspector/InspectorResourceAgent.cpp:
2406         (WebCore::cachedResourceTypeString):
2407         (WebCore::InspectorResourceAgent::didReceiveResponse):
2408         (WebCore::InspectorResourceAgent::setInitialScriptContent):
2409         (WebCore::InspectorResourceAgent::setInitialXHRContent):
2410         * inspector/InspectorResourceAgent.h:
2411         * inspector/front-end/ScriptsPanel.js:
2412         * inspector/generate-inspector-idl:
2413
2414 2011-04-04  Yury Semikhatsky  <yurys@chromium.org>
2415
2416         Reviewed by Pavel Feldman.
2417
2418         Web Inspector: InspectorRuntimeAgent should not depend on Page
2419         https://bugs.webkit.org/show_bug.cgi?id=57759
2420
2421         Descendants of InspectorRuntimeAgent should implement a method providing access to the default
2422         inspected state used for console evaluations.
2423
2424         * inspector/InspectorAgent.cpp:
2425         (WebCore::InspectorAgent::InspectorAgent): runtime agent is created and deleted along with other agents.
2426         (WebCore::InspectorAgent::setFrontend):
2427         * inspector/InspectorAgent.h:
2428         * inspector/InspectorRuntimeAgent.cpp:
2429         (WebCore::InspectorRuntimeAgent::create):
2430         (WebCore::InspectorRuntimeAgent::InspectorRuntimeAgent):
2431         (WebCore::InspectorRuntimeAgent::evaluate):
2432         * inspector/InspectorRuntimeAgent.h:
2433         (WebCore::InspectorRuntimeAgent::InspectedStateProvider::~InspectedStateProvider):
2434
2435 2011-04-04  Yong Li  <yoli@rim.com>
2436
2437         Reviewed by Antonio Gomes.
2438
2439         https://bugs.webkit.org/show_bug.cgi?id=55969
2440         Fix the issue that document state is not saved when
2441         going backward and ending up with error page.
2442
2443         Test: platform/qt/fast/history/back-to-unreachable-url-then-forward.html
2444
2445         (For manual test, load a non-existent html first, then load
2446         fast/history/resources/check-scroll-position.html, then go
2447         back and go forward. If it doesn't show "SUCCESS" at the bottom
2448         of the page, your browser has failed the test)
2449
2450         * loader/FrameLoader.cpp:
2451         (WebCore::FrameLoader::load):
2452
2453 2011-04-04  Sergio Villar Senin  <svillar@igalia.com>
2454
2455         Reviewed by Martin Robinson.
2456
2457         [GTK] Fix make distcheck for 1.4.0
2458         https://bugs.webkit.org/show_bug.cgi?id=57750
2459
2460         Added a missing header file to the Makefile
2461
2462         * GNUmakefile.am:
2463
2464 2011-04-04  Martin Robinson  <mrobinson@igalia.com>
2465
2466         Reviewed by Xan Lopez.
2467
2468         [GTK] http/tests/plugins/post-url-file.html fails on GTK+
2469         https://bugs.webkit.org/show_bug.cgi?id=55826
2470
2471         Correct the implementation of handlePostReadFile which uses GIO APIs and
2472         actually resizes the buffer to fit the entire size of the file data. This
2473         was likely leading to memory corruption until now.
2474
2475         * plugins/gtk/PluginViewGtk.cpp:
2476         (WebCore::PluginView::handlePostReadFile): Fix this method.
2477
2478 2011-04-04  Andrey Kosyakov  <caseq@chromium.org>
2479
2480         Reviewed by Yury Semikhatsky.
2481
2482         Web Inspector: [Extensions API] add notifications on panels shown/hidden
2483         https://bugs.webkit.org/show_bug.cgi?id=57752
2484
2485         * inspector/front-end/ExtensionAPI.js:
2486         (WebInspector.injectedExtensionAPI.PanelImpl):
2487         * inspector/front-end/ExtensionServer.js:
2488         (WebInspector.ExtensionServer.prototype.notifyPanelShown):
2489         (WebInspector.ExtensionServer.prototype.notifyPanelHidden):
2490         * inspector/front-end/Panel.js:
2491         (WebInspector.Panel.prototype.show):
2492         (WebInspector.Panel.prototype.hide):
2493
2494 2011-04-04  Pavel Podivilov  <podivilov@chromium.org>
2495
2496         Reviewed by Yury Semikhatsky.
2497
2498         Web Inspector: search in resources panel is broken.
2499         https://bugs.webkit.org/show_bug.cgi?id=57631
2500
2501         Search in resources panel should trigger source frame content load.
2502
2503         * inspector/front-end/Panel.js:
2504         (WebInspector.Panel.prototype.jumpToNextSearchResult):
2505         (WebInspector.Panel.prototype.jumpToPreviousSearchResult):
2506         * inspector/front-end/ResourcesPanel.js:
2507         * inspector/front-end/SearchController.js:
2508         (WebInspector.SearchController.prototype.handleShortcut):
2509         (WebInspector.SearchController.prototype.focusSearchField):
2510         * inspector/front-end/SourceFrame.js:
2511         (WebInspector.SourceFrame.prototype.show):
2512         (WebInspector.SourceFrame.prototype._ensureContentLoaded):
2513         (WebInspector.SourceFrame.prototype.performSearch):
2514
2515 2011-04-03  Eric Seidel  <eric@webkit.org>
2516
2517         Reviewed by Ryosuke Niwa.
2518
2519         Split out UnicodeBidi enum into its own header (to allow use in platform)
2520         https://bugs.webkit.org/show_bug.cgi?id=57722
2521
2522         unicode-bidi is a CSS concept.  However the same concept is really needed throughout
2523         the bidi code in platform as well.  So I'm moving the enum to platform.
2524         The only part of the enum which doesn't make much sense to platform/ is "normal".
2525
2526         * WebCore.xcodeproj/project.pbxproj:
2527         * css/CSSPrimitiveValueMappings.h:
2528         * platform/text/UnicodeBidi.h: Added.
2529         * rendering/style/RenderStyle.h:
2530         * rendering/style/RenderStyleConstants.h:
2531
2532 2011-04-04  Andrey Adaikin  <aandrey@google.com>
2533
2534         Reviewed by Yury Semikhatsky.
2535
2536         Web Inspector: Highlighted search tokens would not be shown on long lines in the text viewer
2537         https://bugs.webkit.org/show_bug.cgi?id=57749
2538
2539         * inspector/front-end/TextViewer.js:
2540         (WebInspector.TextEditorMainPanel.prototype.markAndRevealRange):
2541         (WebInspector.TextEditorMainPanel.prototype._paintLine):
2542
2543 2011-04-04  Alexander Pavlov  <apavlov@chromium.org>
2544
2545         Reviewed by Yury Semikhatsky.
2546
2547         Web Inspector: Incorrectly reports warning on missing/incorrect content-type for 304s
2548         https://bugs.webkit.org/show_bug.cgi?id=48525
2549
2550         * inspector/front-end/Resource.js:
2551         (WebInspector.Resource.prototype._mimeTypeIsConsistentWithType):
2552
2553 2011-04-01  Alexander Pavlov  <apavlov@chromium.org>
2554
2555         Reviewed by Yury Semikhatsky.
2556
2557         Web Inspector: appropriateSelectorForNode() invokes the "localName" getter on DOMNode rather than function
2558         https://bugs.webkit.org/show_bug.cgi?id=57632
2559
2560         Moved the affected method onto the DOMNode.prototype as "appropriateSelectorFor".
2561
2562         * inspector/front-end/DOMAgent.js:
2563         (WebInspector.DOMNode.prototype.appropriateSelectorFor):
2564         * inspector/front-end/EventListenersSidebarPane.js:
2565         ():
2566         * inspector/front-end/StylesSidebarPane.js:
2567         (WebInspector.StylesSidebarPane.prototype.addBlankSection):
2568         * inspector/front-end/utilities.js:
2569
2570 2011-04-04  Andrey Kosyakov  <caseq@chromium.org>
2571
2572         Unreviewed. Followup to an incomplete commit in r82806.
2573
2574         * inspector/front-end/ExtensionAPI.js:
2575         (WebInspector.injectedExtensionAPI.PanelWithSidebarImpl.prototype.createSidebarPane):
2576         (WebInspector.injectedExtensionAPI.ExtensionSidebarPaneImpl):
2577         (WebInspector.injectedExtensionAPI.ExtensionSidebarPaneImpl.prototype.setHeight):
2578         (WebInspector.injectedExtensionAPI.ExtensionSidebarPaneImpl.prototype.setExpression):
2579         (WebInspector.injectedExtensionAPI):
2580         * inspector/front-end/ExtensionPanel.js:
2581         (WebInspector.ExtensionSidebarPane):
2582         (WebInspector.ExtensionSidebarPane.prototype.setPage):
2583         (WebInspector.ExtensionSidebarPane.prototype._setObject):
2584         * inspector/front-end/ExtensionServer.js:
2585         (WebInspector.ExtensionServer):
2586         (WebInspector.ExtensionServer.prototype.notifyExtensionSidebarUpdated):
2587         (WebInspector.ExtensionServer.prototype._onCreatePanel):
2588         (WebInspector.ExtensionServer.prototype._onCreateSidebarPane):
2589         (WebInspector.ExtensionServer.prototype.createClientIframe):
2590         (WebInspector.ExtensionServer.prototype._onSetSidebarContent):
2591
2592 2011-04-04  Yury Semikhatsky  <yurys@chromium.org>
2593
2594         Unreviewed. Fix Qt minimal build.
2595
2596         * inspector/InspectorFrontendChannel.h:
2597
2598 2011-04-01  Sergey Vorobyev  <sergeyvorobyev@google.com>
2599
2600         Reviewed by Yury Semikhatsky.
2601
2602         Web Inspector: Separate sendMessageToFrontend function
2603         from InspectorClient to individual interface.
2604         https://bugs.webkit.org/show_bug.cgi?id=57548
2605
2606         Refactoring - covered with existing inspector tests.
2607
2608         * GNUmakefile.am:
2609         * WebCore.gypi:
2610         * WebCore.vcproj/WebCore.vcproj:
2611         * WebCore.xcodeproj/project.pbxproj:
2612         * inspector/CodeGeneratorInspector.pm:
2613         * inspector/InspectorClient.h:
2614         * inspector/InspectorFrontendChannel.h: Added.
2615         (WebCore::InspectorFrontendChannel::~InspectorFrontendChannel):
2616
2617 2011-04-04  Nico Weber  <thakis@chromium.org>
2618
2619         Reviewed by Eric Seidel.
2620
2621         Prefer a using directive over qualified names in LocalizedNumberICU.cpp
2622         https://bugs.webkit.org/show_bug.cgi?id=57742
2623
2624         Requested by ap in https://bugs.webkit.org/show_bug.cgi?id=57715
2625
2626         * platform/text/LocalizedNumberICU.cpp:
2627         (WebCore::createFormatterForCurrentLocale):
2628         (WebCore::numberFormatter):
2629         (WebCore::parseLocalizedNumber):
2630         (WebCore::formatLocalizedNumber):
2631
2632 2011-04-04  Andrey Adaikin  <aandrey@google.com>
2633
2634         Reviewed by Yury Semikhatsky.
2635
2636         Web Inspector: Breakpoints in the gutter stay static while editing the text
2637         https://bugs.webkit.org/show_bug.cgi?id=57616
2638
2639         * inspector/front-end/SourceFrame.js:
2640         (WebInspector.SourceFrame):
2641         (WebInspector.SourceFrame.prototype._saveViewerState):
2642         (WebInspector.SourceFrame.prototype._restoreViewerState):
2643         (WebInspector.SourceFrame.prototype._endEditing):
2644         (WebInspector.SourceFrame.prototype._lineNumberAfterEditing):
2645         (WebInspector.SourceFrame.prototype.addBreakpoint):
2646         (WebInspector.SourceFrame.prototype.removeBreakpoint):
2647         * inspector/front-end/TextViewer.js:
2648         (WebInspector.TextViewer.prototype._syncDecorationsForLine):
2649         (WebInspector):
2650         (WebInspector.TextEditorChunkedPanel.prototype.removeDecoration):
2651         (WebInspector.TextEditorChunkedPanel.prototype.makeLineAChunk):
2652         (WebInspector.TextEditorChunkedPanel.prototype._splitChunkOnALine):
2653         (WebInspector.TextEditorMainPanel.prototype._splitChunkOnALine):
2654
2655 2011-04-04  Ilya Tikhonovsky  <loislo@chromium.org>
2656
2657         Reviewed by Yury Semikhatsky.
2658
2659         Web Inspector: remove obsolete doc generating code from CodeGenerator.
2660         https://bugs.webkit.org/show_bug.cgi?id=57748
2661
2662         * inspector/CodeGeneratorInspector.pm:
2663
2664 2011-04-04  Andrey Kosyakov  <caseq@chromium.org>
2665
2666         Reviewed by Yury Semikhatsky.
2667
2668         Web Inspector: [Extensions API] Merge WatchExpressionSidebarPane into ExtensionSidebarPane
2669         https://bugs.webkit.org/show_bug.cgi?id=57622
2670
2671         Merged WatchExpressionSidebarPane into ExtensionSidebarPane, added setPage(url).
2672         Fixed wrong getter in schema (scripts -> elements)
2673
2674         * inspector/front-end/ExtensionAPI.js:
2675         (WebInspector.injectedExtensionAPI.WatchExpressionSidebarPaneImpl.prototype.setObject):
2676         (WebInspector.injectedExtensionAPI.WatchExpressionSidebarPaneImpl.prototype.setPage):
2677         * inspector/front-end/ExtensionAPISchema.json:
2678         * inspector/front-end/ExtensionServer.js:
2679         (WebInspector.ExtensionServer.prototype._onSetSidebarPage):
2680
2681 2011-04-04  Ilya Tikhonovsky  <loislo@chromium.org>
2682
2683         Reviewed by Pavel Feldman.
2684
2685         Web Inspector: introduce support of 'optional' flag for command arguments.
2686         https://bugs.webkit.org/show_bug.cgi?id=57698
2687
2688         * inspector/CodeGeneratorInspector.pm:
2689         * inspector/Inspector.json:
2690         * inspector/InspectorDebuggerAgent.cpp:
2691         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
2692         (WebCore::InspectorDebuggerAgent::setBreakpoint):
2693         (WebCore::InspectorDebuggerAgent::evaluateOnCallFrame):
2694         * inspector/InspectorDebuggerAgent.h:
2695         * inspector/InspectorPageAgent.cpp:
2696         (WebCore::InspectorPageAgent::reloadPage):
2697         * inspector/InspectorPageAgent.h:
2698         * inspector/InspectorResourceAgent.cpp:
2699         (WebCore::InspectorResourceAgent::getResourceContent):
2700         * inspector/InspectorResourceAgent.h:
2701         * inspector/InspectorRuntimeAgent.cpp:
2702         (WebCore::InspectorRuntimeAgent::evaluate):
2703         * inspector/InspectorRuntimeAgent.h:
2704         * inspector/generate-inspector-idl:
2705
2706 2011-04-04  Yury Semikhatsky  <yurys@chromium.org>
2707
2708         Reviewed by Pavel Feldman.
2709
2710         Web Inspector: InjectedScriptManager should not try to access inspected window in case of workers
2711         https://bugs.webkit.org/show_bug.cgi?id=57637
2712
2713         * bindings/js/JSInjectedScriptManager.cpp:
2714         (WebCore::InjectedScriptManager::injectedScriptFor):
2715         * bindings/v8/custom/V8InjectedScriptManager.cpp:
2716         (WebCore::InjectedScriptManager::injectedScriptFor):
2717         * inspector/InjectedScript.cpp:
2718         (WebCore::InjectedScript::InjectedScript):
2719         (WebCore::InjectedScript::canAccessInspectedWindow):
2720         * inspector/InjectedScript.h:
2721         * inspector/InjectedScriptManager.cpp:
2722         (WebCore::InjectedScriptManager::createForPage):
2723         (WebCore::InjectedScriptManager::createForWorker):
2724         (WebCore::InjectedScriptManager::InjectedScriptManager): access check function is passed as a parameter to the constructor
2725         and it depends on which type of context we're inspecting(worker or page).
2726         (WebCore::InjectedScriptManager::canAccessInspectedWorkerContext):
2727         * inspector/InjectedScriptManager.h:
2728         * inspector/InspectorController.cpp:
2729         (WebCore::InspectorController::InspectorController):
2730
2731 2011-04-04  Ryuan Choi  <ryuan.choi@samsung.com>
2732
2733         Reviewed by Eric Seidel.
2734
2735         V8StringCallback.cpp requires V8Binding.h
2736         https://bugs.webkit.org/show_bug.cgi?id=57699
2737
2738         No new tests required because of just adding header file.
2739
2740         * bindings/scripts/CodeGeneratorV8.pm:
2741
2742 2011-04-03  Ryuan Choi  <ryuan.choi@samsung.com>
2743
2744         Reviewed by Eric Seidel.
2745
2746         [CMAKE] Clean duplicated files in WebCore_Sources
2747         https://bugs.webkit.org/show_bug.cgi?id=57741
2748
2749         No new tests, Only duplicated files were removed.
2750
2751         * CMakeLists.txt:
2752
2753 2011-04-03  Luke Macpherson   <macpherson@chromium.org>
2754
2755         Reviewed by Darin Adler.
2756
2757         Fix 2-space indentation introduced in bug 54706.
2758         https://bugs.webkit.org/show_bug.cgi?id=57740
2759
2760         No new tests - whitespace changes only.
2761
2762         * css/CSSStyleSelector.cpp:
2763         (WebCore::CSSStyleSelector::applyProperty):
2764         Convert 2-space indentation to 4-space indentation.
2765
2766 2011-04-03  Luke Macpherson   <macpherson@chromium.org>
2767
2768         Reviewed by Dimitri Glazkov.
2769
2770         Make CSSStyleApplyProperty non-copyable
2771         https://bugs.webkit.org/show_bug.cgi?id=57738
2772
2773         No new functionality added so no new tests required.
2774
2775         * css/CSSStyleApplyProperty.h:
2776         Added WTF_MAKE_NONCOPYABLE(CSSStyleApplyProperty) to ensure singleton stays single.
2777
2778 2011-04-03  Dan Bernstein  <mitz@apple.com>
2779
2780         Reviewed by Maciej Stachowiak.
2781
2782         fast/images/extra-image-in-image-document.html crashes when run after embed-image.html
2783         https://bugs.webkit.org/show_bug.cgi?id=57733
2784
2785         The crash happens because resetting the page scale as part of preparing the WebView for the
2786         next test triggered layout, which in turn caused a plug-in to make a resource request, and
2787         DumpRenderTree's delegate to be dispatched. The delegate doesn’t expect to be called between
2788         tests, and it references the layout test controller, which is null.
2789
2790         * page/Frame.cpp:
2791         (WebCore::Frame::scalePage): Avoid an unnecessary layout if the page scale isn’t changing. This
2792         is more efficient, and has the side effect of avoiding the crash in DumpRenderTree, although
2793         DumpRenderTree could still crash when after a test with disabled plug-ins and a non-1 page scale.
2794         I think there are currently no such tests, so I am not fixing DumpRenderTree.
2795
2796 2011-04-03  Eric Seidel  <eric@webkit.org>
2797
2798         Reviewed by Ryosuke Niwa.
2799
2800         Teach InlineIterator how to work from any root, not just a RenderBlock
2801         https://bugs.webkit.org/show_bug.cgi?id=57726
2802
2803         For implementing bidi-unicode: isolate, we need to be able to run the
2804         bidi algorithm over a subtree of inlines, not just from a block root.
2805         This is the first step in making this possible.
2806
2807         * rendering/InlineIterator.h:
2808         (WebCore::InlineIterator::InlineIterator):
2809         (WebCore::InlineIterator::root):
2810         (WebCore::bidiNext):
2811         (WebCore::bidiFirst):
2812         (WebCore::InlineIterator::increment):
2813         (WebCore::InlineBidiResolver::appendRun):
2814         * rendering/RenderBlockLineLayout.cpp:
2815         (WebCore::RenderBlock::findNextLineBreak):
2816
2817 2011-04-03  Eric Seidel  <eric@webkit.org>
2818
2819         Reviewed by Dan Bernstein.
2820
2821         Split out handling of trailing spaces from layoutInlineChildren
2822         https://bugs.webkit.org/show_bug.cgi?id=57432
2823
2824         There is much more we could split out from this function, but this is a start.
2825
2826         I suspect this is very hot code.  Hopefully the compiler will do the right thing.
2827         If it doesn't the Chromium PLT bots will tell us.
2828
2829         * rendering/RenderBlock.h:
2830         * rendering/RenderBlockLineLayout.cpp:
2831         (WebCore::RenderBlock::handleTrailingSpaces):
2832         (WebCore::RenderBlock::layoutInlineChildren):
2833
2834 2011-03-21  Ryosuke Niwa  <rniwa@webkit.org>
2835
2836         Reviewed by Eric Seidel.
2837
2838         editing commands shouldn't run when there's no body
2839         https://bugs.webkit.org/show_bug.cgi?id=56771
2840
2841         The bug was caused by WebKit's not checking the existence of root editable element
2842         in enabled* functions. Although isContentEditable returns true whenever we're in design mode,
2843         we should not run editing commands in a document without a body element editable because
2844         doing so results in appending a non-body element to the document node.
2845
2846         Fixed the bug by modifying various enabled* functions to ensure we have a root editable element.
2847         New behavior tries to match that of Firefox except StyleWithCSS, which Firefox seems to ignore
2848         when there are no body element. Since StyleWithCSS is a document's state or property, we allow
2849         execCommand('StyleWithCSS') even in a document without a body element.
2850
2851         WebKit's and Firefox's behaviors also deviate in insert-image-with-selecting-document.html.
2852         Whereas WebKit respects selection set by script and ignores execCommand, Firefox modifies
2853         the selection when document.write("x") is ran and successfully inserts image.
2854
2855         Thus, empty-document-delete.html and empty-document-justify-right.html both pass on Firefox
2856         while empty-document-stylewithcss.html and insert-image-with-selecting-document.html both fail.
2857
2858         Since Internet Explorer does not allow execCommand to run under design mode properly, we could
2859         not test its behavior.
2860
2861         Tests: editing/editability/empty-document-delete.html
2862                editing/editability/empty-document-justify-right.html
2863                editing/editability/empty-document-stylewithcss.html
2864                editing/execCommand/insert-image-with-selecting-document.html
2865
2866         * editing/Editor.cpp:
2867         (WebCore::Editor::canEdit): Verify that the root editable element exists
2868         instead of just checking that selection endpoints are editable because
2869         selection endpoints could be document node without a body element in design mode
2870         and we don't want to consider such a document editable.
2871         (WebCore::Editor::canDelete): Ditto.
2872         * editing/EditorCommand.cpp:
2873         (WebCore::enabledInEditableText): Ditto.
2874         (WebCore::enabledInRichlyEditableText): Ditto.
2875         (WebCore::enabledDelete): Call enabledCut and enabledInEditableText instead
2876         of duplicating the code in order to fix the same bug.
2877
2878 2011-04-02  Dan Bernstein  <mitz@apple.com>
2879
2880         Reviewed by Maciej Stachowiak.
2881
2882         REGRESSION (r82786): Media controls render incorrectly on GTK and Qt
2883         https://bugs.webkit.org/show_bug.cgi?id=57719
2884
2885         r82786 exposed an incorrect assumption inRenderMediaControlTimeDisplay::layout()
2886         that the timeline container is the parent of the time display. This is not true
2887         with the GTK media style, where the current time display is an inline box, and
2888         thus wrapped in an anonymous flexible box. The code was incorrectly considering
2889         the width of the anonymous box and deciding to hide the time display. Prior to
2890         r82786, this mistake was corrected by the call to computeLogicalWidth() in line layout.
2891
2892         * rendering/MediaControlElements.cpp:
2893         (WebCore::RenderMediaControlTimeDisplay::layout): Changed to skip past anonymous ancestors.
2894
2895 2011-04-02  Nico Weber  <thakis@chromium.org>
2896
2897         Reviewed by Adam Barth.
2898
2899         Explicitly use icu namespace for ports building with U_USING_ICU_NAMESPACE=0
2900
2901         By default, ICU includes |using namespace icu;| in its header files
2902         for backwards compatibility. Clients can define
2903         U_USING_ICU_NAMESPACE=0 to tell ICU to not do this. Prefixing all ICU
2904         classes with |icu::| makes this file compile no matter what
2905         U_USING_ICU_NAMESPACE is set to.
2906
2907         https://bugs.webkit.org/show_bug.cgi?id=57715
2908
2909         * platform/text/LocalizedNumberICU.cpp:
2910         (WebCore::createFormatterForCurrentLocale):
2911         (WebCore::numberFormatter):
2912         (WebCore::parseLocalizedNumber):
2913         (WebCore::formatLocalizedNumber):
2914
2915 2011-04-02  Dan Bernstein  <mitz@apple.com>
2916
2917         Reviewed by Dave Hyatt.
2918
2919         Remove an unnecessary extra computeLogicalWidth() from line layout
2920         https://bugs.webkit.org/show_bug.cgi?id=57711
2921
2922         Changes in behavior (MathML progression) covered by existing layout tests.
2923
2924         * rendering/RenderBlockLineLayout.cpp:
2925         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Removed a
2926         call to computeLogicalWidth(). Because of <http://webkit.org/b/57700>, this
2927         actually prevents MathML rows from reverting to an incorrect width.
2928
2929 2011-04-02  Dan Bernstein  <mitz@apple.com>
2930
2931         Reviewed by Beth Dakin.
2932
2933         <details> marker loses its margin
2934         https://bugs.webkit.org/show_bug.cgi?id=57713
2935
2936         * rendering/RenderDetails.cpp:
2937         (WebCore::RenderDetails::computePreferredLogicalWidths): Override to update
2938         the marker location.
2939         * rendering/RenderDetails.h:
2940         (WebCore::RenderDetails::renderName): Made private.
2941         (WebCore::RenderDetails::isDetails): Ditto.
2942         * rendering/RenderDetailsMarker.cpp:
2943         (WebCore::RenderDetailsMarker::computePreferredLogicalWidths): Set the margins
2944         in the style, like RenderListMarker does.
2945         (WebCore::RenderDetailsMarker::layout): Set the margins from the style.
2946
2947 2011-04-02  Andy Estes  <aestes@apple.com>
2948
2949         Reviewed by Oliver Hunt.
2950
2951         REGRESSION (r69237): Black border around map elements while using an image map on Mac platform
2952         https://bugs.webkit.org/show_bug.cgi?id=52518
2953
2954         Test: fast/images/imagemap-focus-ring-zero-outline-width.html
2955
2956         * rendering/RenderImage.cpp:
2957         (WebCore::RenderImage::paintAreaElementFocusRing): Return early if outlineWidth is 0.
2958
2959 2011-04-02  Beth Dakin  <bdakin@apple.com>
2960
2961         Reviewed by Sam Weinig.
2962
2963         https://bugs.webkit.org/show_bug.cgi?id=57605
2964         Frame::pageScaleFactor() should not affect getBoundingClientRect() or 
2965         getClientRects()
2966         -and corresponding-
2967         <rdar://problem/9194541>
2968
2969         New functions adjust*ForPageScale() are analogous to adjust*ForAbsoluteZoom().
2970         * dom/Element.cpp:
2971         (WebCore::Element::getClientRects):
2972         (WebCore::Element::getBoundingClientRect):
2973         * dom/Range.cpp:
2974         (WebCore::adjustFloatQuadsForScrollAndAbsoluteZoomAndPageScale):
2975         (WebCore::Range::getBorderAndTextQuads):
2976         * rendering/RenderObject.h:
2977         (WebCore::adjustFloatPointForPageScale):
2978         (WebCore::adjustFloatQuadForPageScale):
2979         (WebCore::adjustFloatRectForPageScale):
2980
2981 2011-04-02  Dan Bernstein  <mitz@apple.com>
2982
2983         Reverted r82775 due to changes in <details> test results, which are
2984         likely progressions.
2985
2986         * rendering/RenderBlockLineLayout.cpp:
2987         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Removed a
2988
2989 2011-04-02  Dan Bernstein  <mitz@apple.com>
2990
2991         Reviewed by Dave Hyatt.
2992
2993         Remove an unnecessary extra computeLogicalWidth() from line layout
2994         https://bugs.webkit.org/show_bug.cgi?id=57711
2995
2996         Changes in behavior (MathML progression) covered by existing layout tests.
2997
2998         * rendering/RenderBlockLineLayout.cpp:
2999         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine): Removed a
3000         call to computeLogicalWidth(). Because of <http://webkit.org/b/57700>, this
3001         actually prevents MathML rows from reverting to an incorrect width.
3002
3003 2011-04-02  Ryuan Choi  <ryuan.choi@samsung.com>
3004
3005         Reviewed by Martin Robinson.
3006
3007         [GTK] Fix leaked pointer in FontGtk.cpp
3008         https://bugs.webkit.org/show_bug.cgi?id=57307
3009
3010         Fix a memory leak.
3011
3012         No new functionality, so no new tests.
3013
3014         * platform/graphics/gtk/FontGtk.cpp:
3015         (WebCore::utf16ToUtf8): Rename utf16_to_utf8 and fix indentation.
3016         (WebCore::convertUniCharToUTF8):
3017
3018 2011-04-02  Ilya Tikhonovsky  <loislo@chromium.org>
3019
3020         Reviewed by Pavel Feldman.
3021
3022         Web Inspector: we should be able to have in and out arguments of a command with same name.
3023         https://bugs.webkit.org/show_bug.cgi?id=57701
3024
3025         * inspector/CodeGeneratorInspector.pm:
3026         * inspector/Inspector.json:
3027
3028 2011-04-01  Ilya Tikhonovsky  <loislo@chromium.org>
3029
3030         Not reviewed trivial change.
3031
3032         Web Inspector: The page agent should be enabled even if JAVASCRIPT_DEBUGGER is off.
3033         Followup change for r82281.
3034         https://bugs.webkit.org/show_bug.cgi?id=57327
3035
3036         * inspector/InspectorPageAgent.cpp:
3037         * inspector/InspectorPageAgent.h:
3038
3039 2011-04-01  Michael Saboff  <msaboff@apple.com>
3040
3041         Reviewed by Darin Adler.
3042
3043         Cached Resource Overhead Space Usage and Accounting Inaccurate
3044         https://bugs.webkit.org/show_bug.cgi?id=57488
3045
3046         Fixed windows test failures.
3047         Changed the fixed overhead value for ResourceResponse to 3800 bytes.
3048         Modified ResourceResponse::platformLazyInit() to handle "base" level
3049         attributes or all attributes.  The base attributes, like URL, status
3050         code, mime type and a few header fields (mostly cache related) are
3051         suitable for most resources.  This reduces the per resource memory
3052         needs by over 1K bytes per resource thus saving memory in the cache.
3053         Collectively, these two changes bring the overhead memory calculation
3054         in line with reality.
3055
3056         No new tests added due to existing tests cover areas of change and
3057         there is no functional change.  The change is limited to reducing 
3058         memory usage along existing paths.
3059
3060         * loader/cache/CachedResource.cpp:
3061         (WebCore::CachedResource::canUseCacheValidator):
3062         * platform/network/ResourceResponseBase.cpp:
3063         (WebCore::ResourceResponseBase::adopt):
3064         (WebCore::ResourceResponseBase::isHTTP):
3065         (WebCore::ResourceResponseBase::url):
3066         (WebCore::ResourceResponseBase::setURL):
3067         (WebCore::ResourceResponseBase::mimeType):
3068         (WebCore::ResourceResponseBase::setMimeType):
3069         (WebCore::ResourceResponseBase::expectedContentLength):
3070         (WebCore::ResourceResponseBase::setExpectedContentLength):
3071         (WebCore::ResourceResponseBase::textEncodingName):
3072         (WebCore::ResourceResponseBase::setTextEncodingName):
3073         (WebCore::ResourceResponseBase::suggestedFilename):
3074         (WebCore::ResourceResponseBase::setSuggestedFilename):
3075         (WebCore::ResourceResponseBase::httpStatusCode):
3076         (WebCore::ResourceResponseBase::setHTTPStatusCode):
3077         (WebCore::ResourceResponseBase::httpStatusText):
3078         (WebCore::ResourceResponseBase::setHTTPStatusText):
3079         (WebCore::ResourceResponseBase::httpHeaderField):
3080         (WebCore::ResourceResponseBase::setHTTPHeaderField):
3081         (WebCore::ResourceResponseBase::httpHeaderFields):
3082         (WebCore::ResourceResponseBase::parseCacheControlDirectives):
3083         (WebCore::ResourceResponseBase::hasCacheValidatorFields):
3084         (WebCore::ResourceResponseBase::date):
3085         (WebCore::ResourceResponseBase::age):
3086         (WebCore::ResourceResponseBase::expires):
3087         (WebCore::ResourceResponseBase::lastModified):
3088         (WebCore::ResourceResponseBase::isAttachment):
3089         (WebCore::ResourceResponseBase::setLastModifiedDate):
3090         (WebCore::ResourceResponseBase::lastModifiedDate):
3091         (WebCore::ResourceResponseBase::wasCached):
3092         (WebCore::ResourceResponseBase::connectionReused):
3093         (WebCore::ResourceResponseBase::setConnectionReused):
3094         (WebCore::ResourceResponseBase::connectionID):
3095         (WebCore::ResourceResponseBase::setConnectionID):
3096         (WebCore::ResourceResponseBase::resourceLoadTiming):
3097         (WebCore::ResourceResponseBase::setResourceLoadTiming):
3098         (WebCore::ResourceResponseBase::resourceLoadInfo):
3099         (WebCore::ResourceResponseBase::setResourceLoadInfo):
3100         (WebCore::ResourceResponseBase::lazyInit):
3101         * platform/network/ResourceResponseBase.h:
3102         (WebCore::ResourceResponseBase::platformLazyInit):
3103         * platform/network/cf/ResourceResponse.h:
3104         (WebCore::ResourceResponse::ResourceResponse):
3105         (WebCore::ResourceResponse::memoryUsage):
3106         * platform/network/cf/ResourceResponseCFNet.cpp:
3107         (WebCore::ResourceResponse::platformLazyInit):
3108         * platform/network/mac/ResourceResponseMac.mm:
3109         (WebCore::ResourceResponse::platformLazyInit):
3110
3111 2011-04-01  Anantanarayanan G Iyengar  <ananta@chromium.org>
3112
3113         Reviewed by Adam Barth.
3114
3115         https://bugs.webkit.org/show_bug.cgi?id=45855
3116         Windowless plugins added dynamically to the DOM should receive paint events.
3117         This is done by ensuring that the plugin widget is marked for painting when
3118         it is added.
3119
3120         Test: plugins/windowless_plugin_paint_test.html
3121
3122         * rendering/RenderWidget.cpp:
3123         (WebCore::RenderWidget::setWidget):
3124
3125 2011-04-01  Mike Reed  <reed@google.com>
3126
3127         Reviewed by James Robinson.
3128
3129         always use native font rendering on skia_gpu
3130         fixes a crash when SKIA_GPU is enabled, as we can't call getTopPlatformDevice()
3131         https://bugs.webkit.org/show_bug.cgi?id=57663
3132
3133         No new tests. existing rendering tests will exercise this
3134
3135         * platform/graphics/skia/PlatformContextSkia.cpp:
3136         (WebCore::PlatformContextSkia::isNativeFontRenderingAllowed):
3137
3138 2011-04-01  Sheriff Bot  <webkit.review.bot@gmail.com>
3139
3140         Unreviewed, rolling out r82712, r82729, and r82746.
3141         http://trac.webkit.org/changeset/82712
3142         http://trac.webkit.org/changeset/82729
3143         http://trac.webkit.org/changeset/82746
3144         https://bugs.webkit.org/show_bug.cgi?id=57682
3145
3146         fast/frames/frame-programmatic-noresize.html is failing on
3147         Windows bots. Will look into this offline. (Requested by dydx
3148         on #webkit).
3149
3150         * html/HTMLFrameElement.cpp:
3151         (WebCore::HTMLFrameElement::HTMLFrameElement):
3152         (WebCore::HTMLFrameElement::attach):
3153         (WebCore::HTMLFrameElement::parseMappedAttribute):
3154         * html/HTMLFrameElement.h:
3155         (WebCore::HTMLFrameElement::noResize):
3156         * rendering/RenderFrame.cpp:
3157         * rendering/RenderFrame.h:
3158         * rendering/RenderFrameSet.cpp:
3159         * rendering/RenderFrameSet.h:
3160
3161 2011-04-01  Adam Barth  <abarth@webkit.org>
3162
3163         Reviewed by Tony Chang.
3164
3165         Valgrind error in _ZN7WebCore8Document11updateTitleERKNS_19StringWithDirectionE
3166         https://bugs.webkit.org/show_bug.cgi?id=57656
3167
3168         We should initialize memory when constructing objects.
3169
3170         * platform/text/StringWithDirection.h:
3171         (WebCore::StringWithDirection::StringWithDirection):
3172
3173 2011-04-01  Jer Noble  <jer.noble@apple.com>
3174
3175         Reviewed by Darin Adler.
3176
3177         WebKit2: Link from PDF opens in a new tab instead of in the same tab
3178         https://bugs.webkit.org/show_bug.cgi?id=57528
3179
3180         * WebCore.exp.in: Export MouseEvent::create().
3181
3182 2011-04-01  John Bauman  <jbauman@chromium.org>
3183
3184         Reviewed by Kenneth Russell.
3185
3186         Avoid decoding images twice in texImage2D
3187         https://bugs.webkit.org/show_bug.cgi?id=51498
3188
3189         Make sure to redecode the image only if it's not opaque and texImage2D
3190         wouldn't premultiply it anyway.
3191
3192         * platform/graphics/BitmapImage.h:
3193         * platform/graphics/cg/GraphicsContext3DCG.cpp:
3194         (WebCore::GraphicsContext3D::getImageData):
3195         * platform/graphics/skia/GraphicsContext3DSkia.cpp:
3196         (WebCore::GraphicsContext3D::getImageData):
3197
3198 2011-04-01  Alexey Proskuryakov  <ap@apple.com>
3199
3200         32-bit Mac build fix.
3201
3202         * dom/KeyboardEvent.h: (WebCore::KeypressCommand::KeypressCommand): Use 0U to index a String
3203         to avoid ambiguity.
3204
3205 2011-04-01  Alexey Proskuryakov  <ap@apple.com>
3206
3207         Reviewed by Darin Adler.
3208
3209         Make WebKit2 text input handling more like WebKit1
3210         https://bugs.webkit.org/show_bug.cgi?id=57649
3211
3212         * dom/KeyboardEvent.h: (WebCore::KeypressCommand::KeypressCommand): Put back the assertions
3213         we used to have. It is dangerous to confuse editor commands and selector names - besides the
3214         presence of a semicolon, they sometimes have different names, and WebKit2 failed to map those.
3215
3216 2011-04-01  Sheriff Bot  <webkit.review.bot@gmail.com>
3217
3218         Unreviewed, rolling out r82711.
3219         http://trac.webkit.org/changeset/82711
3220         https://bugs.webkit.org/show_bug.cgi?id=57657
3221
3222         Made every test crash on XP and Win7 (Requested by
3223         abarth|gardening on #webkit).
3224
3225         * loader/cache/CachedResource.cpp:
3226         (WebCore::CachedResource::canUseCacheValidator):
3227         * platform/network/ResourceResponseBase.cpp:
3228         (WebCore::ResourceResponseBase::adopt):
3229         (WebCore::ResourceResponseBase::isHTTP):
3230         (WebCore::ResourceResponseBase::url):
3231         (WebCore::ResourceResponseBase::setURL):
3232         (WebCore::ResourceResponseBase::mimeType):
3233         (WebCore::ResourceResponseBase::setMimeType):
3234         (WebCore::ResourceResponseBase::expectedContentLength):
3235         (WebCore::ResourceResponseBase::setExpectedContentLength):
3236         (WebCore::ResourceResponseBase::textEncodingName):
3237         (WebCore::ResourceResponseBase::setTextEncodingName):
3238         (WebCore::ResourceResponseBase::suggestedFilename):
3239         (WebCore::ResourceResponseBase::setSuggestedFilename):
3240         (WebCore::ResourceResponseBase::httpStatusCode):
3241         (WebCore::ResourceResponseBase::setHTTPStatusCode):
3242         (WebCore::ResourceResponseBase::httpStatusText):
3243         (WebCore::ResourceResponseBase::setHTTPStatusText):
3244         (WebCore::ResourceResponseBase::httpHeaderField):
3245         (WebCore::ResourceResponseBase::setHTTPHeaderField):
3246         (WebCore::ResourceResponseBase::httpHeaderFields):
3247         (WebCore::ResourceResponseBase::parseCacheControlDirectives):
3248         (WebCore::ResourceResponseBase::date):
3249         (WebCore::ResourceResponseBase::age):
3250         (WebCore::ResourceResponseBase::expires):
3251         (WebCore::ResourceResponseBase::lastModified):
3252         (WebCore::ResourceResponseBase::isAttachment):
3253         (WebCore::ResourceResponseBase::setLastModifiedDate):
3254         (WebCore::ResourceResponseBase::lastModifiedDate):
3255         (WebCore::ResourceResponseBase::wasCached):
3256         (WebCore::ResourceResponseBase::connectionReused):
3257         (WebCore::ResourceResponseBase::setConnectionReused):
3258         (WebCore::ResourceResponseBase::connectionID):
3259         (WebCore::ResourceResponseBase::setConnectionID):
3260         (WebCore::ResourceResponseBase::resourceLoadTiming):
3261         (WebCore::ResourceResponseBase::setResourceLoadTiming):
3262         (WebCore::ResourceResponseBase::resourceLoadInfo):
3263         (WebCore::ResourceResponseBase::setResourceLoadInfo):
3264         (WebCore::ResourceResponseBase::lazyInit):
3265         * platform/network/ResourceResponseBase.h:
3266         (WebCore::ResourceResponseBase::platformLazyInit):
3267         * platform/network/cf/ResourceResponse.h:
3268         (WebCore::ResourceResponse::ResourceResponse):
3269         (WebCore::ResourceResponse::memoryUsage):
3270         * platform/network/cf/ResourceResponseCFNet.cpp:
3271         (WebCore::ResourceResponse::platformLazyInit):
3272         * platform/network/mac/ResourceResponseMac.mm:
3273         (WebCore::ResourceResponse::platformLazyInit):
3274
3275 2011-04-01  Matthew Delaney  <mdelaney@apple.com>
3276
3277         Reviewed by Simon Fraser.
3278
3279         Behavior of isAccelerated() for a IOSurface-backed canvas should be consistent with accelerated status of its ImageBuffer
3280         https://bugs.webkit.org/show_bug.cgi?id=57651
3281
3282         No new tests. This patch does not affect outward behavior.
3283
3284         * html/canvas/CanvasRenderingContext2D.cpp:
3285         (WebCore::CanvasRenderingContext2D::isAccelerated):
3286         * platform/graphics/ImageBuffer.h:
3287         (WebCore::ImageBuffer::isAccelerated):
3288
3289 2011-04-01  Daniel Bates  <dbates@rim.com>
3290
3291         Reviewed by Darin Adler.
3292
3293         Frame's noResize attribute can not be set by JavaScript
3294         https://bugs.webkit.org/show_bug.cgi?id=14845
3295
3296         Tests: fast/frames/frame-inherit-noresize-from-frameset.html
3297                fast/frames/frame-programmatic-noresize.html
3298                fast/frames/frame-with-noresize-can-be-resized-after-removal-of-noresize.html
3299                fast/frames/frame-with-noresize-can-be-resized-after-setting-noResize-to-false.html
3300
3301         Implements support to programmatically allow and disallow frame resizing.
3302
3303         Currently, HTMLFrameElement::parseMappedAttribute() is hardcoded to disallow frame resize (i.e.
3304         m_noResize = true) when either the noresize DOM attribute is specified (or existed at some
3305         point in time) or the value of the noResize attribute is modified. Instead we should allow/disallow
3306         frame resize depending on the presence of the noresize DOM attribute/the value of the noResize
3307         attribute.
3308
3309         * html/HTMLFrameElement.cpp:
3310         (WebCore::HTMLFrameElement::HTMLFrameElement):
3311         (WebCore::HTMLFrameElement::noResize): Made this a non-inline function since this
3312         code path isn't performance critical.
3313         (WebCore::HTMLFrameElement::attach): Removed code to inherit noresize attribute from
3314         parent <frameset> since this functionality is part of RenderFrameSet::computeEdgeInfo().
3315         (WebCore::HTMLFrameElement::parseMappedAttribute):
3316         * html/HTMLFrameElement.h:
3317         * rendering/RenderFrame.cpp:
3318         (WebCore::RenderFrame::updateFromElement): Added.
3319         * rendering/RenderFrame.h:
3320         * rendering/RenderFrameSet.cpp:
3321         (WebCore::RenderFrameSet::notifyFrameEdgeInfoChanged): Added.
3322         * rendering/RenderFrameSet.h:
3323
3324 2011-04-01  Michael Saboff  <msaboff@apple.com>
3325
3326         Reviewed by Darin Adler.
3327
3328         Cached Resource Overhead Space Usage and Accounting Inaccurate
3329         https://bugs.webkit.org/show_bug.cgi?id=57488
3330
3331         Changed the fixed overhead value for ResourceResponse to 3800 bytes.
3332         Modified ResourceResponse::platformLazyInit() to handle "base" level
3333         attributes or all attributes.  The base attributes, like URL, status
3334         code, mime type and a few header fields (mostly cache related) are
3335         suitable for most resources.  This reduces the per resource memory
3336         needs by over 1K bytes per resource thus saving memory in the cache.
3337         Collectively, these two changes bring the overhead memory calculation
3338         in line with reality.
3339
3340         No new tests added due to existing tests cover areas of change and
3341         there is no functional change.  The change is limited to reducing 
3342         memory usage along existing paths.
3343
3344         * loader/cache/CachedResource.cpp:
3345         (WebCore::CachedResource::canUseCacheValidator):
3346         * platform/network/ResourceResponseBase.cpp:
3347         (WebCore::ResourceResponseBase::isHTTP):
3348         (WebCore::ResourceResponseBase::url):
3349         (WebCore::ResourceResponseBase::setURL):
3350         (WebCore::ResourceResponseBase::mimeType):
3351         (WebCore::ResourceResponseBase::setMimeType):
3352         (WebCore::ResourceResponseBase::expectedContentLength):
3353         (WebCore::ResourceResponseBase::setExpectedContentLength):
3354         (WebCore::ResourceResponseBase::textEncodingName):
3355         (WebCore::ResourceResponseBase::setTextEncodingName):
3356         (WebCore::ResourceResponseBase::suggestedFilename):
3357         (WebCore::ResourceResponseBase::setSuggestedFilename):
3358         (WebCore::ResourceResponseBase::httpStatusCode):
3359         (WebCore::ResourceResponseBase::setHTTPStatusCode):
3360         (WebCore::ResourceResponseBase::httpHeaderField):
3361         (WebCore::ResourceResponseBase::setHTTPHeaderField):
3362         (WebCore::ResourceResponseBase::parseCacheControlDirectives):
3363         (WebCore::ResourceResponseBase::hasCacheValidatorFields):
3364         (WebCore::ResourceResponseBase::date):
3365         (WebCore::ResourceResponseBase::age):
3366         (WebCore::ResourceResponseBase::expires):
3367         (WebCore::ResourceResponseBase::lastModified):
3368         (WebCore::ResourceResponseBase::lazyInit):
3369         * platform/network/ResourceResponseBase.h:
3370         (WebCore::ResourceResponseBase::platformLazyInit):
3371         * platform/network/cf/ResourceResponse.h:
3372         (WebCore::ResourceResponse::ResourceResponse):
3373         (WebCore::ResourceResponse::memoryUsage):
3374         * platform/network/cf/ResourceResponseCFNet.cpp:
3375         * platform/network/mac/ResourceResponseMac.mm:
3376         (WebCore::ResourceResponse::platformLazyInit):
3377
3378 2011-04-01  Timothy Hatcher  <timothy@apple.com>
3379
3380         Make momentum scroll event latching work in WebKit2 on Mac.
3381
3382         <rdar://problem/8751861>
3383
3384         Reviewed by Darin Adler.
3385
3386         * WebCore.exp.in: Remove _wkIsLatchingWheelEvent, add _wkGetNSEventMomentumPhase.
3387         * page/EventHandler.cpp:
3388         (WebCore::EventHandler::handleWheelEvent): Set m_useLatchedWheelEventNode based on the
3389         event's momentumPhase.
3390         * page/mac/EventHandlerMac.mm:
3391         (WebCore::EventHandler::wheelEvent): Remove the setting of m_useLatchedWheelEventNode.
3392         It is now done in EventHandler::handleWheelEvent.
3393         * platform/mac/WebCoreSystemInterface.h: Remove wkIsLatchingWheelEvent, add wkGetNSEventMomentumPhase.
3394         * platform/mac/WebCoreSystemInterface.mm: Ditto.
3395         * platform/mac/WheelEventMac.mm:
3396         (WebCore::momentumPhaseForEvent): Return a phase on older Mac system by using wkGetNSEventMomentumPhase.
3397
3398 2011-04-01  Steve Block  <steveblock@google.com>
3399
3400         Reviewed by Jeremy Orlow.
3401
3402         JavaClass should be an interface and free of JNI types
3403         https://bugs.webkit.org/show_bug.cgi?id=57533
3404
3405         This patch fixes JavaClass for V8 only.
3406
3407         It factors out a JavaClass interface which does not use JNI types.
3408         This will allow the Java bridge to be used with objects that
3409         don't use JNI directly. The existing jobject-backed
3410         implementation is moved to a new JavaClassJobject class which
3411         implements the interface.
3412
3413         No new tests, refactoring only.
3414
3415         * Android.v8bindings.mk:
3416         * WebCore.gypi:
3417         * bridge/jni/v8/JavaClassJobjectV8.cpp:
3418         (JavaClassJobject::JavaClassJobject):
3419         (JavaClassJobject::~JavaClassJobject):
3420         (JavaClassJobject::methodsNamed):
3421         (JavaClassJobject::fieldNamed):
3422         * bridge/jni/v8/JavaClassJobjectV8.h: Copied from Source/WebCore/bridge/jni/v8/JavaClassV8.h.
3423         * bridge/jni/v8/JavaClassV8.h:
3424         (JSC::Bindings::JavaClass::~JavaClass):
3425         * bridge/jni/v8/JavaInstanceV8.cpp:
3426         (JavaInstance::getClass):
3427
3428 2011-04-01  Jaehun Lim  <ljaehun.lim@samsung.com>
3429
3430         Unreviewed build fix.
3431
3432         Fix build break when font backend is Pango.
3433         Pango is missed in changeset 80589.
3434
3435         https://bugs.webkit.org/show_bug.cgi?id=57609
3436
3437         * platform/graphics/pango/FontPlatformData.h:
3438         (WebCore::FontPlatformData::setOrientation):
3439
3440 2011-04-01  Sheriff Bot  <webkit.review.bot@gmail.com>
3441
3442         Unreviewed, rolling out r82687.
3443         http://trac.webkit.org/changeset/82687
3444         https://bugs.webkit.org/show_bug.cgi?id=57643
3445
3446         This patch broke accessibility aria-treegrid test in Mac
3447         (Requested by msanchez on #webkit).
3448
3449         * accessibility/AccessibilityARIAGrid.cpp:
3450         * accessibility/AccessibilityARIAGrid.h:
3451         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
3452         (atkRole):
3453         * accessibility/mac/AccessibilityObjectWrapper.mm:
3454
3455 2011-03-31  Abhishek Arya  <inferno@chromium.org>
3456
3457         Reviewed by Andreas Kling.
3458
3459         Whenever a relayout is trigger for SVGPath, make sure
3460         to clear its previous marker layout info. This helps
3461         to prevent removed markers from being used.
3462         https://bugs.webkit.org/show_bug.cgi?id=57492
3463
3464         Test: svg/dom/path-marker-removed-crash.svg
3465
3466         * rendering/svg/RenderSVGPath.cpp:
3467         (WebCore::RenderSVGPath::layout):
3468         * rendering/svg/SVGMarkerLayoutInfo.cpp:
3469         (WebCore::SVGMarkerLayoutInfo::clear):
3470         * rendering/svg/SVGMarkerLayoutInfo.h:
3471
3472 2011-04-01  Rob Buis  <rwlbuis@gmail.com>
3473
3474         Reviewed by Nikolas Zimmermann.
3475
3476         https://bugs.webkit.org/show_bug.cgi?id=55750
3477         SVG <image> referenced by <use> is displayed incorrectly
3478
3479         Reintroduce old behaviour for valid base URI, for invalid
3480         keep using document base URI.
3481         Fixes regression of W3C-SVG-1.1/struct-image-07-t.svg.
3482
3483         Test: svg/custom/image-base-uri.svg
3484
3485         * svg/SVGImageLoader.cpp:
3486         (WebCore::SVGImageLoader::sourceURI):
3487
3488 2011-04-01  Mario Sanchez Prada  <msanchez@igalia.com>
3489
3490         Reviewed by Chris Fleizach.
3491
3492         ARIA Grid tables should return GridRole in roleValue() method
3493         https://bugs.webkit.org/show_bug.cgi?id=57614
3494
3495         This change does not need any test since it doesn't change anything
3496         from the point of view of the consumers (Assistive Technoglogies).
3497         It's just an internal change to simplify identifying HTML and ARIA
3498         tables by calling to the AccessibilityObject::roleValue method.
3499
3500         * accessibility/AccessibilityARIAGrid.h:
3501         * accessibility/AccessibilityARIAGrid.cpp:
3502         (WebCore::AccessibilityARIAGrid::roleValue): Return GridRole.
3503
3504         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
3505         (atkRole): Removed unneeded comment.
3506
3507         * accessibility/mac/AccessibilityObjectWrapper.mm: Map GridRole to
3508 &nb