Try to fix the Apple LLVM Compiler build after r88087.
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-06-03  Dan Bernstein  <mitz@apple.com>
2
3         Try to fix the Apple LLVM Compiler build after r88087.
4
5         * rendering/RenderTableCell.cpp:
6         (WebCore::RenderTableCell::paintMask):
7         * rendering/RenderTableCell.h:
8
9 2011-06-03  Chris Rogers  <crogers@google.com>
10
11         Unreviewed build fix.
12
13         Fix clang build - take 2
14         https://bugs.webkit.org/show_bug.cgi?id=62081
15
16         * webaudio/AudioParamTimeline.cpp:
17         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
18
19 2011-06-03  Chris Rogers  <crogers@google.com>
20
21         Unreviewed clang build fix.
22
23         Fix clang build
24         https://bugs.webkit.org/show_bug.cgi?id=62080
25
26         * webaudio/AudioParamTimeline.cpp:
27         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
28
29 2011-06-03  Levi Weintraub  <leviw@chromium.org>
30
31         Reviewed by Eric Seidel.
32
33         Switch paintMask and paintObject to use IntPoint
34         https://bugs.webkit.org/show_bug.cgi?id=62077
35
36         Switching paintMask and paintObject to use IntPoint for their paint offset instead of
37         a pair of ints. paintObject is still on tx/ty, but paintMask was converted to IntSize
38         passed by value -- bringing it in-line with the agreed-upon convention of a const IntPoint&.
39
40         No new tests since this is simple refactoring.
41
42         * rendering/RenderBlock.cpp:
43         (WebCore::RenderBlock::paint):
44         (WebCore::RenderBlock::paintObject):
45         * rendering/RenderBlock.h:
46         * rendering/RenderBox.cpp:
47         (WebCore::RenderBox::paintMask):
48         (WebCore::RenderBox::pushContentsClip):
49         (WebCore::RenderBox::popContentsClip):
50         * rendering/RenderBox.h:
51         (WebCore::RenderBox::paintObject):
52         * rendering/RenderFieldset.cpp:
53         (WebCore::RenderFieldset::paintMask):
54         * rendering/RenderFieldset.h:
55         * rendering/RenderFileUploadControl.cpp:
56         (WebCore::RenderFileUploadControl::paintObject):
57         * rendering/RenderFileUploadControl.h:
58         * rendering/RenderListBox.cpp:
59         (WebCore::RenderListBox::paintObject):
60         * rendering/RenderListBox.h:
61         * rendering/RenderReplaced.cpp:
62         (WebCore::RenderReplaced::paint):
63         * rendering/RenderReplica.cpp:
64         (WebCore::RenderReplica::paint):
65         * rendering/RenderTable.cpp:
66         (WebCore::RenderTable::paint):
67         (WebCore::RenderTable::paintObject):
68         (WebCore::RenderTable::paintMask):
69         * rendering/RenderTable.h:
70         * rendering/RenderTableSection.cpp:
71         (WebCore::RenderTableSection::paint):
72         (WebCore::RenderTableSection::paintObject):
73         * rendering/RenderTableSection.h:
74         * rendering/RenderTextControl.cpp:
75         (WebCore::RenderTextControl::paintPlaceholder):
76         (WebCore::RenderTextControl::paintObject):
77         * rendering/RenderTextControl.h:
78         * rendering/RenderView.cpp:
79         (WebCore::RenderView::paint):
80         * rendering/RenderWidget.cpp:
81         (WebCore::RenderWidget::paint):
82
83 2011-06-03  Cary Clark  <caryclark@google.com>
84
85         Reviewed by Eric Seidel.
86
87         Support FontCustomPlatformData on Skia-Mac-Chrome variant
88         https://bugs.webkit.org/show_bug.cgi?id=62040
89
90         Canvas text is only recognized by Skia if it is registered
91         by creating a new SkTypeface. Skia uses CGFont to measure
92         and render the glyphs, then takes care of managing the glyph
93         cache.
94
95         Skia on Mac Chrome is not yet enabled, so this change
96         does not affect existing code, and requires no new tests.
97
98         * platform/graphics/mac/FontCustomPlatformData.cpp:
99         (WebCore::RemoteFontStream::RemoteFontStream):
100         (WebCore::RemoteFontStream::~RemoteFontStream):
101         (WebCore::RemoteFontStream::rewind):
102         (WebCore::RemoteFontStream::read):
103         Turn the buffer into a stream. This is identical to
104         the implementation in skia/FontCustomPlatformData.cpp.
105         While that file could be modified instead of this one,
106         it was simpler to add SkTypeface streaming to this instead
107         of adding all CGFont support to the skia platform file.
108
109         (WebCore::FontCustomPlatformData::~FontCustomPlatformData):
110         Release the SkTypeface reference.
111
112         (WebCore::createFontCustomPlatformData):
113         Associate the buffer stream with a SkTypeface so Skia
114         can find the custom font data.
115
116         * platform/graphics/mac/FontCustomPlatformData.h:
117         (WebCore::FontCustomPlatformData::FontCustomPlatformData):
118         Add a slot to hold the SkTypeface.
119
120 2011-06-03  Steve Falkenburg  <sfalken@apple.com>
121
122         Reviewed by Brian Weinstein.
123
124         HistoryItem children persist across page loads
125         https://bugs.webkit.org/show_bug.cgi?id=62071
126         <rdar://problem/9552129>
127         
128         Not testable since there's no way to check for the presence/absence
129         of children for a HistoryItem.
130
131         * history/HistoryItem.cpp:
132         (WebCore::HistoryItem::reset): Call clearChildren when we're reusing a HistoryItem.
133
134 2011-06-03  Chris Rogers  <crogers@google.com>
135
136         Reviewed by Kenneth Russell.
137
138         Allow existing AudioParams to use scheduled parameter changes
139         https://bugs.webkit.org/show_bug.cgi?id=62046
140
141         No new tests since audio API is not yet implemented.
142
143         * platform/audio/AudioBus.cpp:
144         (WebCore::AudioBus::processWithGainFrom):
145         (WebCore::AudioBus::copyWithSampleAccurateGainValuesFrom):
146         * platform/audio/AudioBus.h:
147         * webaudio/AudioBufferSourceNode.cpp:
148         (WebCore::AudioBufferSourceNode::AudioBufferSourceNode):
149         * webaudio/AudioGainNode.cpp:
150         (WebCore::AudioGainNode::AudioGainNode):
151         (WebCore::AudioGainNode::process):
152         * webaudio/AudioGainNode.h:
153         * webaudio/HighPass2FilterNode.cpp:
154         (WebCore::HighPass2FilterNode::HighPass2FilterNode):
155         * webaudio/LowPass2FilterNode.cpp:
156         (WebCore::LowPass2FilterNode::LowPass2FilterNode):
157
158 2011-06-03  Chris Rogers  <crogers@google.com>
159
160         Reviewed by Kenneth Russell.
161
162         Biquad filter coefficient naming is incorrect
163         https://bugs.webkit.org/show_bug.cgi?id=62053
164
165         No new tests since audio API is not yet implemented.
166
167         * platform/audio/Biquad.cpp:
168         (WebCore::Biquad::Biquad):
169         (WebCore::Biquad::process):
170         (WebCore::Biquad::processFast):
171         (WebCore::Biquad::setLowpassParams):
172         (WebCore::Biquad::setHighpassParams):
173         (WebCore::Biquad::setLowShelfParams):
174         (WebCore::Biquad::setZeroPolePairs):
175         * platform/audio/Biquad.h:
176
177 2011-06-03  Adam Barth  <abarth@webkit.org>
178
179         Reviewed by Eric Seidel.
180
181         DOMWindow::setLocation doesn't understand that DOMWindow can be inactive
182         https://bugs.webkit.org/show_bug.cgi?id=62057
183
184         This code gets confused when dealing with inactive DOMWindows.  We
185         should just block inactive DOMWindows because there's no compatibility
186         reason to support them in this code path.
187
188         Test: http/tests/security/xss-DENIED-contentWindow-eval.html
189
190         * page/DOMWindow.cpp:
191         (WebCore::DOMWindow::isInsecureScriptAccess):
192
193 2011-05-31  Martin Robinson  <mrobinson@igalia.com>
194
195         Reviewed by Ryosuke Niwa.
196
197         [GTK] Support smart replace for the pasteboard
198         https://bugs.webkit.org/show_bug.cgi?id=61734
199
200         Add smart replace support to WebCore and add hooks for it in WebKit
201         via DumpRenderTreeSupportGtk. When a platform supports smart replace,
202         WebCore will remove extra spaces that appear when pasting text. Eventually
203         WebKitGTK+ may want to expose this in the public API.
204
205         * platform/gtk/PasteboardGtk.cpp:
206         (WebCore::Pasteboard::writeSelection): Now pass whether or not to use smart replace
207         when calling writeSelection.
208         (WebCore::Pasteboard::canSmartReplace): Added an implementation that checks the clipboard
209         for whether or not it supports smart paste.
210         * platform/gtk/PasteboardHelper.cpp:
211         (WebCore::initGdkAtoms): Added initialization for smart replace atom.
212         (WebCore::PasteboardHelper::fillSelectionData): Added no-op handler for smart replace atom.
213         (WebCore::PasteboardHelper::targetListForDataObject): Properly handle new smart replace parameter.
214         (WebCore::PasteboardHelper::writeClipboardContents): Properly handle new smart replace parameter.
215         (WebCore::PasteboardHelper::clipboardContentSupportsSmartReplace): Added helper for Pasteboard.
216         * platform/gtk/PasteboardHelper.h: Add new method definition.
217
218 2011-06-03  Levi Weintraub  <leviw@chromium.org>
219
220         Reviewed by Eric Seidel.
221
222         Switch paintCell to use IntPoint
223         https://bugs.webkit.org/show_bug.cgi?id=62033
224
225         Switching paintCell to take an IntPoint representing the paint offset
226         instead of a pair of ints.
227
228         No new tests since this is simple refactoring.
229
230         * rendering/RenderTableSection.cpp:
231         (WebCore::RenderTableSection::paintCell):
232         (WebCore::RenderTableSection::paintObject):
233         * rendering/RenderTableSection.h:
234
235 2011-06-03  Martin Robinson  <mrobinson@igalia.com>
236
237         Reviewed by Dimitri Glazkov.
238
239         Teach Gtk build about window.internals
240         https://bugs.webkit.org/show_bug.cgi?id=61071
241
242         * GNUmakefile.am: Add new internals directories to the VPATH
243         (for idl processing) and the include list.
244
245 2011-06-03  Levi Weintraub  <leviw@chromium.org>
246
247         Reviewed by Eric Seidel.
248
249         Switch paintBackgroundsBehindCell to use IntPoint
250         https://bugs.webkit.org/show_bug.cgi?id=62031
251
252         Switching paintBackgroundsBehindCell to take an IntPoint representing
253         the paint offset instead of a pair of ints.
254
255         No new tests as this is simple refactoring.
256
257         * rendering/RenderTableCell.cpp:
258         (WebCore::RenderTableCell::paintBackgroundsBehindCell):
259         (WebCore::RenderTableCell::paintBoxDecorations):
260         * rendering/RenderTableCell.h:
261         * rendering/RenderTableRow.cpp:
262         (WebCore::RenderTableRow::paint):
263         * rendering/RenderTableSection.cpp:
264         (WebCore::RenderTableSection::paintCell):
265
266 2011-06-03  Levi Weintraub  <leviw@chromium.org>
267
268         Reviewed by Eric Seidel.
269
270         Switch paintCaret and paintDragCaret to use IntPoint
271         https://bugs.webkit.org/show_bug.cgi?id=62037
272
273         Switching paintCaret and paintDragCaret to use an IntPoint representing
274         the paint offset instead of a pair of ints.
275
276         No new tests since this is simple refactoring.
277
278         * editing/FrameSelection.cpp:
279         (WebCore::FrameSelection::paintCaret):
280         (WebCore::CaretBase::paintCaret):
281         (WebCore::DragCaretController::paintDragCaret):
282         * editing/FrameSelection.h:
283         * rendering/RenderBlock.cpp:
284         (WebCore::RenderBlock::paintCaret):
285         (WebCore::RenderBlock::paintObject):
286         (WebCore::RenderBlock::positionForPoint):
287         (WebCore::RenderBlock::offsetForContents):
288         * rendering/RenderBlock.h:
289
290 2011-06-03  Levi Weintraub  <leviw@chromium.org>
291
292         Reviewed by Eric Seidel.
293
294         Switch paintItemForeground and paintItemForeground to use IntPoint
295         https://bugs.webkit.org/show_bug.cgi?id=62035
296
297         Switching paintItemFore/Background to use IntPoint instead of a pair of ints.
298
299         No new tests since this is simple refactoring.
300
301         * rendering/RenderListBox.cpp:
302         (WebCore::RenderListBox::paintObject):
303         (WebCore::RenderListBox::paintItemForeground):
304         (WebCore::RenderListBox::paintItemBackground):
305         * rendering/RenderListBox.h:
306
307 2011-06-03  Alexis Menard  <alexis.menard@openbossa.org>
308
309         Reviewed by Andreas Kling.
310
311         To support building namespaced Qt, we require that forward-declarations
312         of Qt classes be wrapped in QT_BEGIN_NAMESPACE and QT_END_NAMESPACE.
313
314         * platform/network/qt/QtMIMETypeSniffer.h:
315
316 2011-06-03  Rob Buis  <rbuis@rim.com>
317
318         Reviewed by Nikolas Zimmermann.
319
320         Cleanup member variable usage in svg/animation classes
321         https://bugs.webkit.org/show_bug.cgi?id=62029
322
323         Cleanup member variables.
324
325         * svg/animation/SMILTimeContainer.cpp:
326         (WebCore::SMILTimeContainer::SMILTimeContainer):
327         (WebCore::SMILTimeContainer::sampleAnimationAtTime):
328         (WebCore::SMILTimeContainer::updateAnimations):
329         * svg/animation/SMILTimeContainer.h:
330         * svg/animation/SVGSMILElement.cpp:
331         (WebCore::SVGSMILElement::SVGSMILElement):
332         * svg/animation/SVGSMILElement.h:
333
334 2011-06-03  Chris Rogers  <crogers@google.com>
335
336         Reviewed by Kenneth Russell.
337
338         Add AudioParam parameter scheduling implementation
339         https://bugs.webkit.org/show_bug.cgi?id=61830
340
341         No new tests since audio API is not yet implemented.
342
343         * WebCore.gypi:
344         * WebCore.xcodeproj/project.pbxproj:
345         * webaudio/AudioParam.cpp:
346         (WebCore::AudioParam::value):
347         (WebCore::AudioParam::smoothedValue):
348         (WebCore::AudioParam::smooth):
349         (WebCore::AudioParam::calculateSampleAccurateValues):
350         * webaudio/AudioParam.h:
351         (WebCore::AudioParam::setContext):
352         (WebCore::AudioParam::context):
353         (WebCore::AudioParam::setValueAtTime):
354         (WebCore::AudioParam::linearRampToValueAtTime):
355         (WebCore::AudioParam::exponentialRampToValueAtTime):
356         (WebCore::AudioParam::setTargetValueAtTime):
357         (WebCore::AudioParam::setValueCurveAtTime):
358         (WebCore::AudioParam::cancelScheduledValues):
359         (WebCore::AudioParam::hasTimelineValues):
360         * webaudio/AudioParam.idl:
361         * webaudio/AudioParamTimeline.cpp: Added.
362         (WebCore::AudioParamTimeline::setValueAtTime):
363         (WebCore::AudioParamTimeline::linearRampToValueAtTime):
364         (WebCore::AudioParamTimeline::exponentialRampToValueAtTime):
365         (WebCore::AudioParamTimeline::setTargetValueAtTime):
366         (WebCore::AudioParamTimeline::setValueCurveAtTime):
367         (WebCore::isValidNumber):
368         (WebCore::AudioParamTimeline::insertEvent):
369         (WebCore::AudioParamTimeline::cancelScheduledValues):
370         (WebCore::AudioParamTimeline::valueForContextTime):
371         (WebCore::AudioParamTimeline::valuesForTimeRange):
372         (WebCore::timeToSampleFrame):
373         (WebCore::AudioParamTimeline::valuesForTimeRangeImpl):
374         * webaudio/AudioParamTimeline.h: Added.
375         (WebCore::AudioParamTimeline::AudioParamTimeline):
376         (WebCore::AudioParamTimeline::hasValues):
377         (WebCore::AudioParamTimeline::ParamEvent::ParamEvent):
378         (WebCore::AudioParamTimeline::ParamEvent::type):
379         (WebCore::AudioParamTimeline::ParamEvent::value):
380         (WebCore::AudioParamTimeline::ParamEvent::time):
381         (WebCore::AudioParamTimeline::ParamEvent::timeConstant):
382         (WebCore::AudioParamTimeline::ParamEvent::duration):
383         (WebCore::AudioParamTimeline::ParamEvent::curve):
384
385 2011-06-01  Jer Noble  <jer.noble@apple.com>
386
387         Reviewed by Simon Fraser.
388
389         Flash of broken page when exiting full screen at jerryseinfeld.com
390         https://bugs.webkit.org/show_bug.cgi?id=61897
391         <rdar://problem/9522985>
392
393         Test: fullscreen/full-screen-placeholder.html
394
395         Entering full-screen mode is causing the page layout to change because the full-screen
396         element is taken out of the normal flow.  To counteract this effect, insert a placeholder
397         block as a parent of the full-screen renderer with the same size and style as the full-screen
398         element pre-full-screen.
399
400         Only create a placeholder for block-level elements; the technique required for inline elements
401         would be vastly more complicated.
402
403         * dom/Document.cpp:
404         (WebCore::Document::webkitWillEnterFullScreenForElement): Create a placeholder
405             based on the size and style of the full-screen element.
406         (WebCore::Document::setFullScreenRenderer): Persist the placeholder size and 
407             style across new renderers.
408         * rendering/RenderFullScreen.cpp:
409         (RenderFullScreen::RenderFullScreen): Added ivar.
410         (RenderFullScreen::destroy): Make sure to safely destroy our placeholder.
411         (RenderFullScreen::createPlaceholder): Added.
412         * rendering/RenderFullScreen.h:
413         (WebCore::RenderFullScreen::placeholder): Ivar accessor.
414
415 2011-06-03  Levi Weintraub  <leviw@chromium.org>
416
417         Reviewed by Eric Seidel.
418
419         Switch paintBoxDecorations to IntPoint
420         https://bugs.webkit.org/show_bug.cgi?id=61968
421
422         Switching paintBoxDecorations to take an IntPoint representing
423         the paint offset instead of a pair of ints. Also cleaning up
424         some duplicated code in InlineFlowBox related to constraining
425         the paint rect to the linetop and linebottom.
426
427         No new tests since this is just refactoring.
428
429         * rendering/InlineFlowBox.cpp:
430         (WebCore::InlineFlowBox::paint):
431         (WebCore::InlineFlowBox::constrainToLineTopAndBottomIfNeeded): Added
432         to remove duplicate code in paintBoxDecorations and paintMask.
433         (WebCore::InlineFlowBox::paintBoxDecorations):
434         (WebCore::InlineFlowBox::paintMask):
435         * rendering/InlineFlowBox.h:
436         * rendering/RenderBlock.cpp:
437         (WebCore::RenderBlock::paintObject):
438         * rendering/RenderBox.cpp:
439         (WebCore::RenderBox::paintBoxDecorations):
440         * rendering/RenderBox.h:
441         * rendering/RenderFieldset.cpp:
442         (WebCore::RenderFieldset::paintBoxDecorations):
443         * rendering/RenderFieldset.h:
444         * rendering/RenderReplaced.cpp:
445         (WebCore::RenderReplaced::paint):
446         * rendering/RenderTable.cpp:
447         (WebCore::RenderTable::paintObject):
448         (WebCore::RenderTable::paintBoxDecorations):
449         * rendering/RenderTable.h:
450         * rendering/RenderTableCell.cpp:
451         (WebCore::RenderTableCell::paintBoxDecorations):
452         * rendering/RenderTableCell.h:
453         * rendering/RenderView.cpp:
454         (WebCore::RenderView::paintBoxDecorations):
455         * rendering/RenderView.h:
456         * rendering/RenderWidget.cpp:
457         (WebCore::RenderWidget::paint):
458         * rendering/svg/RenderSVGRoot.cpp:
459         (WebCore::RenderSVGRoot::paint):
460
461 2011-06-03  Doreen Jiang  <doreen.jiang@nokia.com>
462
463         Reviewed by Benjamin Poulain.
464
465         [Qt]The minimum size of the select menu list is incorrect for qtwebkit
466         https://bugs.webkit.org/show_bug.cgi?id=56752
467
468         The minimum width of the select-box is calculated to be as small as possible 
469         instead of hardcoded value (width of 7 characters) in minimumMenuListSize() function
470         This will avoid overapping the select lists in popular websites.
471
472         Test: fast/forms/selectlist-minsize.html
473
474         * platform/qt/RenderThemeQt.cpp:
475         (WebCore::RenderThemeQt::minimumMenuListSize):
476
477 2011-06-02  Dimitri Glazkov  <dglazkov@chromium.org>
478
479         Reviewed by Darin Adler.
480
481         Prevent event dispatch for events with related target when host is the target.
482         https://bugs.webkit.org/show_bug.cgi?id=61979
483
484         Turns out, even if we trim the ancestor chain to 0, the event is still dispatched during AT_TARGET.
485         So might as well be explicit about what we are trying to do and add a flag to prevent dispatch in these cases.
486
487         * dom/EventDispatcher.cpp:
488         (WebCore::EventDispatcher::adjustToShadowBoundaries): Added preventing dispatch when the ancestor chain is trimmed to nothing.
489         (WebCore::EventDispatcher::EventDispatcher): Added initializer.
490         (WebCore::EventDispatcher::dispatchEvent): Added a check to prevent dispatch.
491         * dom/EventDispatcher.h: Added a def.
492
493 2011-06-03  Dan Bernstein  <mitz@apple.com>
494
495         Mac build fix.
496
497         * WebCore.xcodeproj/project.pbxproj:
498
499 2011-06-03  Naoki Takano  <takano.naoki@gmail.com>
500
501         Reviewed by Eric Seidel.
502
503         [Chromium] Call setToolTipText() in WebPopupMenuImpl mouse move handler to show tool tip in select popup window.
504         https://bugs.webkit.org/show_bug.cgi?id=61260
505         http://code.google.com/p/chromium/issues/detail?id=12721
506
507         Manual test: select-popup-tooltip-test.html
508
509         * manual-tests/select-popup-tooltip-test.html: Added.
510         * platform/chromium/PopupMenuChromium.cpp:
511         (WebCore::PopupContainer::getSelectedItemToolTip): Get selected item tooltip string according to hovering mouse position.
512         * platform/chromium/PopupMenuChromium.h: Add getSelectedItemToolTip() declaration.
513
514 2011-06-03  Rob Buis  <rbuis@rim.com>
515
516         Reviewed by Nikolas Zimmermann.
517
518         Creating <animateMotion> elements via javascript do not execute
519         https://bugs.webkit.org/show_bug.cgi?id=34301
520
521         Enable constructors for SVGMPathElement and SVGAnimateMotionElement.
522
523         * DerivedSources.cpp:
524         * DerivedSources.make:
525         * GNUmakefile.list.am:
526         * WebCore.gypi:
527         * WebCore.vcproj/WebCore.vcproj:
528         * WebCore.xcodeproj/project.pbxproj:
529         * page/DOMWindow.idl:
530
531 2011-06-03  Hans Wennborg  <hans@chromium.org>
532
533         Reviewed by Steve Block.
534
535         IndexedDB: Clean-up use of INT64_MAX in LevelDB back-end
536         https://bugs.webkit.org/show_bug.cgi?id=62009
537
538         This constant should only be needed inside IDBLevelDBCoding.cpp.
539
540         No new functionality, no new tests.
541
542         * storage/IDBLevelDBBackingStore.cpp:
543         (WebCore::getNewDatabaseId):
544         (WebCore::IDBLevelDBBackingStore::getObjectStores):
545         (WebCore::getNewObjectStoreId):
546         (WebCore::IDBLevelDBBackingStore::deleteObjectStore):
547         (WebCore::getNewIndexId):
548         * storage/IDBLevelDBCoding.cpp:
549         (WebCore::IDBLevelDBCoding::DatabaseFreeListKey::encodeMaxKey):
550         (WebCore::IDBLevelDBCoding::ObjectStoreMetaDataKey::encodeMaxKey):
551         (WebCore::IDBLevelDBCoding::IndexMetaDataKey::encodeMaxKey):
552         (WebCore::IDBLevelDBCoding::ObjectStoreFreeListKey::encodeMaxKey):
553         (WebCore::IDBLevelDBCoding::IndexFreeListKey::encodeMaxKey):
554         * storage/IDBLevelDBCoding.h:
555
556 2011-06-03  Siddharth Mathur  <siddharth.mathur@nokia.com>
557
558         Reviewed by Benjamin Poulain.
559
560         [Qt] Build flag for experimental ICU library support
561         https://bugs.webkit.org/show_bug.cgi?id=60786
562
563         Adds a build-time flag (CONFIG+=use_system_icu) that enables experimental 
564         ICU powered Unicode support. 
565
566         No new tests as no new features added.
567
568         * WebCore.pri: Removed text_breaking_with_icu CONFIG flag. 
569         * WebCore.pro: Added TextCodecICU.cpp and qt/TextBreakIteratorInternalICUQt.cpp.
570         * editing/qt/SmartReplaceQt.cpp:
571         * features.pri: Support for use_system_icu CONFIG flag.
572         * platform/text/TextCodecICU.cpp: Guard with USE(ICU_UNICODE). 
573         * platform/text/qt/TextBreakIteratorInternalICUQt.cpp: Added.
574         (WebCore::Q_GLOBAL_STATIC_WITH_INITIALIZER):
575         (WebCore::currentSearchLocaleID):
576         (WebCore::currentTextBreakLocaleID):
577         * platform/text/qt/TextBreakIteratorQt.cpp: Moved out currentTextBreakLocaleID(). 
578         (WebCore::isTextBreak):
579         * platform/text/qt/TextCodecQt.cpp: Guard with USE(QT4_UNICODE). 
580         (WebCore::TextCodecQt::registerEncodingNames):
581         (WebCore::TextCodecQt::registerCodecs):
582
583 2011-06-03  Yael Aharon  <yael.aharon@nokia.com>
584
585         Reviewed by Kenneth Rohde Christiansen.
586
587         Frame flattening is broken with nested frames
588         https://bugs.webkit.org/show_bug.cgi?id=61491
589
590         Do not flatten offscreen iframes during frame flattening, as flattening might make them visible.
591
592         Test: fast/frames/flattening/iframe-flattening-out-of-view.html
593               fast/frames/flattening/iframe-flattening-out-of-view-and-scroll.html
594               fast/frames/flattening/iframe-flattening-out-of-view-scroll-and-relayout.html
595
596         * rendering/RenderIFrame.cpp:
597         (WebCore::RenderIFrame::flattenFrame):
598
599 2011-06-03  Nikolas Zimmermann  <nzimmermann@rim.com>
600
601         Reviewed by Andreas Kling.
602
603         Incorrect embedded document replaced size calculation for box-sizing: border-box
604         https://bugs.webkit.org/show_bug.cgi?id=62007
605
606         When using <object style="box-sizing: border-box" data="foo.svg"/> to embed foo.svg
607         which has an intrinsic width/height, the embedded document intrinsic size is incorrect.
608
609         RenderPart::computeEmbeddedDocumentReplacedWidth/Height has to ask the content renderer for the replaced width/height not ourselves.
610
611         Tests: svg/as-image/img-preserveAspectRatio-support-2.html
612                svg/as-object/object-box-sizing-no-width-height.html
613
614         * rendering/RenderPart.cpp:
615         (WebCore::RenderPart::computeEmbeddedDocumentReplacedWidth):
616         (WebCore::RenderPart::computeEmbeddedDocumentReplacedHeight):
617
618 2011-06-03  Sheriff Bot  <webkit.review.bot@gmail.com>
619
620         Unreviewed, rolling out r88004.
621         http://trac.webkit.org/changeset/88004
622         https://bugs.webkit.org/show_bug.cgi?id=62008
623
624         This patch broke 4 tests in the GTK bots (Requested by
625         msanchez on #webkit).
626
627         * accessibility/gtk/AXObjectCacheAtk.cpp:
628         (WebCore::AXObjectCache::handleScrolledToAnchor):
629
630 2011-06-03  Nikolas Zimmermann  <nzimmermann@rim.com>
631
632         Reviewed by Andreas Kling.
633
634         Zooming <object style="width/height: auto" data="foo.svg"/> doesn't work as expected
635         https://bugs.webkit.org/show_bug.cgi?id=62005
636
637         Zooming an object with auto size, that references a svg with fixed size was broken. The svg size stayed the same.
638         Get rid of the dependency between RenderSVGRoot and SVGSVGElement::currentScale(), always ask for the effective
639         zoom in the RenderStyle instead of asking SVGSVGElement.
640
641         The SVGSVGElement::currentScale()/setCurrentScale() methods are now only used when called from the bindings (eg. JS).
642         They only take effect on the outermost <svg> element in standalone documents, otherwhise they are no-ops.
643
644         Test: svg/zoom/page/zoom-svg-through-object-with-auto-size.html
645
646         * rendering/svg/RenderSVGRoot.cpp:
647         (WebCore::RenderSVGRoot::computeIntrinsicWidth):
648         (WebCore::RenderSVGRoot::computeIntrinsicHeight):
649         (WebCore::RenderSVGRoot::localToBorderBoxTransform):
650         * svg/SVGSVGElement.cpp:
651         (WebCore::SVGSVGElement::SVGSVGElement):
652         (WebCore::SVGSVGElement::currentScale):
653         (WebCore::SVGSVGElement::setCurrentScale):
654         * svg/SVGSVGElement.h:
655
656 2011-06-03  Mario Sanchez Prada  <msanchez@igalia.com>
657
658         Reviewed by Martin Robinson.
659
660         Focus and caret position should be updated when same-page links are followed
661         https://bugs.webkit.org/show_bug.cgi?id=59737
662
663         Update the caret position to the anchor's position after scrolling.
664
665         This behavior is specific to the Gtk port and requested because of
666         accessibility needs, that's why it's implemented in AXObjectCache.
667
668         Test: platform/gtk/accessibility/caret-browsing-anchor-followed.html
669
670         * accessibility/gtk/AXObjectCacheAtk.cpp:
671         (WebCore::AXObjectCache::handleScrolledToAnchor): Make sure the
672         caret is updated to be in the anchor's position after scrolling.
673
674 2011-06-03  Dominic Cooney  <dominicc@chromium.org>
675
676         Reviewed by Kent Tamura.
677
678         Cloned keygen shadows should have -webkit-keygen-select pseudoclass.
679         https://bugs.webkit.org/show_bug.cgi?id=61984
680
681         When cloneNode's tag name-based cloning algorithm clones the
682         KeygenSelectElements of a keygen shadow as select elements. These
683         lack the -webkit-keygen-select pseudoclass.
684
685         Test: fast/html/clone-keygen.html
686
687         * html/HTMLKeygenElement.cpp:
688         (WebCore::KeygenSelectElement::cloneElementWithoutAttributesAndChildren): Create a KeygenSelectElement when being cloned.
689
690 2011-06-02  MORITA Hajime  <morrita@google.com>
691         
692         Unreviewed ChangeLog fix.
693         
694 2011-06-03  Peter Varga  <pvarga@webkit.org>
695
696         Rubber-stamped by Csaba Osztrogonác.
697         
698         [Qt][V8] Buildfix after r87988.
699
700         No new tests needed.
701
702         * bindings/v8/ScheduledAction.cpp: Add missing guards.
703         (WebCore::ScheduledAction::execute):
704         * bindings/v8/V8EventListener.cpp: Ditto.
705         (WebCore::V8EventListener::callListenerFunction):
706
707 2011-06-03  Dominic Cooney  <dominicc@chromium.org>
708
709         Reviewed by Kent Tamura.
710
711         Cloned range input sliders should be SliderThumbElements, not divs.
712         https://bugs.webkit.org/show_bug.cgi?id=61982
713
714         Test: fast/html/clone-range.html
715
716         * html/shadow/SliderThumbElement.h:
717         (WebCore::SliderThumbElement::cloneElementWithoutAttributesAndChildren): Create a SliderThumbElement when being cloned.
718
719 2011-06-02  Yury Semikhatsky  <yurys@chromium.org>
720
721         Reviewed by Pavel Feldman.
722
723         Web Inspector: add an option for automatically attaching to new workers
724         https://bugs.webkit.org/show_bug.cgi?id=61930
725
726         Worker list is extended with a checkbox that makes inspector attach to each
727         new worker. Whenever a new worker context starts a new inspector window will
728         be opened for it.
729
730         Also worker agent and worker list will be updated when worker context is terminated.
731
732         * inspector/Inspector.json:
733         * inspector/InspectorController.cpp:
734         (WebCore::InspectorController::InspectorController):
735         * inspector/InspectorInstrumentation.cpp:
736         (WebCore::InspectorInstrumentation::workerContextTerminatedImpl):
737         * inspector/InspectorInstrumentation.h:
738         (WebCore::InspectorInstrumentation::workerContextTerminated):
739         * inspector/InspectorWorkerAgent.cpp:
740         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::~WorkerFrontendChannel):
741         (WebCore::InspectorWorkerAgent::create):
742         (WebCore::InspectorWorkerAgent::InspectorWorkerAgent):
743         (WebCore::InspectorWorkerAgent::clearFrontend):
744         (WebCore::InspectorWorkerAgent::setAutoconnectToWorkers):
745         (WebCore::InspectorWorkerAgent::didStartWorkerContext):
746         (WebCore::InspectorWorkerAgent::workerContextTerminated):
747         * inspector/InspectorWorkerAgent.h:
748         * inspector/front-end/WorkerManager.js:
749         (WebInspector.WorkerManager.prototype._workerCreated):
750         (WebInspector.WorkerManager.prototype._workerTerminated):
751         (WebInspector.WorkerManager.prototype.openWorkerInspector):
752         (WebInspector.WorkerManager.prototype._openInspectorWindow):
753         (WebInspector.WorkerManager.prototype.reset):
754         (WebInspector.WorkerMessageForwarder.prototype.workerCreated):
755         (WebInspector.WorkerMessageForwarder.prototype.workerTerminated):
756         * inspector/front-end/WorkersSidebarPane.js:
757         (WebInspector.WorkerListSidebarPane):
758         (WebInspector.WorkerListSidebarPane.prototype._workerAdded):
759         (WebInspector.WorkerListSidebarPane.prototype._workerRemoved):
760         (WebInspector.WorkerListSidebarPane.prototype._workersCleared):
761         (WebInspector.WorkerListSidebarPane.prototype._addWorker):
762         (WebInspector.WorkerListSidebarPane.prototype._workerItemClicked):
763         (WebInspector.WorkerListSidebarPane.prototype._autoattachToWorkersClicked):
764         * inspector/front-end/inspector.js:
765         (WebInspector.reset):
766
767 2011-06-02  Hayato Ito  <hayato@chromium.org>
768
769         Reviewed by Ryosuke Niwa.
770
771         Show a shadow root node itself in Node::traverseNextNodeAcrossFrame.
772         https://bugs.webkit.org/show_bug.cgi?id=61992
773
774         It's better to show a shadow root node itself for debugging.
775         Skipping it didn't add any values.
776
777         No new tests since the function is only available in debug builds.
778
779         * dom/Node.cpp:
780         (WebCore::traverseNextNodeAcrossFrame):
781
782 2011-06-02  James Robinson  <jamesr@chromium.org>
783
784         Unreviewed, rolling out r87901.
785         http://trac.webkit.org/changeset/87901
786         https://bugs.webkit.org/show_bug.cgi?id=61894
787
788         Might be responsible for performance regression on Chromium page cyclers, reverting to see...
789
790         * loader/DocumentLoader.h:
791         (WebCore::DocumentLoader::didTellClientAboutLoad):
792         (WebCore::DocumentLoader::haveToldClientAboutLoad):
793         * loader/FrameLoader.cpp:
794         (WebCore::FrameLoader::loadedResourceFromMemoryCache):
795         * loader/ResourceLoadNotifier.cpp:
796         (WebCore::ResourceLoadNotifier::dispatchWillSendRequest):
797
798 2011-06-02  Levi Weintraub  <leviw@chromium.org>
799
800         Reviewed by Eric Seidel.
801
802         Switch paintReplaced to use IntPoint
803         https://bugs.webkit.org/show_bug.cgi?id=61891
804
805         Switching paintReplaced to use IntPoint to represent the paint offset instead
806         of a pair of ints.
807
808         Also renaming the IntPoint flavor of IntRect::move to moveBy to clear up the
809         fact that the IntPoint is added as an offset as opposed to being relocated
810         to that point.
811
812         No tests because this is just a refactoring.
813
814         * page/FrameView.cpp:
815         (WebCore::FrameView::invalidateScrollbarRect):
816         (WebCore::FrameView::convertFromRenderer):
817         (WebCore::FrameView::convertToRenderer):
818         * platform/ScrollView.cpp:
819         (WebCore::ScrollView::wheelEvent):
820         * platform/ScrollbarThemeComposite.cpp:
821         (WebCore::ScrollbarThemeComposite::invalidatePart):
822         * platform/graphics/gpu/Texture.cpp
823         (WebCore::Texture::updateSubRect)
824         * platform/graphics/IntRect.h:
825         (WebCore::IntRect::moveBy):
826         * platform/mac/WidgetMac.mm:
827         (WebCore::Widget::paint):
828         * rendering/InlineFlowBox.cpp:
829         (WebCore::InlineFlowBox::paint):
830         * rendering/RenderBlock.cpp:
831         (WebCore::RenderBlock::logicalRectToPhysicalRect):
832         (WebCore::RenderBlock::selectionGaps):
833         * rendering/RenderBox.cpp:
834         (WebCore::RenderBox::offsetFromContainer):
835         (WebCore::RenderBox::computeRectForRepaint):
836         (WebCore::RenderBox::localCaretRect):
837         * rendering/RenderDetailsMarker.cpp:
838         (WebCore::RenderDetailsMarker::paint):
839         * rendering/RenderEmbeddedObject.cpp:
840         (WebCore::RenderEmbeddedObject::paintReplaced):
841         * rendering/RenderEmbeddedObject.h:
842         * rendering/RenderHTMLCanvas.cpp:
843         (WebCore::RenderHTMLCanvas::paintReplaced):
844         * rendering/RenderHTMLCanvas.h:
845         * rendering/RenderImage.cpp:
846         (WebCore::RenderImage::paintReplaced):
847         * rendering/RenderImage.h:
848         * rendering/RenderInline.cpp:
849         (WebCore::RenderInline::culledInlineVisualOverflowBoundingBox):
850         * rendering/RenderLayer.cpp:
851         (WebCore::expandClipRectForDescendantsAndReflection):
852         (WebCore::RenderLayer::paintScrollCorner):
853         (WebCore::RenderLayer::paintResizer):
854         (WebCore::RenderLayer::paintChildLayerIntoColumns):
855         (WebCore::RenderLayer::hitTestChildLayerColumns):
856         (WebCore::RenderLayer::boundingBox):
857         (WebCore::RenderLayer::setBackingNeedsRepaintInRect):
858         * rendering/RenderLayerBacking.cpp:
859         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
860         (WebCore::paintScrollbar):
861         (WebCore::RenderLayerBacking::paintContents):
862         * rendering/RenderLayerCompositor.cpp:
863         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
864         (WebCore::RenderLayerCompositor::layerWillBeRemoved):
865         (WebCore::paintScrollbar):
866         (WebCore::RenderLayerCompositor::paintContents):
867         * rendering/RenderListBox.cpp:
868         (WebCore::RenderListBox::controlClipRect):
869         * rendering/RenderListItem.cpp:
870         (WebCore::RenderListItem::positionListMarker):
871         * rendering/RenderListMarker.cpp:
872         (WebCore::RenderListMarker::paint):
873         * rendering/RenderReplaced.cpp:
874         (WebCore::RenderReplaced::paint):
875         * rendering/RenderReplaced.h:
876         (WebCore::RenderReplaced::paintReplaced):
877         * rendering/RenderTableCell.cpp:
878         (WebCore::RenderTableCell::computeRectForRepaint):
879         * rendering/RenderTextControlSingleLine.cpp:
880         (WebCore::RenderTextControlSingleLine::controlClipRect):
881         * rendering/RenderVideo.cpp:
882         (WebCore::RenderVideo::paintReplaced):
883         * rendering/RenderVideo.h:
884         * rendering/RenderView.cpp:
885         (WebCore::RenderView::repaintViewRectangle):
886
887 2011-06-02  James Robinson  <jamesr@chromium.org>
888
889         Reviewed by Dimitri Glazkov.
890
891         [chromium][V8] Add trace events for timer fires and event listener dispatches
892         https://bugs.webkit.org/show_bug.cgi?id=61977
893
894         Adds TRACE_EVENT macro around timer and event listener dispatches.  When tracing (a chromium feature) is
895         enabled, this allows correlating these events with painting, compositing, and everything else in chromium that
896         is traced.  When tracing is disabled, this macro does nothing useful.  Trace points are very cheap when tracing
897         is disabled so this should have no performance impact for non-developers.
898
899         * bindings/v8/ScheduledAction.cpp:
900         (WebCore::ScheduledAction::execute):
901         * bindings/v8/V8EventListener.cpp:
902         (WebCore::V8EventListener::callListenerFunction):
903
904 2011-06-02  John Bates  <jbates@google.com>
905
906         Reviewed by James Robinson.
907
908         DrawingBufferChromium cleanup:
909         - Correct FIXME comment about synchronization.
910         - Remove unnecessary DrawingBufferInternal indirection struct
911           and its unused offscreenColorTexture member.
912         https://bugs.webkit.org/show_bug.cgi?id=61953
913
914         * platform/graphics/chromium/DrawingBufferChromium.cpp:
915         (WebCore::DrawingBuffer::DrawingBuffer):
916         (WebCore::DrawingBuffer::~DrawingBuffer):
917         (WebCore::DrawingBuffer::publishToPlatformLayer):
918         (WebCore::DrawingBuffer::didReset):
919         (WebCore::DrawingBuffer::platformLayer):
920         * platform/graphics/gpu/DrawingBuffer.h:
921
922 2011-06-02  Andrey Kosyakov  <caseq@chromium.org>
923
924         Reviewed by Pavel Feldman.
925
926         Web Inspector: ResourceCookiesView.resize() is missing
927         https://bugs.webkit.org/show_bug.cgi?id=61868
928
929         * inspector/front-end/ResourceCookiesView.js:
930         (WebInspector.ResourceCookiesView.prototype.resize):
931
932 2011-06-02  Kent Tamura  <tkent@chromium.org>
933
934         Reviewed by Dimitri Glazkov.
935
936         REGRESSION(r87014): Cloned text <input> doesn't work well.
937         https://bugs.webkit.org/show_bug.cgi?id=61909
938
939         The default implementation of Element::cloneNode() creates a clone
940         node by Document::createElement(). So, if a customized class is used for
941         shadow nodes, cloneNode() doesn't create a node of the correct class.
942         Such custom classes need to override Element::
943         cloneElementWithoutAttributesAndChildren().
944
945         TextFieldInputType and SearchInputType had references to shadow nodes
946         initialized in createShadowSubtree(). However createShadowSubtree() is
947         not called if the host node is cloned. The accessors for shadow nodes
948         should search a shadow tree.
949
950         Test: fast/forms/textfield-clone.html
951
952         * html/SearchInputType.cpp:
953           Remove data members for shadow nodes, and the accessors search the
954           shadow tree for the requested node by TreeScope::getElementById().
955         (WebCore::SearchInputType::SearchInputType):
956         (WebCore::innerBlockId):
957         (WebCore::resultButtonId):
958         (WebCore::cancelButtonId):
959         (WebCore::SearchInputType::createShadowSubtree):
960         (WebCore::SearchInputType::innerBlockElement):
961         (WebCore::SearchInputType::resultsButtonElement):
962         (WebCore::SearchInputType::cancelButtonElement):
963         * html/SearchInputType.h:
964         * html/TextFieldInputType.cpp: ditto.
965         (WebCore::TextFieldInputType::TextFieldInputType):
966         (WebCore::TextFieldInputType::innerTextId):
967         (WebCore::spinButtonId):
968         (WebCore::TextFieldInputType::speechButtonId):
969         (WebCore::TextFieldInputType::appendChildAndSetId):
970         (WebCore::TextFieldInputType::createShadowSubtree):
971         (WebCore::TextFieldInputType::getShadowElementById):
972         (WebCore::TextFieldInputType::innerTextElement):
973         (WebCore::TextFieldInputType::innerSpinButtonElement):
974         (WebCore::TextFieldInputType::speechButtonElement):
975         * html/TextFieldInputType.h:
976         * html/shadow/TextControlInnerElements.cpp:
977           Overrides cloneElementWithoutAttributesAndChildren() in order that cloneNode()
978           produces an instance of the correct class.
979         (WebCore::TextControlInnerElement::cloneElementWithoutAttributesAndChildren):
980         (WebCore::TextControlInnerTextElement::cloneElementWithoutAttributesAndChildren):
981         (WebCore::SearchFieldResultsButtonElement::cloneElementWithoutAttributesAndChildren):
982         (WebCore::SearchFieldCancelButtonElement::cloneElementWithoutAttributesAndChildren):
983         (WebCore::SpinButtonElement::cloneElementWithoutAttributesAndChildren):
984         (WebCore::InputFieldSpeechButtonElement::cloneElementWithoutAttributesAndChildren):
985         * html/shadow/TextControlInnerElements.h:
986
987 2011-05-28  Martin Robinson  <mrobinson@igalia.com>
988
989         Reviewed by Gustavo Noronha Silva.
990
991         [GTK] Remove PasteboardHelperGtk
992         https://bugs.webkit.org/show_bug.cgi?id=61690
993
994         Remove the virtual methods from PasteboardHelper, so that PasteboardHelperGtk
995         can be removed. Since the GtkClipboard IDs are verified to be the same between
996         WebKit and WebCore we no longer need to communicate from WebCore to WebKit to
997         get them.
998
999         No new tests. This is just a code refactor.
1000
1001         * platform/Pasteboard.h: Remove GTK+ specific methods. They are no longer needed.
1002         * platform/gtk/ClipboardGtk.cpp: Remove the m_helper member and access the
1003         PasteboardHelper singleton directly.
1004         * platform/gtk/ClipboardGtk.h: Ditto.
1005         * platform/gtk/PasteboardGtk.cpp: Ditto.
1006         * platform/gtk/PasteboardHelper.cpp:
1007         (WebCore::removeMarkupPrefix): Remove an extra line.
1008         (WebCore::PasteboardHelper::defaultPasteboardHelper): Added this static getter
1009         for the singleton.
1010         (WebCore::PasteboardHelper::PasteboardHelper): Moved the contents of initTargetList here.
1011         (WebCore::PasteboardHelper::getCurrentClipboard): Instead of talking with WebKit to determine
1012         whether or not to use the primary selection clipboard, just use our new member.
1013         (WebCore::PasteboardHelper::fillSelectionData): Use our local enum to get the ID.
1014         (WebCore::PasteboardHelper::targetListForDataObject): Ditto.
1015         (WebCore::PasteboardHelper::dropAtomsForContext): Ditto.
1016         (WebCore::getClipboardContentsCallback): Ditto.
1017         * platform/gtk/PasteboardHelper.h: PasteboardHelper now keeps track of whether or
1018         not to use the primary selection clipboard internally.
1019         (WebCore::PasteboardHelper::setUsePrimarySelectionClipboard): Added.
1020         (WebCore::PasteboardHelper::usePrimarySelectionClipboard): Added.
1021
1022 2011-06-02  Levi Weintraub  <leviw@chromium.org>
1023
1024         Reviewed by Eric Seidel.
1025
1026         Teach InlineBox about FloatPoint
1027         https://bugs.webkit.org/show_bug.cgi?id=44412
1028
1029         Original patch by Eric Seidel. Updated by me.
1030
1031         This is another step towards more point/size
1032         usage throughout the rendering tree.
1033
1034         Added left(), right(), top(), and bottom() methods
1035         to InlineBox. Removed m_x, and m_y and replaced them
1036         with a single m_topLeft member.
1037
1038         No new tests since this is just a refactoring.
1039
1040         * rendering/EllipsisBox.cpp:
1041         (WebCore::EllipsisBox::paint):
1042         (WebCore::EllipsisBox::selectionRect):
1043         (WebCore::EllipsisBox::paintSelection):
1044         (WebCore::EllipsisBox::nodeAtPoint):
1045         * rendering/EllipsisBox.h:
1046         (WebCore::EllipsisBox::EllipsisBox):
1047         * rendering/InlineBox.cpp:
1048         (WebCore::InlineBox::adjustPosition):
1049         (WebCore::InlineBox::canAccommodateEllipsis):
1050         * rendering/InlineBox.h:
1051         (WebCore::InlineBox::InlineBox):
1052         (WebCore::InlineBox::setX):
1053         (WebCore::InlineBox::x):
1054         (WebCore::InlineBox::left):
1055         (WebCore::InlineBox::setY):
1056         (WebCore::InlineBox::y):
1057         (WebCore::InlineBox::top):
1058         (WebCore::InlineBox::topLeft):
1059         (WebCore::InlineBox::right):
1060         (WebCore::InlineBox::bottom):
1061         (WebCore::InlineBox::logicalLeft):
1062         (WebCore::InlineBox::setLogicalLeft):
1063         (WebCore::InlineBox::logicalTop):
1064         (WebCore::InlineBox::setLogicalTop):
1065         (WebCore::InlineBox::logicalFrameRect):
1066         * rendering/InlineFlowBox.h:
1067         (WebCore::InlineFlowBox::frameRectIncludingLineHeight):
1068         * rendering/InlineTextBox.cpp:
1069         (WebCore::InlineTextBox::placeEllipsisBox):
1070         (WebCore::InlineTextBox::paintTextMatchMarker):
1071         (WebCore::InlineTextBox::computeRectForReplacementMarker):
1072         * rendering/RenderText.cpp:
1073         (WebCore::RenderText::firstRunX):
1074         (WebCore::RenderText::firstRunY):
1075         * rendering/RenderTreeAsText.cpp:
1076         (WebCore::writeTextRun):
1077         * rendering/RootInlineBox.cpp:
1078         (WebCore::RootInlineBox::placeEllipsis):
1079         * rendering/svg/RenderSVGText.cpp:
1080         (WebCore::RenderSVGText::positionForPoint):
1081         * rendering/svg/SVGInlineTextBox.h:
1082         (WebCore::SVGInlineTextBox::selectionTop):
1083         * rendering/svg/SVGRootInlineBox.cpp:
1084         (WebCore::SVGRootInlineBox::closestLeafChildForPosition):
1085
1086 2011-06-02  Jian Li  <jianli@chromium.org>
1087
1088         Reviewed by David Levin.
1089
1090         Update the behavior of multiple reads for FileReader
1091         https://bugs.webkit.org/show_bug.cgi?id=61793
1092
1093         Changed to throw an OperationNotAllowedException with the NOT_ALLOWED_ERR
1094         status code on any of the read methods that occur when readyState = LOADING.
1095         Otherwise, calling any of the read methods should work. 
1096
1097         Test: fast/files/read-file-async.html
1098
1099         * CodeGenerators.pri:
1100         * DerivedSources.cpp:
1101         * DerivedSources.make:
1102         * GNUmakefile.list.am:
1103         * WebCore.gypi:
1104         * WebCore.pro:
1105         * WebCore.vcproj/WebCore.vcproj:
1106         * WebCore.xcodeproj/project.pbxproj:
1107         * bindings/js/JSDOMBinding.cpp:
1108         (WebCore::setDOMException):
1109         * bindings/v8/V8Proxy.cpp:
1110         (WebCore::V8Proxy::setDOMException):
1111         * dom/ExceptionCode.cpp:
1112         (WebCore::getExceptionCodeDescription):
1113         * dom/ExceptionCode.h:
1114         * fileapi/FileReader.cpp:
1115         (WebCore::FileReader::FileReader):
1116         (WebCore::FileReader::hasPendingActivity):
1117         (WebCore::FileReader::readAsArrayBuffer):
1118         (WebCore::FileReader::readAsBinaryString):
1119         (WebCore::FileReader::readAsText):
1120         (WebCore::FileReader::readAsDataURL):
1121         (WebCore::FileReader::readInternal):
1122         (WebCore::FileReader::abort):
1123         (WebCore::FileReader::doAbort):
1124         (WebCore::FileReader::terminate):
1125         (WebCore::FileReader::start):
1126         (WebCore::FileReader::didStartLoading):
1127         (WebCore::FileReader::didFinishLoading):
1128         (WebCore::FileReader::didFail):
1129         * fileapi/FileReader.h:
1130         (WebCore::FileReader::readyState):
1131         * fileapi/FileReader.idl:
1132         * fileapi/OperationNotAllowedException.h: Added.
1133         (WebCore::OperationNotAllowedException::create):
1134         (WebCore::OperationNotAllowedException::OperationNotAllowedException):
1135         * fileapi/OperationNotAllowedException.idl: Added.
1136
1137 2011-06-02  Adrienne Walker  <enne@google.com>
1138
1139         Reviewed by James Robinson.
1140
1141         [chromium] Compositor HUD should respect mapTexSubImage2D returning NULL
1142         https://bugs.webkit.org/show_bug.cgi?id=61954
1143
1144         * platform/graphics/chromium/cc/CCHeadsUpDisplay.cpp:
1145         (WebCore::CCHeadsUpDisplay::draw):
1146
1147 2011-06-02  Brady Eidson  <beidson@apple.com>
1148
1149         Reviewed by Oliver Hunt.
1150
1151         <rdar://problem/9539920> and https://bugs.webkit.org/show_bug.cgi?id=61950
1152         Repro crash loading certain webarchives after r87566.
1153
1154         Test: webarchive/loading/javascript-url-iframe-crash.html
1155
1156         * bindings/ScriptControllerBase.cpp:
1157         (WebCore::ScriptController::executeIfJavaScriptURL): DocumentWriter::replaceDocument can
1158           cause the DocumentLoader to be destroyed, so protect it with a Ref here.
1159
1160 2011-06-02  Jay Civelli  <jcivelli@chromium.org>
1161
1162         Reviewed by Adam Barth.
1163
1164         Adding MHTML generation support to MHTMLArchive.
1165         https://bugs.webkit.org/show_bug.cgi?id=7169
1166
1167         * loader/archive/mhtml/MHTMLArchive.cpp:
1168         (WebCore::generateRandomBoundary):
1169         (WebCore::replaceNonPrintableCharacters):
1170         (WebCore::MHTMLArchive::generateMHTMLData):
1171         * loader/archive/mhtml/MHTMLArchive.h:
1172         * page/PageSerializer.cpp:
1173         (WebCore::PageSerializer::serializeFrame):
1174         (WebCore::PageSerializer::serializeCSSStyleSheet):
1175         * platform/SharedBuffer.cpp:
1176         (WebCore::SharedBuffer::append):
1177         * platform/SharedBuffer.h:
1178
1179 2011-06-02  Simon Fraser  <simon.fraser@apple.com>
1180
1181         Reviewed by Andreas Kling.
1182
1183         Share Path code that uses beziers to construct a rounded rect
1184         https://bugs.webkit.org/show_bug.cgi?id=61960
1185
1186         Have two methods in Path that construct beziers for rounded
1187         rects to share the same code.
1188         
1189         Make gCircleControlPoint a little more precise, and add
1190         a comment describing its derivation.
1191         
1192         Make use of FloatRect::maxX() and maxY().
1193
1194         * platform/graphics/Path.cpp:
1195         (WebCore::Path::addRoundedRect):
1196         (WebCore::Path::addBeziersForRoundedRect):
1197         * platform/graphics/Path.h:
1198
1199 2011-06-02  Ryosuke Niwa  <rniwa@webkit.org>
1200
1201         Reviewed by Enrica Casucci.
1202
1203         ApplyStyleCommand shouldn't call collapseTextDecorationProperties
1204         https://bugs.webkit.org/show_bug.cgi?id=61887
1205
1206         Removed the call to collapseTextDecorationProperties in ApplyStyleCommand::applyInlineStyle.
1207
1208         No new tests because this is a code refactoring.
1209
1210         * editing/ApplyStyleCommand.cpp:
1211         (WebCore::ApplyStyleCommand::applyInlineStyle): No loner calls collapseTextDecorationProperties.
1212         (WebCore::ApplyStyleCommand::pushDownInlineStyleAroundNode): Updated comment.
1213         * editing/EditingStyle.cpp:
1214         (WebCore::HTMLElementEquivalent::propertyExistsInStyle): Added to check both text-decoration
1215         and -webkit-text-decorations-in-effect.
1216         (WebCore::HTMLTextDecorationEquivalent::HTMLTextDecorationEquivalent): Added a comment.
1217         (WebCore::HTMLTextDecorationEquivalent::propertyExistsInStyle): Checks both text-decoration
1218         and -webkit-text-decorations-in-effect.
1219         (WebCore::HTMLTextDecorationEquivalent::valueIsPresentInStyle): Checks if a text decoration
1220         is present in -webkit-text-decorations-in-effect or text-decoration preferring the former.
1221         (WebCore::EditingStyle::conflictsWithInlineStyleOfElement): Merged loops for when conflictingProperties
1222         is false and true. Added a support for -webkit-text-decorations-in-effect.
1223
1224 2011-06-02  Ryosuke Niwa  <rniwa@webkit.org>
1225
1226         Reviewed by Eric Seidel.
1227
1228         Make more functions static local in EventHandlers.cpp
1229         https://bugs.webkit.org/show_bug.cgi?id=58503
1230
1231         Removed canHandleDragAndDropForTarget and made focusDirectionForKey local to EventHandler.cpp.
1232
1233         * page/EventHandler.cpp:
1234         (WebCore::targetIsFrame): Extracted from canHandleDragAndDropForTarget.
1235         (WebCore::EventHandler::updateDragAndDrop): Calls contentFrameForTarget instead of canHandleDragAndDropForTarget.
1236         (WebCore::EventHandler::cancelDragAndDrop): Ditto.
1237         (WebCore::EventHandler::performDragAndDrop): Ditto.
1238         (WebCore::focusDirectionForKey): No longer a member function of EventHandler class.
1239         (WebCore::handleKeyboardSelectionMovement): No longer a member function of EventHandler class; also calls
1240         focusDirectionForKey instead of manually comparing.
1241         * page/EventHandler.h:
1242
1243 2011-06-02  Alok Priyadarshi  <alokp@chromium.org>
1244
1245         Reviewed by James Robinson.
1246
1247         [chromium] Things jump around when selecting anything on the page
1248         https://bugs.webkit.org/show_bug.cgi?id=61639
1249
1250         WebCore::LayerTextureUpdaterSkPicture::updateTextureRect was not updating a tile sub-region properly.
1251         It did not consider dest-rect when selecting the clip and translation required to draw the content-rect into dest-rect.
1252         Also removed clearing of framebuffer because it used to clear the whole tile not just dest-rect.
1253         An appropriate viewport could be set to just clear the dest-rect, but it was debug only code and I did not want to mess
1254         with the viewport set by skia.
1255
1256         No new tests. This case should be covered by most of the layout tests (pixel) targeting selection or hovering when chromium is run in compositing mode.
1257         Here is a non-exhaustive list of existing tests covering this case.
1258         Test: editing/selection/14971.html (existing)
1259               editing/selection/3690703-2.html (existing)
1260               editing/selection/4402375.html (existing)
1261               editing/selection/4818145.html (existing)
1262
1263         * platform/graphics/chromium/LayerTextureUpdaterCanvas.cpp:
1264         (WebCore::LayerTextureUpdaterSkPicture::updateTextureRect):
1265         (WebCore::LayerTextureUpdaterSkPicture::createFrameBuffer):
1266         * platform/graphics/chromium/LayerTextureUpdaterCanvas.h:
1267
1268 2011-06-02  Dimitri Glazkov  <dglazkov@chromium.org>
1269
1270         Reviewed by Darin Adler.
1271
1272         Add build logistics and plumbing for window.internals object.
1273         https://bugs.webkit.org/show_bug.cgi?id=60313
1274
1275         Test: fast/harness/internals-object.html
1276
1277         * Configurations/WebCoreTestSupport.xcconfig: Added.
1278         * DerivedSources.make: Added support for generating from Internals.idl.
1279         * WebCore.gyp/WebCore.gyp: Added new webcore_test_support library.
1280         * WebCore.gypi: Ditto.
1281         * WebCore.xcodeproj/project.pbxproj: Added WebCoreTestSupport library.
1282         * testing/Internals.cpp: Added.
1283         * testing/Internals.h: Added.
1284         * testing/Internals.idl: Added.
1285         * testing/js/WebCoreTestSupport.cpp: Added.
1286         * testing/js/WebCoreTestSupport.h: Added.
1287         * testing/v8/WebCoreTestSupport.cpp: Added.
1288         * testing/v8/WebCoreTestSupport.h: Added.
1289
1290 2011-06-01  Adrienne Walker  <enne@google.com>
1291
1292         Reviewed by Eric Seidel.
1293
1294         [chromium] LayerChromium should use a RefPtr for replica layer
1295         https://bugs.webkit.org/show_bug.cgi?id=61898
1296
1297         Having this member variable be a raw pointer is brittle and assumes
1298         that the GraphicsLayer tree keeps this in sync.  There aren't any
1299         known bugs caused by this, but it seems like good sense to do this.
1300
1301         * platform/graphics/chromium/LayerChromium.h:
1302         (WebCore::LayerChromium::replicaLayer):
1303
1304 2011-06-02  Ryosuke Niwa  <rniwa@webkit.org>
1305
1306         Reviewed by Eric Seidel.
1307
1308         REGRESSION: inline style is lost when deleting line break between paragraphs with same style
1309         https://bugs.webkit.org/show_bug.cgi?id=61899
1310
1311         The bug was caused by ReplaceSelectionCommand::doApply's calling handleStyleSpansBeforeInsertion
1312         before insertionPos is adjusted by positionAvoidingPrecedingNodes and positionOutsideTabSpan.
1313
1314         Fixed the bug by calling handleStyleSpansBeforeInsertion after the calls to these two functions.
1315
1316         Test: editing/deleting/delete-line-break-between-paragraphs-with-same-style.html
1317
1318         * editing/ReplaceSelectionCommand.cpp:
1319         (WebCore::ReplaceSelectionCommand::doApply):
1320
1321 2011-06-01  Ryosuke Niwa  <rniwa@webkit.org>
1322
1323         Reviewed by Simon Fraser.
1324
1325         REGRESSION: Text selection broken for text with line-height applied
1326         https://bugs.webkit.org/show_bug.cgi?id=54929
1327
1328         The bug was caused by RenderText::positionForPoint's not considering the case where a point is
1329         above selectionTop and below lineTop of the first root inline box. Fixed the bug by considering
1330         any point between selectionTop and lineTop to be inside a root inline box. This condition is
1331         consistent with the condition we use to determine the bottom of a line.
1332
1333         Test: editing/selection/hit-test-on-text-with-line-height.html
1334
1335         * rendering/RenderBlock.cpp:
1336         (WebCore::RenderBlock::positionForPointWithInlineChildren): Fixed a condition to determine whether
1337         or not a point is above the first root line box. We need to check both selectionTop and logicalTop
1338         for the same reason explained above.
1339         * rendering/RenderText.cpp:
1340         (WebCore::RenderText::positionForPoint): See above.
1341
1342 2011-06-02  Andreas Kling  <kling@webkit.org>
1343
1344         Reviewed by James Robinson.
1345
1346         Canvas/V8: Fix setting strokeStyle or fillStyle to a CSS system color.
1347         https://bugs.webkit.org/show_bug.cgi?id=61944
1348
1349         Call setFillColor/setStrokeColor (instead of setFillStyle/setStrokeStyle)
1350         for string styles. This ensures that system color resolution is performed,
1351         and matches what the JSC bindings do.
1352
1353         Test: canvas/philip/tests/2d.fillStyle.parse.system.html
1354
1355         * bindings/v8/custom/V8CanvasRenderingContext2DCustom.cpp:
1356         (WebCore::toCanvasStyle):
1357         (WebCore::V8CanvasRenderingContext2D::strokeStyleAccessorSetter):
1358         (WebCore::V8CanvasRenderingContext2D::fillStyleAccessorSetter):
1359
1360 2011-06-02  Sheriff Bot  <webkit.review.bot@gmail.com>
1361
1362         Unreviewed, rolling out r87920.
1363         http://trac.webkit.org/changeset/87920
1364         https://bugs.webkit.org/show_bug.cgi?id=61943
1365
1366         This patch does not build in Win Builder (dbg)(shared)
1367         downstream (Requested by abarth|gardener on #webkit).
1368
1369         * platform/chromium/PopupMenuChromium.cpp:
1370         (WebCore::PopupContainer::showPopup):
1371         (WebCore::PopupListBox::handleMouseReleaseEvent):
1372         (WebCore::PopupListBox::acceptIndex):
1373
1374 2011-06-02  Dimitri Glazkov  <dglazkov@chromium.org>
1375
1376         Unreviewed, rolling out r87926.
1377         http://trac.webkit.org/changeset/87926
1378         https://bugs.webkit.org/show_bug.cgi?id=60313
1379
1380         Fails to find WebCoreTestSupport.dylib on bots.
1381
1382         * Configurations/WebCore.xcconfig:
1383         * Configurations/WebCoreTestSupport.xcconfig: Removed.
1384         * DerivedSources.make:
1385         * WebCore.exp.in:
1386         * WebCore.gyp/WebCore.gyp:
1387         * WebCore.gypi:
1388         * WebCore.xcodeproj/project.pbxproj:
1389         * bindings/js/JSDOMWrapper.cpp:
1390         (WebCore::JSDOMWrapper::~JSDOMWrapper):
1391         * bindings/js/JSDOMWrapper.h:
1392         * testing/Internals.cpp: Removed.
1393         * testing/Internals.h: Removed.
1394         * testing/Internals.idl: Removed.
1395         * testing/js/WebCoreTestSupport.cpp: Removed.
1396         * testing/js/WebCoreTestSupport.h: Removed.
1397         * testing/v8/WebCoreTestSupport.cpp: Removed.
1398         * testing/v8/WebCoreTestSupport.h: Removed.
1399
1400 2011-06-02  Carlos Garcia Campos  <cgarcia@igalia.com>
1401
1402         Reviewed by Martin Robinson.
1403
1404         [GTK] Implement popup menus in Webkit2
1405         https://bugs.webkit.org/show_bug.cgi?id=61854
1406
1407         Move common code into a new class to be used by both WebKit1 and
1408         WebKit2.
1409
1410         * GNUmakefile.list.am: Add new files to compilation.
1411         * platform/gtk/GtkPopupMenu.cpp: Copied from Source/WebCore/platform/gtk/PopupMenuGtk.cpp.
1412         (WebCore::GtkPopupMenu::GtkPopupMenu):
1413         (WebCore::GtkPopupMenu::~GtkPopupMenu):
1414         (WebCore::GtkPopupMenu::clear): Remove all menu items.
1415         (WebCore::GtkPopupMenu::appendSeparator): Add a new separator
1416         item to the menu.
1417         (WebCore::GtkPopupMenu::appendItem): Add a new item to the menu for
1418         the given action.
1419         (WebCore::GtkPopupMenu::popUp): Show the menu.
1420         (WebCore::GtkPopupMenu::popDown): Hide the menu.
1421         (WebCore::GtkPopupMenu::menuRemoveItem):
1422         (WebCore::GtkPopupMenu::menuPositionFunction):
1423         (WebCore::GtkPopupMenu::resetTypeAheadFindState):
1424         (WebCore::GtkPopupMenu::typeAheadFind):
1425         (WebCore::GtkPopupMenu::selectItemCallback):
1426         (WebCore::GtkPopupMenu::keyPressEventCallback):
1427         * platform/gtk/GtkPopupMenu.h: Copied from Source/WebCore/platform/gtk/PopupMenuGtk.h.
1428         (WebCore::GtkPopupMenu::create):
1429         (WebCore::GtkPopupMenu::platformMenu):
1430         * platform/gtk/PopupMenuGtk.cpp:
1431         (WebCore::PopupMenuGtk::PopupMenuGtk):
1432         (WebCore::PopupMenuGtk::~PopupMenuGtk):
1433         (WebCore::PopupMenuGtk::show): Use GtkPopupMenu.
1434         (WebCore::PopupMenuGtk::hide): Ditto.
1435         (WebCore::PopupMenuGtk::menuItemActivated):
1436         (WebCore::PopupMenuGtk::menuUnmapped):
1437         * platform/gtk/PopupMenuGtk.h:
1438
1439 2011-05-21  Dimitri Glazkov  <dglazkov@chromium.org>
1440
1441         Reviewed by Darin Adler.
1442
1443         Add build logistics and plumbing for window.internals object.
1444         https://bugs.webkit.org/show_bug.cgi?id=60313
1445
1446         Test: fast/harness/internals-object.html
1447
1448         * Configurations/WebCoreTestSupport.xcconfig: Added.
1449         * DerivedSources.make: Added support for generating from Internals.idl.
1450         * WebCore.gyp/WebCore.gyp: Added new webcore_test_support library.
1451         * WebCore.gypi: Ditto.
1452         * WebCore.xcodeproj/project.pbxproj: Added WebCoreTestSupport library.
1453         * testing/Internals.cpp: Added.
1454         * testing/Internals.h: Added.
1455         * testing/Internals.idl: Added.
1456         * testing/js/WebCoreTestSupport.cpp: Added.
1457         * testing/js/WebCoreTestSupport.h: Added.
1458         * testing/v8/WebCoreTestSupport.cpp: Added.
1459         * testing/v8/WebCoreTestSupport.h: Added.
1460
1461 2011-06-02  Naoki Takano  <takano.naoki@gmail.com>
1462
1463         Reviewed by Dimitri Glazkov.
1464
1465         [Chromium] Click event is not fired for a menulist <select>
1466         https://bugs.webkit.org/show_bug.cgi?id=60563
1467
1468         Tests: SelectItemEventFire, SelectItemKeyEvent, SelectItemRemoveSelectOnChange and SelectItemRemoveSelectOnChange in webkit_unit_tests.
1469
1470         * platform/chromium/PopupMenuChromium.cpp:
1471         (WebCore::PopupContainer::showPopup): Set m_focusedNode from m_frameView.
1472         (WebCore::PopupListBox::handleMouseReleaseEvent): Call dispatchMouseEvent to forward the event only if select popup.
1473         (WebCore::PopupListBox::acceptIndex): Change to return accepted or not.
1474
1475 2011-06-02  Dimitri Glazkov  <dglazkov@chromium.org>
1476
1477         Reviewed by Darin Adler.
1478
1479         Stop event propagation for cases where relatedTarget is both ancestor of the target and at shadow boundary.
1480         https://bugs.webkit.org/show_bug.cgi?id=61892
1481
1482         In the cases where the relatedTarget of an event is an ancestor of the target, and the relatedTarget is
1483         a shadow host, we should not allow events to escape out of the hosted shadow DOM subtree.
1484
1485         * dom/EventDispatcher.cpp:
1486         (WebCore::EventDispatcher::adjustToShadowBoundaries): Added a check that is valid for both new and old shadow DOM.
1487
1488 2011-06-02  Hans Wennborg  <hans@chromium.org>
1489
1490         Reviewed by Tony Gentilcore.
1491
1492         Fix LevelDBTransaction::clearTree()
1493         https://bugs.webkit.org/show_bug.cgi?id=61917
1494
1495         This was broken in the code I copied it from; we can't delete and walk
1496         the tree at the same time.
1497
1498         No new functionality, no new tests.
1499
1500         * platform/leveldb/LevelDBTransaction.cpp:
1501         (WebCore::LevelDBTransaction::clearTree):
1502
1503 2011-06-02  Andreas Kling  <kling@webkit.org>
1504
1505         Rubber-stamped by Simon Hausmann.
1506
1507         Remove Qt's precompiled header hack as it was broken, and was not even
1508         used unless building WebKit inside a Qt tree.
1509
1510         * WebCore.pri:
1511
1512 2011-06-02  James Robinson  <jamesr@chromium.org>
1513
1514         Reviewed by Brady Eidson.
1515
1516         DocumentLoader keeps a reference to all URL strings ever loaded leading to lots of memory waste
1517         https://bugs.webkit.org/show_bug.cgi?id=61894
1518
1519         DocumentLoader::m_resourcesClientKnowsAbout is a set of all the URLs that have passed through
1520         FrameLoader::dispatchWillSendRequest() and is used by FrameLoader::loadedResourceFromMemoryCached to decide
1521         whether to inform the FrameLoader's m_client about this load.  Unfortunately, this set holds a reference to the
1522         URL string for every resource loaded, so on pages that use data URLs to "load" large amounts of data this leaks
1523         lots of memory.
1524
1525         This set only has an effect on the Mac port, as the only two ports that implement
1526         FrameLoaderClient::dispatchDidLoadResourceFromMemoryCache() are Chromium and Mac and the Chromium implementation
1527         can correctly handle receiving multiple callbacks.  This patch limits the set to only PLATFORM(MAC) so other
1528         ports do not have to pay this memory cost.  It's possible that a better fix exists specifically for the Mac port
1529         implementation, but that would have to determined by someone who works on that port specifically.
1530
1531         * loader/DocumentLoader.h:
1532         (WebCore::DocumentLoader::didTellClientAboutLoad):
1533         (WebCore::DocumentLoader::haveToldClientAboutLoad):
1534
1535 2011-06-02  Aparna Nandyal  <aparna.nand@wipro.com>
1536
1537         Reviewed by Andreas Kling.
1538
1539         [Qt] Multiple drop events when doing DnD of images.
1540         https://bugs.webkit.org/show_bug.cgi?id=61504
1541
1542         Duplicate entries of the url were getting added into drag data
1543         which is removed. The duplicate entries were causing the same image
1544         url to be copied twice. The code changes now match other webkit ports.
1545
1546         * platform/qt/ClipboardQt.cpp:
1547         (WebCore::ClipboardQt::declareAndWriteDragImage):
1548
1549 2011-06-02  Naiem Shaik  <naiem.shaik@gmail.com>
1550
1551         Reviewed by Kent Tamura.
1552         
1553         Fixing invalid value being returned for default checkbox and radio state
1554         https://bugs.webkit.org/show_bug.cgi?id=61674
1555
1556         As per http://www.w3.org/TR/html5/number-state.html#checkbox-state and
1557         http://www.w3.org/TR/html5/number-state.html#radio-button-state:
1558         The value IDL attribute is in mode default/on: 
1559         If the element has a value attribute, it must return that attribute's 
1560         value; otherwise, it must return the string "on".  
1561         Currently default value is empty string;Default value of Radio button 
1562         and checkbox should be "on".Changed fallbackValue function to return the same
1563         This works as per spec in IE9,Firefox and Opera
1564
1565         Tests: fast/forms/checkbox-default-value.html
1566                fast/forms/radio-default-value.html
1567
1568         * html/BaseCheckableInputType.cpp:
1569         (WebCore::BaseCheckableInputType::fallbackValue):
1570
1571 2011-06-02  Kent Tamura  <tkent@chromium.org>
1572
1573         [Chromium/Mac] Fix a wrong merge for r87881
1574         https://bugs.webkit.org/show_bug.cgi?id=61845
1575
1576         * platform/chromium/ThemeChromiumMac.mm:
1577         (WebCore::paintStepper):
1578
1579 2011-06-02  Ian Henderson  <ianh@apple.com>
1580
1581         Reviewed by Simon Fraser.
1582
1583         [CG] GraphicsContext::fillRoundedRect() ignores the gradient fill the CGContextFillEllipseInRect() code path
1584         https://bugs.webkit.org/show_bug.cgi?id=61882
1585
1586         If we have a gradient or pattern fill set, take the slow path, which
1587         handles these cases properly.
1588
1589         No new tests, since we never try to fill a rounded rect with a
1590         gradient or pattern.
1591
1592         * platform/graphics/cg/GraphicsContextCG.cpp:
1593         (WebCore::GraphicsContext::fillRoundedRect):
1594
1595 2011-06-02  MORITA Hajime  <morrita@google.com>
1596
1597         Reviewed by Kent Tamura.
1598
1599         [Refactoring] Node::nextRenderer() and previousRenderer() should be part of NodeRenderingContext
1600         https://bugs.webkit.org/show_bug.cgi?id=61912
1601
1602         Inlined Node::nextRenderer() and previousRenderer() into NodeRenderingContext and
1603         removed original definitions.
1604
1605         No test, no behavioral change.
1606         
1607         * dom/Node.cpp:
1608         * dom/Node.h:
1609         * dom/NodeRenderingContext.cpp:
1610         (WebCore::NodeRenderingContext::nextRenderer):
1611         (WebCore::NodeRenderingContext::previousRenderer):
1612
1613 2011-06-02  Piroska András  <Piroska.Andras@stud.u-szeged.hu>
1614
1615         Rubber-stamped by Gabor Loki.
1616
1617         Trivial buildfix for the ParallelJobs part of FEConvolveMatrix.
1618
1619         * platform/graphics/filters/FEConvolveMatrix.cpp:
1620         (WebCore::FEConvolveMatrix::apply): Rename variable i to job
1621
1622 2011-06-02  Yuta Kitamura  <yutak@chromium.org>
1623
1624         Reviewed by Kent Tamura.
1625
1626         WebSocket: Call WebSocketChannel::fail() when WebSocketHandshake has failed
1627         https://bugs.webkit.org/show_bug.cgi?id=61841
1628
1629         There is no change in behavior except that capitalization of a few error messages
1630         has been changed. No new tests are added.
1631
1632         * websockets/WebSocketChannel.cpp:
1633         (WebCore::WebSocketChannel::processBuffer):
1634         Pass m_handshake.failureReason() to fail() if the handshake has failed.
1635         * websockets/WebSocketHandshake.cpp:
1636         Replace occurrences of m_handle->addMessage() with assignments to m_failureReason.
1637         Change capitalization of a few messages so that all messages start with a capital letter.
1638         (WebCore::WebSocketHandshake::readServerHandshake):
1639         (WebCore::WebSocketHandshake::failureReason):
1640         (WebCore::WebSocketHandshake::readStatusLine):
1641         (WebCore::WebSocketHandshake::readHTTPHeaders):
1642         (WebCore::WebSocketHandshake::checkResponseHeaders):
1643         * websockets/WebSocketHandshake.h:
1644         Add failureReason(), which returns a string that describes why WebSocket handshake
1645         has failed.
1646
1647 2011-06-01  Dan Bernstein  <mitz@apple.com>
1648
1649         Reviewed by Anders Carlsson.
1650
1651         Incorrect UA style when printing a simple document
1652         https://bugs.webkit.org/show_bug.cgi?id=61900
1653
1654         This is not testable in run-webkit-tests because unless the test is the first to run in an instance
1655         of DumpRenderTree, it is not guaranteed that the full default style sheet has not been initialized.
1656
1657         * css/CSSStyleSelector.cpp:
1658         (WebCore::loadFullDefaultStyle): Replace the simple default print style, which is now equal to the
1659         simple default style, with a new RuleSet before adding the style rules from the full default sheet.
1660         (WebCore::loadSimpleDefaultStyle): Set defaultPrintStyle to point to the default style. They are
1661         equal in the simple case.
1662
1663 2011-06-01  Kent Tamura  <tkent@chromium.org>
1664
1665         Reviewed by Dimitri Glazkov.
1666
1667         Remove outer-spin-button
1668         https://bugs.webkit.org/show_bug.cgi?id=61845
1669
1670         Remove outer-spin-button, and render steppers as inner-spin-button.
1671         Outer-spin-button have never worked well with padding and border of
1672         <input>, and the layout code is very tricky and very hard to maintain it.
1673
1674         * css/CSSPrimitiveValueMappings.h:
1675         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
1676         * css/CSSValueKeywords.in:
1677         * css/html.css:
1678         * html/HTMLInputElement.cpp:
1679         (WebCore::HTMLInputElement::innerSpinButtonElement):
1680         * html/HTMLInputElement.h:
1681         * html/InputType.h:
1682         * html/TextFieldInputType.cpp:
1683         (WebCore::TextFieldInputType::TextFieldInputType):
1684         (WebCore::TextFieldInputType::createShadowSubtree):
1685         (WebCore::TextFieldInputType::destroyShadowSubtree):
1686         * html/TextFieldInputType.h:
1687         * html/shadow/TextControlInnerElements.cpp:
1688         (WebCore::SpinButtonElement::SpinButtonElement):
1689         (WebCore::SpinButtonElement::create):
1690         (WebCore::SpinButtonElement::shadowPseudoId):
1691         * html/shadow/TextControlInnerElements.h:
1692         * platform/ThemeTypes.h:
1693         * platform/chromium/ThemeChromiumMac.mm:
1694         (WebCore::paintStepper):
1695          Center the stepper drawing area because the specified area can be
1696          larger than the NSStepper sizes.
1697         (WebCore::ThemeChromiumMac::controlSize):
1698         (WebCore::ThemeChromiumMac::minimumControlSize):
1699         (WebCore::ThemeChromiumMac::inflateControlPaintRect):
1700         (WebCore::ThemeChromiumMac::paint):
1701         * platform/mac/ThemeMac.mm:
1702         (WebCore::paintStepper):
1703          Center the stepper drawing area because the specified area can be
1704          larger than the NSStepper sizes.
1705         (WebCore::ThemeMac::controlSize):
1706         (WebCore::ThemeMac::minimumControlSize):
1707         (WebCore::ThemeMac::inflateControlPaintRect):
1708         (WebCore::ThemeMac::paint):
1709         * rendering/RenderBox.cpp:
1710         (WebCore::RenderBox::paintBoxDecorations):
1711         * rendering/RenderBox.h:
1712         * rendering/RenderTextControlSingleLine.cpp:
1713         (WebCore::RenderTextControlSingleLine::layout):
1714         (WebCore::RenderTextControlSingleLine::nodeAtPoint):
1715         (WebCore::RenderTextControlSingleLine::textBlockWidth):
1716         * rendering/RenderTextControlSingleLine.h:
1717         * rendering/RenderTheme.cpp:
1718         (WebCore::RenderTheme::adjustStyle):
1719         (WebCore::RenderTheme::paint):
1720         (WebCore::RenderTheme::adjustInnerSpinButtonStyle):
1721         * rendering/RenderTheme.h:
1722         * rendering/RenderThemeMac.mm:
1723         (WebCore::RenderThemeMac::adjustRepaintRect):
1724
1725 2011-06-01  Emil A Eklund  <eae@chromium.org>
1726
1727         Reviewed by Eric Seidel.
1728
1729         Switch RenderLayer::convertToLayerCoords to use IntPoint
1730         https://bugs.webkit.org/show_bug.cgi?id=61818
1731
1732         Covered by existing tests.
1733
1734         * platform/graphics/FloatPoint.h:
1735         (WebCore::flooredIntSize):
1736         * rendering/RenderLayer.cpp:
1737         (WebCore::RenderLayer::updateLayerPositions):
1738         (WebCore::expandClipRectForDescendantsAndReflection):
1739         (WebCore::transparencyClipBox):
1740         (WebCore::RenderLayer::convertToLayerCoords):
1741         (WebCore::RenderLayer::paintLayer):
1742         (WebCore::RenderLayer::paintChildLayerIntoColumns):
1743         (WebCore::RenderLayer::createLocalTransformState):
1744         (WebCore::RenderLayer::hitTestChildLayerColumns):
1745         (WebCore::RenderLayer::calculateClipRects):
1746         (WebCore::RenderLayer::calculateRects):
1747         (WebCore::RenderLayer::boundingBox):
1748         (WebCore::RenderLayer::setBackingNeedsRepaintInRect):
1749         * rendering/RenderLayer.h:
1750         * rendering/RenderLayerBacking.cpp:
1751         (WebCore::RenderLayerBacking::updateCompositedBounds):
1752         (WebCore::RenderLayerBacking::updateGraphicsLayerGeometry):
1753         * rendering/RenderLayerCompositor.cpp:
1754         (WebCore::RenderLayerCompositor::calculateCompositedBounds):
1755         (WebCore::RenderLayerCompositor::layerWillBeRemoved):
1756         (WebCore::RenderLayerCompositor::recursiveRepaintLayerRect):
1757
1758 2011-06-01  Roland Steiner  <rolandsteiner@chromium.org>
1759
1760         Reviewed by Kent Tamura.
1761
1762         Remove superfluous renderer() test
1763         https://bugs.webkit.org/show_bug.cgi?id=61907
1764
1765         No new tests. (trivial)
1766
1767         * dom/Document.cpp:
1768         (WebCore::Document::recalcStyle):
1769
1770 2011-06-01  Levi Weintraub  <leviw@chromium.org>
1771
1772         Reviewed by Hajime Morita.
1773
1774         Add IntPoint + IntPoint operator
1775         https://bugs.webkit.org/show_bug.cgi?id=61876
1776
1777         Adding an operator+ convenience method to IntPoint that sums two points
1778         and returns the result as an IntPoint. Changing doImageDrag to use it
1779         as a proof of concept.
1780
1781         No new tests since there is no change in behavior.
1782
1783         * page/DragController.cpp:
1784         (WebCore::DragController::doImageDrag):
1785         * platform/graphics/IntPoint.h:
1786         (WebCore::operator+):
1787
1788 2011-06-01  Jaehun Lim  <ljaehun.lim@samsung.com>
1789
1790         Reviewed by Eric Seidel.
1791
1792         [EFL] Add adjustMenuListButtonStyle and paintMenuListButton functions
1793         https://bugs.webkit.org/show_bug.cgi?id=61836
1794
1795         Add functions for rendering drop-down list when style attributes are applied.
1796
1797         * platform/efl/RenderThemeEfl.cpp:
1798         (WebCore::RenderThemeEfl::adjustMenuListButtonStyle):
1799         (WebCore::RenderThemeEfl::paintMenuListButton):
1800         * platform/efl/RenderThemeEfl.h:
1801
1802 2011-06-01  Yuta Kitamura  <yutak@chromium.org>
1803
1804         Reviewed by Kent Tamura.
1805
1806         WebSocket: WebSocketChannel::fail() should close the connection immediately
1807         https://bugs.webkit.org/show_bug.cgi?id=61851
1808
1809         The effect of this change is almost unobservable. The difference between m_handle->close() and
1810         m_handle->disconnect() is that the former does not close the connection if the handle has
1811         unsent data while the latter immediately closes the connection regardless of unsent data.
1812         Usually a socket stream handle does not have unsent data, and even if it has any, it is hard
1813         for user scripts to observe the difference between close() and disconnect() (it should take some time
1814         for onclose() to be called if there are any unsent data, but there ought to be no other difference
1815         in user scripts' perspective).
1816
1817         No new tests are added, because writing a test for this issue is not feasible due to the above reason.
1818
1819         * websockets/WebSocketChannel.cpp:
1820         (WebCore::WebSocketChannel::fail): Use m_handle->disconnect() instead of m_handle->close().
1821
1822 2011-06-01  Abhishek Arya  <inferno@chromium.org>
1823
1824         Unreviewed.
1825
1826         Coding style nit. Move ec=0 initialization, change
1827         recommended by Alexey in bug.
1828         https://bugs.webkit.org/show_bug.cgi?id=60831
1829
1830         * dom/Document.cpp:
1831         (WebCore::Document::setBody):
1832
1833 2011-06-01  Hayato Ito  <hayato@chromium.org>
1834
1835         Reviewed by Kent Tamura.
1836
1837         Move {Next,Previous}FocusableNode functions from Document to FocusController.
1838         https://bugs.webkit.org/show_bug.cgi?id=61839
1839
1840         There are some member functions in Document which use 'this'
1841         pointer, but we should use TreeScope instead of Document in some
1842         places to handle focus issues nicely. We have to move these
1843         functions out of Document class so that we can give the TreeScope
1844         as a parameter.
1845
1846         No new tests since no functionality was changed.
1847
1848         * dom/Document.cpp:
1849         * dom/Document.h:
1850         * page/FocusController.cpp:
1851         (WebCore::FocusController::deepFocusableNode):
1852         (WebCore::FocusController::advanceFocusInDocumentOrder):
1853         (WebCore::nextNodeWithExactTabIndex):
1854         (WebCore::previousNodeWithExactTabIndex):
1855         (WebCore::nextNodeWithGreaterTabIndex):
1856         (WebCore::previousNodeWithLowerTabIndex):
1857         (WebCore::FocusController::nextFocusableNode):
1858         (WebCore::FocusController::previousFocusableNode):
1859         * page/FocusController.h:
1860
1861 2011-06-01  Adrienne Walker  <enne@google.com>
1862
1863         Reviewed by James Robinson.
1864
1865         [chromium] Fix syncing of removed mask and replica layers
1866         https://bugs.webkit.org/show_bug.cgi?id=61895
1867
1868         * platform/graphics/chromium/TreeSynchronizer.cpp:
1869         (WebCore::TreeSynchronizer::synchronizeTreeRecursive):
1870
1871 2011-06-01  Julien Chaffraix  <jchaffraix@codeaurora.org>
1872
1873         Reviewed by Simon Fraser.
1874
1875         CSSStyleSheet#insertRule doesn't work well with imported stylesheets
1876         https://bugs.webkit.org/show_bug.cgi?id=56981
1877
1878         Test: fast/css/import-and-insert-rule-no-update.html
1879
1880         The bug arises from the fact that <link> element did not know about a programmatically
1881         loading sheet (using insertRule and @import) and would thus never call removePendingSheet.
1882         This is needed to make sure our style selector contains an up-to-date list of stylesheets.
1883
1884         The gist of the patch adds a way for style sheet owner element to know if we are
1885         programmatically loading a style sheet. This is needed as <link> keeps the information
1886         about that last loaded stylesheet.
1887
1888         * css/CSSImportRule.cpp:
1889         (WebCore::CSSImportRule::insertedIntoParent): Call startLoadingDynamicSheet
1890         on our parent style sheet instead of directly adding a pending style sheet.
1891
1892         * css/CSSStyleSheet.cpp:
1893         (WebCore::CSSStyleSheet::startLoadingDynamicSheet): Call startLoadingDynamicSheet
1894         on our owner element if we have one.
1895
1896         * css/CSSStyleSheet.h:
1897         * dom/Node.h:
1898         (WebCore::Node::startLoadingDynamicSheet): Added common implementation of
1899         startLoadingDynamicSheet, which should never be called.
1900
1901         * dom/StyleElement.cpp:
1902         (WebCore::StyleElement::startLoadingDynamicSheet):
1903         * dom/StyleElement.h:
1904         Common implementation of startLoadingDynamicSheet for style elements.
1905
1906         * html/HTMLLinkElement.cpp:
1907         (WebCore::HTMLLinkElement::startLoadingDynamicSheet):
1908         * html/HTMLLinkElement.h:
1909         Use the HTMLLinkElement plumbing to make sure we call addRemovePendingSheet.
1910
1911         * html/HTMLStyleElement.h:
1912         (WebCore::HTMLStyleElement::startLoadingDynamicSheet):
1913         * svg/SVGStyleElement.h:
1914         (WebCore::SVGStyleElement::startLoadingDynamicSheet):
1915         Forward the call to StyleElement.
1916
1917 2011-06-01  Levi Weintraub  <leviw@chromium.org>
1918
1919         Reviewed by Eric Seidel.
1920
1921         Switch paintCustomHighlight to use IntPoint
1922         https://bugs.webkit.org/show_bug.cgi?id=61562
1923
1924         Switching paintCustomHighlight to use an IntPoint for
1925         its paint offset instead of a pair of ints.
1926
1927         No new tests since this is refactoring.
1928
1929         * rendering/InlineTextBox.cpp:
1930         (WebCore::InlineTextBox::paint):
1931         (WebCore::InlineTextBox::paintCustomHighlight):
1932         * rendering/InlineTextBox.h:
1933         * rendering/RenderBox.cpp:
1934         (WebCore::RenderBox::paintCustomHighlight):
1935         * rendering/RenderBox.h:
1936         * rendering/RenderImage.cpp:
1937         (WebCore::RenderImage::paintReplaced):
1938         * rendering/RenderListMarker.cpp:
1939         (WebCore::RenderListMarker::paint):
1940         * rendering/RenderWidget.cpp:
1941         (WebCore::RenderWidget::paint):
1942         * rendering/RootInlineBox.cpp:
1943         (WebCore::RootInlineBox::paintCustomHighlight):
1944         (WebCore::RootInlineBox::paint):
1945         * rendering/RootInlineBox.h:
1946
1947 2011-06-01  Emil A Eklund  <eae@chromium.org>
1948
1949         Reviewed by Eric Seidel.
1950
1951         Switch MouseRelatedEvent to use IntPoint
1952         https://bugs.webkit.org/show_bug.cgi?id=61574
1953
1954         Covered by existing tests.
1955
1956         * dom/MouseEvent.cpp:
1957         (WebCore::MouseEvent::MouseEvent):
1958         (WebCore::MouseEvent::initMouseEvent):
1959         (WebCore::SimulatedMouseEvent::SimulatedMouseEvent):
1960         * dom/MouseRelatedEvent.cpp:
1961         (WebCore::MouseRelatedEvent::MouseRelatedEvent):
1962         (WebCore::contentsScrollOffset):
1963         (WebCore::MouseRelatedEvent::initCoordinates):
1964         (WebCore::MouseRelatedEvent::computeRelativePosition):
1965         (WebCore::MouseRelatedEvent::layerX):
1966         (WebCore::MouseRelatedEvent::layerY):
1967         (WebCore::MouseRelatedEvent::offsetX):
1968         (WebCore::MouseRelatedEvent::offsetY):
1969         (WebCore::MouseRelatedEvent::pageX):
1970         (WebCore::MouseRelatedEvent::pageY):
1971         (WebCore::MouseRelatedEvent::pageLocation):
1972         (WebCore::MouseRelatedEvent::x):
1973         (WebCore::MouseRelatedEvent::y):
1974         * dom/MouseRelatedEvent.h:
1975         (WebCore::MouseRelatedEvent::screenX):
1976         (WebCore::MouseRelatedEvent::screenY):
1977         (WebCore::MouseRelatedEvent::screenLocation):
1978         (WebCore::MouseRelatedEvent::clientX):
1979         (WebCore::MouseRelatedEvent::clientY):
1980         (WebCore::MouseRelatedEvent::clientLocation):
1981         (WebCore::MouseRelatedEvent::absoluteLocation):
1982         * dom/TouchEvent.cpp:
1983         (WebCore::TouchEvent::TouchEvent):
1984         (WebCore::TouchEvent::initTouchEvent):
1985         * dom/WheelEvent.cpp:
1986         (WebCore::WheelEvent::WheelEvent):
1987         (WebCore::WheelEvent::initWheelEvent):
1988         (WebCore::WheelEventDispatchMediator::WheelEventDispatchMediator):
1989         * dom/WheelEvent.h:
1990         (WebCore::WheelEvent::create):
1991         (WebCore::WheelEvent::wheelDelta):
1992         (WebCore::WheelEvent::wheelDeltaX):
1993         (WebCore::WheelEvent::wheelDeltaY):
1994         (WebCore::WheelEvent::rawDeltaX):
1995         (WebCore::WheelEvent::rawDeltaY):
1996         (WebCore::WheelEvent::isHorizontal):
1997         * platform/graphics/IntPoint.h:
1998         (WebCore::IntPoint::scale):
1999
2000 2011-06-01  Levi Weintraub  <leviw@chromium.org>
2001
2002         Reviewed by Eric Seidel.
2003
2004         Switch paintOverflowControls to use IntPoint
2005         https://bugs.webkit.org/show_bug.cgi?id=61884
2006
2007         Switching paintOverflowControls to use an IntPoint instead of a pair of ints.
2008
2009         No new tests since this is simple refactoring.
2010
2011         * rendering/RenderBlock.cpp:
2012         (WebCore::RenderBlock::paint):
2013         * rendering/RenderLayer.cpp:
2014         (WebCore::RenderLayer::paintOverflowControls):
2015         (WebCore::RenderLayer::paintLayer):
2016         * rendering/RenderLayer.h:
2017         * rendering/RenderLayerBacking.cpp:
2018         (WebCore::RenderLayerBacking::paintIntoLayer):
2019
2020 2011-06-01  Abhishek Arya  <inferno@chromium.org>
2021
2022         Reviewed by Alexey Proskuryakov.
2023
2024         Fix setting of document.body
2025         https://bugs.webkit.org/show_bug.cgi?id=60831
2026
2027         1. Only allowing setting to an element if it has a body tag.
2028         2. If element is from another document, import it.
2029
2030         Test: fast/dom/document-set-body.html
2031
2032         * dom/Document.cpp:
2033         (WebCore::Document::setBody):
2034
2035 2011-06-01  Chris Fleizach  <cfleizach@apple.com>
2036
2037         Reviewed by Darin Adler.
2038
2039         Safari always crashes on http://bbc.co.uk when VoiceOver enabled
2040         https://bugs.webkit.org/show_bug.cgi?id=61886
2041
2042         This crash can happen on webpages that remove an element from the DOM when the element receives focus.
2043         When AppKit goes to post a notification to inform VoiceOver the focus has changed, it asks for the AXFocusedUIElement.
2044         However by posting that notification, a render tree update is performed. This causes the element to disappear, but
2045         AppKit still has a handle to it and continues to try to reference it. When the autorelease pool pops, the reference goes bad.
2046
2047         To fix, the root element, the AccessibilityScrollView, needs to implement updateBackingStore(), otherwise this method 
2048         will not be called in time.
2049
2050         No test could be created because to cause it depends on an internal AppKit mechanism
2051         that is only triggered remotely through the accessibility runtime.
2052
2053         * accessibility/AccessibilityObject.cpp:
2054         (WebCore::AccessibilityObject::updateBackingStore):
2055         * accessibility/AccessibilityObject.h:
2056         * accessibility/AccessibilityRenderObject.cpp:
2057         * accessibility/AccessibilityRenderObject.h:
2058
2059 2011-06-01  David Carson  <dacarson@apple.com>
2060
2061         Reviewed by Antti Koivisto.
2062
2063         https://bugs.webkit.org/show_bug.cgi?id=61831
2064         If width and height of an iframe is fixed and should not be visible, then
2065         it shouldn't be flattened.
2066
2067         Test: fast/frames/flattening/iframe-flattening-fixed-width-and-height-zero-size.html
2068
2069         * rendering/RenderIFrame.cpp:
2070         (WebCore::RenderIFrame::flattenFrame): add a check for a zero width or height
2071
2072 2011-06-01  Daniel Cheng  <dcheng@chromium.org>
2073
2074         Reviewed by Tony Chang.
2075
2076         [chromium] Use correct file name for dragging out images.
2077         https://bugs.webkit.org/show_bug.cgi?id=24887
2078
2079         We try to guess an appropriate filename when dragging out images. In order, we try to use:
2080         - The filename suggested in the HTTP header.
2081         - The last path component of the source URL.
2082         - The alt text.
2083         This matches the behavior of the other WebKit ports.
2084
2085         Test: fast/events/drag-image-filename.html
2086
2087         * platform/chromium/ClipboardChromium.cpp:
2088         (WebCore::writeImageToDataObject):
2089         * platform/chromium/ClipboardChromiumMac.cpp:
2090         (WebCore::isInvalidFileCharacter):
2091         (WebCore::ClipboardChromium::validateFileName):
2092
2093 2011-06-01  Levi Weintraub  <leviw@chromium.org>
2094
2095         Reviewed by Eric Seidel.
2096
2097         Text is scaled in a stair-step pattern
2098         https://bugs.webkit.org/show_bug.cgi?id=60317
2099
2100         Stop scaling the specified font to the actual on-screen value when font-rendering: 
2101         geometricPrecision is specified, but instead scale the graphics context. This allows
2102         us to scale text up and down smoothly.
2103
2104         Test: svg/text/scaling-font-with-geometric-precision.html
2105
2106         * rendering/svg/RenderSVGInlineText.cpp:
2107         (WebCore::RenderSVGInlineText::computeNewScaledFontForStyle):
2108
2109 2011-06-01  Levi Weintraub  <leviw@chromium.org>
2110
2111         Reviewed by Eric Seidel.
2112
2113         Switch paintResizer to use IntPoint
2114         https://bugs.webkit.org/show_bug.cgi?id=61883
2115
2116         Switch paintResizer to take an IntPoint instead of a pair of ints.
2117
2118         No new tests as this is simple refactoring.
2119
2120         * rendering/RenderLayer.cpp:
2121         (WebCore::RenderLayer::paintOverflowControls):
2122         (WebCore::RenderLayer::paintResizer):
2123         * rendering/RenderLayer.h:
2124         * rendering/RenderLayerBacking.cpp:
2125         (WebCore::RenderLayerBacking::paintContents):
2126
2127 2011-06-01  Jer Noble  <jer.noble@apple.com>
2128
2129         Reviewed by Darin Adler.
2130
2131         Page layout messed up after exiting full screen at Apple trailers page
2132         https://bugs.webkit.org/show_bug.cgi?id=61755
2133         <rdar://problem/9525277>
2134
2135         Test: fullscreen/full-screen-zIndex-after.html
2136
2137         Fix the incomplete implementation of r87660. Make parameters to
2138         setContainsFullScreenElementRecursively() in webkitWillExitFullScreenForElement() match those
2139         in webkitWillEnterFullScreenForElement(), so the ancestors' flags do not become
2140         inconsistent..
2141
2142         * dom/Document.cpp:
2143         (WebCore::Document::webkitWillExitFullScreenForElement):
2144
2145 2011-06-01  Levi Weintraub  <leviw@chromium.org>
2146
2147         Reviewed by Eric Seidel.
2148
2149         Switch paintScrollCorner to use IntPoint
2150         https://bugs.webkit.org/show_bug.cgi?id=61874
2151
2152         Changing paintScrollCorner to take an IntPoint representing the paint
2153         offset instead of a pair of ints.
2154
2155         No new tests as this is simple refactoring.
2156
2157         * rendering/RenderLayer.cpp:
2158         (WebCore::RenderLayer::paintOverflowControls):
2159         (WebCore::RenderLayer::paintScrollCorner):
2160         * rendering/RenderLayer.h:
2161         * rendering/RenderLayerBacking.cpp:
2162         (WebCore::RenderLayerBacking::paintContents):
2163
2164 2011-06-01  Kenneth Russell  <kbr@google.com>
2165
2166         Reviewed by Nate Chapin.
2167
2168         [V8] Optimize fetches of indexed properties in custom bindings
2169         https://bugs.webkit.org/show_bug.cgi?id=61821
2170
2171         Avoid allocating garbage in affected custom bindings. This speeds
2172         up one test case by at least a factor of two. No new tests;
2173         covered by existing layout tests (typed array and otherwise).
2174
2175         * bindings/v8/custom/V8ArrayBufferViewCustom.h:
2176         (WebCore::constructWebGLArray):
2177         (WebCore::setWebGLArrayHelper):
2178         * bindings/v8/custom/V8InspectorFrontendHostCustom.cpp:
2179         (WebCore::V8InspectorFrontendHost::showContextMenuCallback):
2180         * bindings/v8/custom/V8MessagePortCustom.cpp:
2181         (WebCore::getMessagePortArray):
2182         * bindings/v8/custom/V8WebGLRenderingContextCustom.cpp:
2183         (WebCore::jsArrayToFloatArray):
2184         (WebCore::jsArrayToIntArray):
2185
2186 2011-06-01  Andras Becsi  <abecsi@webkit.org>
2187
2188         Reviewed by Csaba Osztrogonác.
2189
2190         [Qt] Fix the Phonon build when logging is disabled
2191         https://bugs.webkit.org/show_bug.cgi?id=61869
2192
2193         No new tests needed.
2194
2195         * platform/graphics/qt/MediaPlayerPrivatePhonon.cpp: Add missing guards.
2196         (WebCore::MediaPlayerPrivatePhonon::networkState):
2197         (WebCore::MediaPlayerPrivatePhonon::readyState):
2198         (WebCore::MediaPlayerPrivatePhonon::updateStates):
2199         (WebCore::MediaPlayerPrivatePhonon::stateChanged):
2200
2201 2011-06-01  Abhishek Arya  <inferno@chromium.org>
2202
2203         Reviewed by Antti Koivisto.
2204
2205         Do not use the pushed style selector if it is not equal to the
2206         parent document's style selector. It usually means that it is
2207         in a bad state, e.g. already cleared.
2208         https://bugs.webkit.org/show_bug.cgi?id=61737
2209
2210         * dom/Element.cpp:
2211         (WebCore::StyleSelectorParentPusher::~StyleSelectorParentPusher):
2212
2213 2011-06-01  Levi Weintraub  <leviw@chromium.org>
2214
2215         Reviewed by Eric Seidel.
2216
2217         Switch RenderLineBoxList intersection functions to use IntPoint
2218         https://bugs.webkit.org/show_bug.cgi?id=61794
2219
2220         Switching rangeIntersectsRect, anyLineIntersectsRect, and lineIntersectsDirtyRect
2221         to take IntPoint instead of a tx/ty to represent the offset to be applied match
2222         the rect and lines' coordinates.
2223
2224         No new tests since this is merely refactoring.
2225
2226         * rendering/RenderLineBoxList.cpp:
2227         (WebCore::RenderLineBoxList::rangeIntersectsRect):
2228         (WebCore::RenderLineBoxList::anyLineIntersectsRect):
2229         (WebCore::RenderLineBoxList::lineIntersectsDirtyRect):
2230         (WebCore::RenderLineBoxList::paint):
2231         (WebCore::RenderLineBoxList::hitTest):
2232         * rendering/RenderLineBoxList.h:
2233
2234 2011-05-19  Adrienne Walker  <enne@google.com>
2235
2236         Reviewed by James Robinson.
2237
2238         [chromium] Don't split long, narrow layers into multiple tiles.
2239         https://bugs.webkit.org/show_bug.cgi?id=60821
2240
2241         This changes the heuristic for when we tile layers to be less bad
2242         about wasting texture space.  Long, narrow layers that are tiled with
2243         a large tile size waste texture space.  Now layers are only tiled if
2244         they are above 512px in one dimension and extend into a second tile in
2245         the other.  If they are not tiled, their layer texture will exactly
2246         fit their layer bounds.  In particular, this will help scrollbars.
2247
2248         * platform/graphics/chromium/ContentLayerChromium.cpp:
2249         (WebCore::ContentLayerChromium::updateLayerSize):
2250         * platform/graphics/chromium/LayerRendererChromium.h:
2251         (WebCore::LayerRendererChromium::maxTextureSize):
2252
2253 2011-06-01  Cary Clark  <caryclark@google.com>
2254
2255         Reviewed by Eric Seidel.
2256
2257         Ready Chromium port for Skia on Mac
2258         https://bugs.webkit.org/show_bug.cgi?id=61800
2259
2260         Skia on Mac is not enabled. The executing
2261         code is unchanged, so there are no new tests.
2262
2263         * platform/chromium/DragImageRef.h:
2264         Use Skia for DragImageRef instead of CG.
2265
2266         * platform/chromium/ScrollbarThemeChromiumMac.mm:
2267         (WebCore::ScrollbarThemeChromiumMac::paint):
2268         Get the total matrix from Skia for the scrollbar.
2269         Convert the SkCanvas into a CGContext to draw.
2270
2271         * platform/chromium/ThemeChromiumMac.mm:
2272         (WebCore::paintStepper):
2273         Ditto.
2274
2275 2011-06-01  Yury Semikhatsky  <yurys@chromium.org>
2276
2277         Reviewed by Pavel Feldman.
2278
2279         Web Inspector: allow opening inspector for existing workers
2280         https://bugs.webkit.org/show_bug.cgi?id=61853
2281
2282         Added sidebar pane with a list of all workers. Each worker has a check box
2283         that allows opening inspector for the worker.
2284
2285         * inspector/Inspector.json:
2286         * inspector/InspectorInstrumentation.cpp:
2287         (WebCore::InspectorInstrumentation::didStartWorkerContextImpl):
2288         * inspector/InspectorInstrumentation.h:
2289         (WebCore::InspectorInstrumentation::didStartWorkerContext):
2290         * inspector/InspectorWorkerAgent.cpp:
2291         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::WorkerFrontendChannel):
2292         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::~WorkerFrontendChannel):
2293         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::connectToWorkerContext):
2294         (WebCore::InspectorWorkerAgent::WorkerFrontendChannel::disconnectFromWorkerContext):
2295         (WebCore::InspectorWorkerAgent::clearFrontend):
2296         (WebCore::InspectorWorkerAgent::connectToWorker):
2297         (WebCore::InspectorWorkerAgent::disconnectFromWorker):
2298         (WebCore::InspectorWorkerAgent::didStartWorkerContext):
2299         * inspector/InspectorWorkerAgent.h:
2300         * inspector/front-end/ScriptsPanel.js:
2301         (WebInspector.ScriptsPanel):
2302         * inspector/front-end/Settings.js:
2303         * inspector/front-end/WorkerManager.js:
2304         (WebInspector.WorkerManager):
2305         (WebInspector.WorkerManager.prototype._workerCreated):
2306         (WebInspector.WorkerManager.prototype._sendMessageToWorkerInspector):
2307         (WebInspector.WorkerManager.prototype.openWorkerInspector):
2308         (WebInspector.WorkerManager.prototype.closeWorkerInspector):
2309         (WebInspector.WorkerManager.prototype._workerInspectorClosing):
2310         (WebInspector.WorkerMessageForwarder):
2311         (WebInspector.WorkerMessageForwarder.prototype.workerCreated):
2312         (WebInspector.WorkerMessageForwarder.prototype.dispatchMessageFromWorker):
2313         * inspector/front-end/WorkersSidebarPane.js:
2314         (WebInspector.WorkersSidebarPane):
2315         (WebInspector.WorkersSidebarPane.prototype.addWorker):
2316         (WebInspector.WorkerListSidebarPane):
2317         (WebInspector.WorkerListSidebarPane.prototype._workerAdded):
2318         (WebInspector.WorkerListSidebarPane.prototype._workerRemoved):
2319         (WebInspector.WorkerListSidebarPane.prototype._workerInspectorClosed):
2320         (WebInspector.WorkerListSidebarPane.prototype._addWorker):
2321         (WebInspector.WorkerListSidebarPane.prototype._createCheckbox):
2322         (WebInspector.WorkerListSidebarPane.prototype._workerItemClicked):
2323         * workers/Worker.cpp:
2324         (WebCore::Worker::notifyFinished):
2325
2326 2011-06-01  Shishir Agrawal  <shishir@chromium.org>
2327
2328         Reviewed by Tony Gentilcore.
2329
2330         Renaming the Page Visibility attributes as per the modified spec draft.
2331         https://bugs.webkit.org/show_bug.cgi?id=61825
2332
2333         Spec draft:
2334         http://dvcs.w3.org/hg/webperf/raw-file/tip/specs/PageVisibility/Overview.html
2335
2336         - Event needs to be webkitVisibilityChange from webkitVisibilityStateChange
2337         - The attribute webkitIsVisible needs to change to webkitHidden
2338
2339         * dom/Document.cpp:
2340         (WebCore::Document::webkitHidden):
2341         (WebCore::Document::dispatchVisibilityStateChangeEvent):
2342         * dom/Document.h:
2343         * dom/Document.idl:
2344         * dom/EventNames.h:
2345
2346 2011-06-01  Nikolas Zimmermann  <nzimmermann@rim.com>
2347
2348         Reviewed by Rob Buis.
2349
2350         Remove duplicated code in various computeReplacedLogical*() functions
2351         https://bugs.webkit.org/show_bug.cgi?id=61860
2352
2353         Centralize this calculation in RenderBox::computeReplacedLogicalWidthRespectingMinMaxWidth:
2354         int minLogicalWidth = computeReplacedLogicalWidthUsing(style()->logicalMinWidth());
2355         int maxLogicalWidth = !includeMaxWidth || style()->logicalMaxWidth().isUndefined() ? logicalWidth : computeReplacedLogicalWidthUsing(style()->logicalMaxWidth());
2356         return max(minLogicalWidth, min(logicalWidth, maxLogicalWidth));
2357
2358         Centralize this calculation in RenderBox::computeReplacedLogicalHeightRespectingMinMaxHeight:
2359         int minLogicalHeight = computeReplacedLogicalHeightUsing(style()->logicalMinHeight());
2360         int maxLogicalHeight = style()->logicalMaxHeight().isUndefined() ? logicalHeight : computeReplacedLogicalHeightUsing(style()->logicalMaxHeight());
2361         return max(minLogicalHeight, min(logicalHeight, maxLogicalHeight));
2362
2363         Use the new helper methods where possible, deduplicating lots of code.
2364
2365         * rendering/RenderBox.cpp:
2366         (WebCore::RenderBox::computeReplacedLogicalWidth):
2367         (WebCore::RenderBox::computeReplacedLogicalWidthRespectingMinMaxWidth):
2368         (WebCore::RenderBox::computeReplacedLogicalHeight):
2369         (WebCore::RenderBox::computeReplacedLogicalHeightRespectingMinMaxHeight):
2370         * rendering/RenderBox.h:
2371         * rendering/RenderImage.cpp:
2372         (WebCore::RenderImage::computeReplacedLogicalWidth):
2373         (WebCore::RenderImage::computeReplacedLogicalHeight):
2374         * rendering/RenderPart.cpp:
2375         (WebCore::RenderPart::computeEmbeddedDocumentReplacedWidth):
2376         (WebCore::RenderPart::computeEmbeddedDocumentReplacedHeight):
2377         (WebCore::RenderPart::computeReplacedLogicalWidth):
2378         (WebCore::RenderPart::computeReplacedLogicalHeight):
2379         * rendering/RenderPart.h:
2380         * rendering/RenderReplaced.cpp:
2381         (WebCore::RenderReplaced::computeReplacedLogicalWidth):
2382         (WebCore::RenderReplaced::computeReplacedLogicalHeight):
2383         * rendering/svg/RenderSVGRoot.cpp:
2384         (WebCore::RenderSVGRoot::computeReplacedLogicalWidth):
2385         (WebCore::RenderSVGRoot::computeReplacedLogicalHeight):
2386
2387 2011-06-01  Sheriff Bot  <webkit.review.bot@gmail.com>
2388
2389         Unreviewed, rolling out r87788.
2390         http://trac.webkit.org/changeset/87788
2391         https://bugs.webkit.org/show_bug.cgi?id=61856
2392
2393         breaks windows chromium canary (Requested by jknotten on
2394         #webkit).
2395
2396         * loader/archive/mhtml/MHTMLArchive.cpp:
2397         * loader/archive/mhtml/MHTMLArchive.h:
2398         * page/PageSerializer.cpp:
2399         (WebCore::PageSerializer::serializeFrame):
2400         (WebCore::PageSerializer::serializeCSSStyleSheet):
2401         * platform/SharedBuffer.cpp:
2402         * platform/SharedBuffer.h:
2403
2404 2011-06-01  Joseph Pecoraro  <joepeck@webkit.org>
2405
2406         Reviewed by Pavel Feldman.
2407
2408         Web Inspector: [JSC] JSLock ASSERTs Seen Under eventListenerHandlerBody
2409         https://bugs.webkit.org/show_bug.cgi?id=61835
2410
2411         Add a JSLock call before possible allocations in jsFunction and toString.
2412
2413         * bindings/js/ScriptEventListener.cpp:
2414         (WebCore::eventListenerHandlerBody):
2415
2416 2011-06-01  Jay Civelli  <jcivelli@chromium.org>
2417
2418         Reviewed by Adam Barth.
2419
2420         Adding MHTML generation support to MHTMLArchive.
2421         https://bugs.webkit.org/show_bug.cgi?id=7169
2422
2423         * loader/archive/mhtml/MHTMLArchive.cpp:
2424         (WebCore::generateRandomBoundary):
2425         (WebCore::replaceNonPrintableCharacters):
2426         (WebCore::MHTMLArchive::generateMHTMLData):
2427         * loader/archive/mhtml/MHTMLArchive.h:
2428         * page/PageSerializer.cpp:
2429         (WebCore::PageSerializer::serializeFrame):
2430         (WebCore::PageSerializer::serializeCSSStyleSheet):
2431         * platform/SharedBuffer.cpp:
2432         (WebCore::SharedBuffer::append):
2433         * platform/SharedBuffer.h:
2434
2435 2011-06-01  Dimitri Glazkov  <dglazkov@chromium.org>
2436
2437         Reviewed by Kent Tamura.
2438
2439         Remove ShadowElement and compact remaining used bits into RenderFileUploadControl.
2440         https://bugs.webkit.org/show_bug.cgi?id=61816
2441
2442         This is a near-mechanical move-and-rename of ShadowElement, which is now only
2443         used by input[type=file]. Next step -- switch it over to new shadow DOM.
2444
2445         Refactoring, no change in behavior.
2446
2447         * CMakeLists.txt: Removed ShadowElement.cpp and ShadowElement.h.
2448         * GNUmakefile.list.am: Ditto.
2449         * WebCore.gypi: Ditto.
2450         * WebCore.pro: Ditto.
2451         * WebCore/WebCore.vcproj/WebCore.vcproj: Ditto.
2452         * WebCore.xcodeproj/project.pbxproj: Ditto.
2453         * WebCore/rendering/RenderingAllInOne.cpp: Ditto.
2454         * rendering/RenderFileUploadControl.cpp:
2455         (WebCore::UploadButton::create): Moved from ShadowElement, renamed as UploadButton.
2456         (WebCore::UploadButton::detach): Ditto.
2457         (WebCore::UploadButton::UploadButton): Ditto.
2458         (WebCore::RenderFileUploadControl::updateFromElement): Changed to use UploadButton.
2459         * rendering/RenderMeter.cpp: Removed ShadowElement.h include, which is no longer used.
2460         * rendering/RenderProgress.cpp: Ditto.
2461         * rendering/ShadowElement.cpp: Removed.
2462         * rendering/ShadowElement.h: Removed.
2463
2464 2011-06-01  Nikolas Zimmermann  <nzimmermann@rim.com>
2465
2466         Reviewed by Rob Buis.
2467
2468         SVG fails all 3 of Hixie's CSS intrinsic sizing tests
2469         https://bugs.webkit.org/show_bug.cgi?id=15473
2470
2471         Hixies CSS intrinsic sizing tests cover percentage sizes specified on the target SVG document as width/height attributes
2472         and using width: auto / height: auto on the <object> that hosts the SVG document. Take percentage sizes of the outermost
2473         SVGs width/height attributes into account when determining the intrinsic size of the <object>.
2474
2475         Added several other testcases demonstrating several scenarios. All tests work exactly the same in WebKit and Firefox now.
2476         The *on-target-svg-absolute.xhtml tests look equal to WebKit/FF but Opera fails them, likely a relict of the different
2477         interpretation of the intrinsic size of a SVG document in SVG Tiny 1.2.
2478
2479         Tests: svg/custom/object-sizing-height-50p-on-target-svg-absolute.xhtml
2480                svg/custom/object-sizing-height-50p-on-target-svg.xhtml
2481                svg/custom/object-sizing-width-50p-height-50p-on-target-svg-absolute.xhtml
2482                svg/custom/object-sizing-width-50p-height-50p-on-target-svg.xhtml
2483                svg/custom/object-sizing-width-50p-height-75p-on-target-svg-absolute.xhtml
2484                svg/custom/object-sizing-width-50p-height-75p-on-target-svg.xhtml
2485                svg/custom/object-sizing-width-50p-on-target-svg-absolute.xhtml
2486                svg/custom/object-sizing-width-50p-on-target-svg.xhtml
2487                svg/custom/object-sizing-width-75p-height-50p-on-target-svg-absolute.xhtml
2488                svg/custom/object-sizing-width-75p-height-50p-on-target-svg.xhtml
2489                svg/hixie/intrinsic/001.html
2490                svg/hixie/intrinsic/002.html
2491                svg/hixie/intrinsic/003.html
2492
2493         * rendering/RenderPart.cpp:
2494         (WebCore::RenderPart::computeReplacedLogicalWidth):
2495         (WebCore::RenderPart::computeReplacedLogicalHeight):
2496         * rendering/svg/RenderSVGRoot.cpp:
2497         (WebCore::RenderSVGRoot::computeIntrinsicRatio):
2498         * rendering/svg/RenderSVGRoot.h:
2499
2500 2011-05-31  Tonis Tiigi  <tonistiigi@gmail.com>
2501
2502         Reviewed by Pavel Feldman.
2503
2504         Web Inspector: Timeline panel improvements for managing current selection
2505         https://bugs.webkit.org/show_bug.cgi?id=61468
2506
2507         Enables X-axis dragging of the selected area.
2508         Double click zoom-out.
2509         Fixes slightly wrong selection area position.
2510
2511         * inspector/front-end/TimelineOverviewPane.js:
2512         (WebInspector.TimelineOverviewPane):
2513         (WebInspector.TimelineOverviewPane.prototype._dragWindow):
2514         (WebInspector.TimelineOverviewPane.prototype._endWindowSelectorDragging):
2515         (WebInspector.TimelineOverviewPane.prototype._resizeWindowRight):
2516         (WebInspector.TimelineOverviewPane.prototype._resizeWindowMaximum):
2517         (WebInspector.TimelineOverviewPane.prototype.scrollWindow):
2518         (WebInspector.TimelineOverviewPane.prototype._createTimelineCategoryStatusBarCheckbox):
2519         * inspector/front-end/TimelinePanel.js:
2520         (WebInspector.TimelinePanel):
2521
2522 2011-05-31  Keishi Hattori  <keishi@webkit.org>
2523
2524         Reviewed by Kent Tamura.
2525
2526         Fix to enable page scroll of select element
2527         https://bugs.webkit.org/show_bug.cgi?id=53628
2528
2529         Manual test: select-page-scroll.html
2530
2531         * manual-tests/select-page-scroll.html: Added.
2532         * rendering/RenderListBox.cpp:
2533         (WebCore::RenderListBox::computeLogicalHeight): Fix min to max.
2534
2535 2011-05-31  Yong Li  <yoli@rim.com>
2536
2537         Reviewed by Eric Seidel.
2538
2539         https://bugs.webkit.org/show_bug.cgi?id=54807
2540         We have been assuming plain bitfields (like "int a : 31") are always signed integers.
2541         However some compilers can treat them as unsigned. For example, RVCT 4.0 states plain
2542         bitfields (declared without either signed or unsigned qualifiers) are treats as unsigned.
2543         http://infocenter.arm.com/help/index.jsp?topic=/com.arm.doc.dui0348c/Babjddhe.html
2544         Although we can use "--signed-bitfields" flag to make RVCT 4.0 behave as most other compilers,
2545         always using "signed"/"unsigned" qualifier to declare integral type bitfields is still a good
2546         rule we should have in order to make our code independent from compilers and compiler flags.
2547
2548         No new test added because this change is not known to fix any issue.
2549
2550         * css/CSSPrimitiveValue.h:
2551         * css/CSSProperty.h:
2552         * rendering/InlineBox.h:
2553         * rendering/RenderBlock.h:
2554
2555 2011-05-31  Hironori Bono  <hbono@chromium.org>
2556
2557         Reviewed by Eric Seidel.
2558
2559         Send an input event when we change the text direction.
2560         https://bugs.webkit.org/show_bug.cgi?id=50952
2561
2562         Both Safari and Chrome call Editor::setBaseWritingDirection() to change
2563         the text direction of an editable element with their UIs. This change
2564         calls dispatchInputEvent() to send an input event when the function
2565         actually changes the "dir" attribute so we can send an input event as
2566         written in the HTML5 spec.
2567
2568         Test: fast/html/set-text-direction.html
2569
2570         * editing/Editor.cpp:
2571         (WebCore::Editor::setBaseWritingDirection):
2572
2573 2011-05-31  Jer Noble  <jer.noble@apple.com>
2574
2575         Reviewed by Darin Adler.
2576
2577         Flash of black at the end of full screen transition at apple.com product videos
2578         https://bugs.webkit.org/show_bug.cgi?id=61756
2579
2580         Added two new entries to the WebCore exports list.
2581
2582         * WebCore.exp.in:
2583
2584 2011-05-31  Rafael Brandao  <rafael.lobo@openbossa.org>
2585
2586         Reviewed by Andreas Kling.
2587
2588         [Qt] tst_QWebFrame::render() failing
2589         https://bugs.webkit.org/show_bug.cgi?id=60893
2590
2591         Due a problem on QPicture (http://bugreports.qt.nokia.com/browse/QTBUG-19496),
2592         this test was calculating the final geometry incorrectly. As the order between
2593         a translate and a draw operation could be relevant for it, but not for the
2594         final rendered result, they were changed on ScrollbarThemeQt::paint.
2595
2596         * platform/qt/ScrollbarThemeQt.cpp:
2597         (WebCore::ScrollbarThemeQt::paint):
2598
2599 2011-05-27  Adrienne Walker  <enne@google.com>
2600
2601         Reviewed by James Robinson.
2602
2603         [chromium] Fix crash from empty reflections with masks
2604         https://bugs.webkit.org/show_bug.cgi?id=61654
2605
2606         Change the iteration for updateCompositorResources to match that being
2607         done in the paint and draw steps.  This mismatch of iteration style
2608         was causing layers with replica masks to correctly get skipped while
2609         painting but not get skipped during texture upload.
2610
2611         Test: compositing/reflections/empty-reflection-with-mask.html
2612
2613         * platform/graphics/chromium/LayerRendererChromium.cpp:
2614         (WebCore::LayerRendererChromium::updateLayers):
2615         (WebCore::LayerRendererChromium::updateCompositorResources):
2616         * platform/graphics/chromium/LayerRendererChromium.h:
2617
2618 2011-05-31  B.J. Wever  <skylined@chromium.org>
2619
2620         Reviewed by Adam Barth.
2621
2622         requestFileSystem and resolveLocalFileSystemURI are not checking if
2623         errorCallback is NULL before scheduling a callback on error.
2624         https://bugs.webkit.org/show_bug.cgi?id=49539
2625
2626         Test: fast/filesystem/filesystem-no-callback-null-ptr-crash.html
2627
2628         * fileapi/DOMFileSystem.cpp:
2629         (WebCore::DOMFileSystem::scheduleCallback): Only call callback if
2630           one is supplied.
2631
2632 2011-05-31  Brady Eidson  <beidson@apple.com>
2633
2634         Reviewed by Darin Adler.
2635
2636         Another swipe at resolving <rdar://problem/9125145> and https://bugs.webkit.org/show_bug.cgi?id=61494
2637         
2638         Re-land http://trac.webkit.org/changeset/87566 with invalid ASSERTs removed.
2639
2640         No new tests. No change in behavior.
2641
2642         Instead of storing the DocumentLoader at construction and never changing it,
2643         always calculate it based on the FrameLoader's current DocumentLoader:
2644         * dom/Document.cpp:
2645         (WebCore::Document::Document):
2646         (WebCore::Document::suggestedMIMEType):
2647         (WebCore::Document::lastModified):
2648         (WebCore::Document::initSecurityContext):
2649         (WebCore::Document::updateURLForPushOrReplaceState):
2650         (WebCore::Document::loader):
2651         * dom/Document.h:
2652
2653         Null-check or ASSERT that the DocumentLoader exists (or both) depending on the scenario:
2654         * bindings/ScriptControllerBase.cpp:
2655         (WebCore::ScriptController::executeIfJavaScriptURL):
2656         * html/MediaDocument.cpp:
2657         (WebCore::MediaDocument::replaceMediaElementTimerFired):
2658         * html/PluginDocument.cpp:
2659         (WebCore::PluginDocumentParser::createDocumentStructure):
2660         * platform/mac/HTMLConverter.mm:
2661         (fileWrapperForElement):
2662
2663         * WebCore.exp.in:
2664
2665 2011-05-31  Levi Weintraub  <leviw@chromium.org>
2666
2667         Reviewed by Simon Fraser.
2668
2669         Change InlineBox::paint and its overloaded variants to use IntPoint
2670         https://bugs.webkit.org/show_bug.cgi?id=61804
2671
2672         Changing InlineBox::paint, its 7 overloaded variants, and RootInlineBox::paintEllipsisBox
2673         to use IntPoint for their paint offset instead of a pair of ints.
2674
2675         No new tests since this is just a refactoring.
2676
2677         * rendering/EllipsisBox.cpp:
2678         (WebCore::EllipsisBox::paint):
2679         * rendering/EllipsisBox.h:
2680         * rendering/InlineBox.cpp:
2681         (WebCore::InlineBox::paint):
2682         * rendering/InlineBox.h:
2683         * rendering/InlineFlowBox.cpp:
2684         (WebCore::InlineFlowBox::paint):
2685         * rendering/InlineFlowBox.h:
2686         * rendering/InlineTextBox.cpp:
2687         (WebCore::InlineTextBox::paint):
2688         * rendering/InlineTextBox.h:
2689         * rendering/RenderBlock.cpp:
2690         (WebCore::RenderBlock::paintEllipsisBoxes):
2691         * rendering/RenderBoxModelObject.cpp:
2692         (WebCore::RenderBoxModelObject::paintFillLayerExtended):
2693         * rendering/RenderLineBoxList.cpp:
2694         (WebCore::RenderLineBoxList::paint):
2695         * rendering/RootInlineBox.cpp:
2696         (WebCore::RootInlineBox::paintEllipsisBox):
2697         (WebCore::RootInlineBox::paint):
2698         * rendering/RootInlineBox.h:
2699         * rendering/svg/SVGInlineFlowBox.cpp:
2700         (WebCore::SVGInlineFlowBox::paint):
2701         * rendering/svg/SVGInlineFlowBox.h:
2702         * rendering/svg/SVGInlineTextBox.cpp:
2703         (WebCore::SVGInlineTextBox::paint):
2704         * rendering/svg/SVGInlineTextBox.h:
2705         * rendering/svg/SVGRootInlineBox.cpp:
2706         (WebCore::SVGRootInlineBox::paint):
2707         * rendering/svg/SVGRootInlineBox.h:
2708
2709 2011-05-31  James Robinson  <jamesr@chromium.org>
2710
2711         Reviewed by Kenneth Russell.
2712
2713         [chromium] Clear out LayerChromium's m_ccLayerImpl ptr on CCLayerImpl destruction
2714         https://bugs.webkit.org/show_bug.cgi?id=61593
2715
2716         Whenever a CCLayerImpl is being destroyed, clear out its owner's m_ccLayerImpl pointer.
2717         This is extremely defensive and not strictly necessary, but not harmful either.
2718
2719         * platform/graphics/chromium/LayerChromium.h:
2720         * platform/graphics/chromium/cc/CCLayerImpl.cpp:
2721         (WebCore::CCLayerImpl::~CCLayerImpl):
2722
2723 2011-05-31  Stephen White  <senorblanco@chromium.org>
2724
2725         Unreviewed; build fix.
2726
2727         Silence some warnings on the Safari/Mac release build.
2728
2729         * platform/graphics/gpu/TilingData.h:
2730         (WebCore::TilingData::assertTile):
2731
2732 2011-05-31  Justin Novosad  <junov@chromium.org>
2733
2734         Reviewed by Stephen White.
2735
2736         [Chromium] Build fails when ACCELERATED_2D_CANVAS is disabled
2737         https://bugs.webkit.org/show_bug.cgi?id=61790
2738         Changing the build guards in these two files that are required
2739         by the accelerated compositing feature.
2740
2741         * platform/graphics/gpu/LoopBlinnMathUtils.cpp:
2742         * platform/graphics/gpu/TilingData.cpp:
2743
2744 2011-05-31  Justin Novosad  <junov@chromium.org>
2745
2746         Reviewed by Stephen White.
2747
2748         [Chromium] Build fails when ACCELERATED_2D_CANVAS is disabled
2749         https://bugs.webkit.org/show_bug.cgi?id=61790
2750         Changing the build guards in these two files that are required
2751         by the accelerated compositing feature.
2752
2753         * platform/graphics/gpu/LoopBlinnMathUtils.cpp:
2754         * platform/graphics/gpu/TilingData.cpp:
2755
2756 2011-05-31  Rob Buis  <rbuis@rim.com>
2757
2758         Reviewed by Dirk Schulze.
2759
2760         https://bugs.webkit.org/show_bug.cgi?id=34301
2761         Creating <animateMotion> elements via javascript do not execute
2762
2763         https://bugs.webkit.org/show_bug.cgi?id=17043
2764         SVG missing some .idl files
2765
2766         Add missing idl files.
2767
2768         Test: svg/animations/animate-mpath-insert.html
2769
2770         * CMakeLists.txt:
2771         * CodeGenerators.pri:
2772         * WebCore.gypi:
2773         * WebCore.xcodeproj/project.pbxproj:
2774         * svg/SVGAnimateMotionElement.idl: Added.
2775         * svg/SVGMPathElement.idl: Added.
2776
2777 2011-05-31  Robin Dunn  <robin@alldunn.com>
2778
2779         Reviewed by Kevin Ollivier.
2780
2781         [wx] Implement printing support for wxWidgets 2.9.x and above.
2782         
2783         https://bugs.webkit.org/show_bug.cgi?id=61796
2784
2785         * platform/graphics/GraphicsContext.h:
2786         * platform/graphics/wx/FontWx.cpp:
2787         (WebCore::Font::drawGlyphs):
2788         * platform/graphics/wx/GraphicsContextWx.cpp:
2789         (WebCore::GraphicsContextPlatformPrivate::GraphicsContextPlatformPrivate):
2790         (WebCore::GraphicsContext::drawRect):
2791         (WebCore::GraphicsContext::drawLine):
2792         (WebCore::GraphicsContext::drawEllipse):
2793         (WebCore::GraphicsContext::strokeArc):
2794         (WebCore::GraphicsContext::drawConvexPolygon):
2795         (WebCore::GraphicsContext::fillRect):
2796         (WebCore::GraphicsContext::drawLineForText):
2797         (WebCore::GraphicsContext::scale):
2798         (WebCore::GraphicsContext::currentScale):
2799         * platform/wx/wxcode/win/non-kerned-drawing.cpp:
2800         (WebCore::drawTextWithSpacing):
2801
2802 2011-05-31  Joseph Pecoraro  <joepeck@webkit.org>
2803
2804         Reviewed by Pavel Feldman.
2805
2806         Web Inspector: Missing InspectorFrontendHost.saveSessionSetting function
2807         https://bugs.webkit.org/show_bug.cgi?id=61751
2808
2809         Add missing stub function causing an error on load.
2810
2811         * inspector/front-end/InspectorFrontendHostStub.js:
2812         (.WebInspector.InspectorFrontendHostStub.prototype.saveSessionSetting):
2813
2814 2011-05-31  Abhishek Arya  <inferno@chromium.org>
2815
2816         Reviewed by Dimitri Glazkov.
2817
2818         Improve hasMediaControls logic to check that node has
2819         media controls. This can be false when cloning nodes.
2820         https://bugs.webkit.org/show_bug.cgi?id=61765
2821
2822         Test: media/media-controls-clone-crash.html
2823
2824         * dom/Node.h:
2825         (WebCore::Node::isMediaControls):
2826         * html/HTMLMediaElement.cpp:
2827         (WebCore::HTMLMediaElement::mediaControls):
2828         (WebCore::HTMLMediaElement::hasMediaControls):
2829         * html/shadow/MediaControls.h:
2830         (WebCore::MediaControls::isMediaControls):
2831         (WebCore::toMediaControls):
2832
2833 2011-05-31  Xan Lopez  <xlopez@igalia.com>
2834
2835         Reviewed by Martin Robinson.
2836
2837         [GTK] Provide custom DOM bindings methods to check if input/textareas have been edited
2838         https://bugs.webkit.org/show_bug.cgi?id=61791
2839
2840         * bindings/gobject/GNUmakefile.am: add new files.
2841         * bindings/gobject/WebKitDOMCustom.cpp: Added.
2842         (webkit_dom_html_text_area_element_is_edited):
2843         (webkit_dom_html_input_element_is_edited):
2844         * bindings/gobject/WebKitDOMCustom.h: Added.
2845
2846 2011-05-31  Noam Rosenthal  <noam.rosenthal@nokia.com>
2847
2848         Unreviewed build fix for Symbian.
2849         Opt-out Symbian for TextureMapper.
2850
2851         No new tests: build fix.
2852
2853         * WebCore.pri:
2854
2855 2011-05-31  Levi Weintraub  <leviw@chromium.org>
2856
2857         Reviewed by Eric Seidel.
2858
2859         Switch paintFocusRing to IntPoint
2860         https://bugs.webkit.org/show_bug.cgi?id=61580
2861
2862         Switching paintFocusRing to take an IntPoint representing the paint offset
2863         instead of a pair of ints.
2864
2865         No new tests as this is just refactoring.
2866
2867         * rendering/RenderInline.cpp:
2868         (WebCore::RenderInline::paintOutline):
2869         * rendering/RenderObject.cpp:
2870         (WebCore::RenderObject::paintFocusRing):
2871         (WebCore::RenderObject::paintOutline):
2872         * rendering/RenderObject.h:
2873
2874 2011-05-31  Abhishek Arya  <inferno@chromium.org>
2875
2876         Reviewed by Dimitri Glazkov.
2877
2878         Convert raw ptr to RefPtr for documentElement.
2879         https://bugs.webkit.org/show_bug.cgi?id=61688
2880
2881         Test: fast/dom/xml-parser-error-message-crash.svg
2882
2883         * dom/XMLDocumentParser.cpp:
2884         (WebCore::XMLDocumentParser::insertErrorMessageBlock):
2885
2886 2011-05-31  Andreas Kling  <kling@webkit.org>
2887
2888         Reviewed by Antti Koivisto.
2889
2890         Canvas/JSC: Auto-generate overloads for setShadow()
2891         https://bugs.webkit.org/show_bug.cgi?id=61786
2892
2893         Move CanvasRenderingContext2D.setShadow() to auto-generated JSC bindings.
2894
2895         There is a subtle difference to the previous behavior: invalid numbers of
2896         arguments now raise TypeError instead of SyntaxError. This is in accordance
2897         with Web IDL, and matches the existing V8 bindings.
2898
2899         Test: fast/canvas/canvas-overloads-setShadow.html
2900
2901         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2902         * html/canvas/CanvasRenderingContext2D.idl:
2903
2904 2011-05-31  Andreas Kling  <kling@webkit.org>
2905
2906         Reviewed by Antti Koivisto.
2907
2908         Canvas/JSC: Auto-generate overloads for drawImageFromRect()
2909         https://bugs.webkit.org/show_bug.cgi?id=61709
2910
2911         Move CanvasRenderingContext2D.drawImageFromRect() to auto-generated JSC bindings.
2912         Make it [RequiresAllArguments=Raise] to match the old behavior.
2913         Side effect: calling drawImageFromRect() with zero arguments will now raise
2914         SyntaxError instead of TypeError.
2915
2916         Test: fast/canvas/canvas-overloads-drawImageFromRect.html
2917
2918         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2919         * html/canvas/CanvasRenderingContext2D.h:
2920         * html/canvas/CanvasRenderingContext2D.idl:
2921
2922 2011-05-31  Andreas Kling  <kling@webkit.org>
2923
2924         Reviewed by Antti Koivisto.
2925
2926         Canvas/JSC: Auto-generate overloads for drawImage()
2927         https://bugs.webkit.org/show_bug.cgi?id=61703
2928
2929         Move CanvasRenderingContext2D.drawImage() to auto-generated JSC bindings.
2930
2931         There is a subtle difference to the previous behavior: invalid numbers of
2932         arguments now raise TypeError instead of SyntaxError. This is in accordance
2933         with Web IDL, and matches the existing V8 bindings.
2934
2935         Test: fast/canvas/canvas-overloads-drawImage.html
2936
2937         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2938         * html/canvas/CanvasRenderingContext2D.idl:
2939
2940 2011-05-31  Andreas Kling  <kling@webkit.org>
2941
2942         Reviewed by Antti Koivisto.
2943
2944         Canvas/JSC: Auto-generate overloads for strokeRect()
2945         https://bugs.webkit.org/show_bug.cgi?id=61641
2946
2947         Move CanvasRenderingContext2D.setStrokeColor() to auto-generated JSC bindings.
2948
2949         No behavioral change.
2950
2951         Test: fast/canvas/canvas-overloads-strokeRect.html
2952
2953         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2954         * html/canvas/CanvasRenderingContext2D.idl:
2955
2956 2011-05-31  Andreas Kling  <kling@webkit.org>
2957
2958         Reviewed by Antti Koivisto.
2959
2960         Canvas/JSC: Auto-generate overloads for setFillColor()
2961         https://bugs.webkit.org/show_bug.cgi?id=61635
2962
2963         Move CanvasRenderingContext2D.setStrokeColor() to auto-generated JSC bindings.
2964
2965         There is a subtle difference to the previous behavior: invalid numbers of
2966         arguments now raise TypeError instead of SyntaxError. This is in accordance
2967         with Web IDL, but doesn't matter much anyway since this method is WebKit-only.
2968
2969         Test: fast/canvas/canvas-overloads-setFillColor.html
2970
2971         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2972         * html/canvas/CanvasRenderingContext2D.idl:
2973
2974 2011-05-31  Andreas Kling  <kling@webkit.org>
2975
2976         Reviewed by Antti Koivisto.
2977
2978         Canvas/JSC: Auto-generate overloads for setStrokeColor()
2979         https://bugs.webkit.org/show_bug.cgi?id=61629
2980
2981         Move CanvasRenderingContext2D.setStrokeColor() to auto-generated JSC bindings.
2982
2983         There is a subtle difference to the previous behavior: invalid numbers of
2984         arguments now raise TypeError instead of SyntaxError. This is in accordance
2985         with Web IDL, but doesn't matter much anyway since this method is WebKit-only.
2986
2987         Test: fast/canvas/canvas-overloads-setStrokeColor.html
2988
2989         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
2990         * html/canvas/CanvasRenderingContext2D.idl:
2991
2992 2011-05-31  Andreas Kling  <kling@webkit.org>
2993
2994         Reviewed by Antti Koivisto.
2995
2996         Canvas/JSC: Auto-generate overloads for strokeText()
2997         https://bugs.webkit.org/show_bug.cgi?id=61626
2998
2999         Move CanvasRenderingContext2D.strokeText() to auto-generated JSC bindings.
3000         Make it [RequiresAllArguments=Raise] to match the old behavior.
3001         This has the side-effect of aligning the behaviors of JSC and V8.
3002
3003         Test: fast/canvas/canvas-overloads-strokeText.html
3004
3005         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
3006         * html/canvas/CanvasRenderingContext2D.idl:
3007
3008 2011-05-31  Andreas Kling  <kling@webkit.org>
3009
3010         Reviewed by Antti Koivisto.
3011
3012         Canvas/JSC: Auto-generate overloads for fillText()
3013         https://bugs.webkit.org/show_bug.cgi?id=61623
3014
3015         Move CanvasRenderingContext2D.fillText() to auto-generated JSC bindings.
3016         Make it [RequiresAllArguments=Raise] to match the old behavior.
3017         This has the side-effect of aligning the behaviors of JSC and V8.
3018
3019         Test: fast/canvas/canvas-overloads-fillText.html
3020
3021         * bindings/js/JSCanvasRenderingContext2DCustom.cpp:
3022         * html/canvas/CanvasRenderingContext2D.idl:
3023
3024 2011-05-31  Yael Aharon  <yael.aharon@nokia.com>
3025
3026         Reviewed by Kenneth Rohde Christiansen.
3027
3028         Frame flattening is broken with nested frames
3029         https://bugs.webkit.org/show_bug.cgi?id=61491
3030
3031         After r77988, when frame flattening is enabled, performPostLayoutTasks() is called on a timer for iframes.
3032         This causes layout of nested iframes to sometimes happen asynchronously, but WebCore expects layout to always finish synchronously.
3033         Added a call to updateWidgetPosition() for cases that performPostLayoutTasks() is now happening asynchronously.
3034
3035         Test: fast/frames/flattening/iframe-flattening-nested.html
3036
3037         * page/FrameView.cpp:
3038         (WebCore::FrameView::layout):
3039
3040 2011-05-31  Tommy Widenflycht  <tommyw@google.com>
3041
3042         Reviewed by Tony Gentilcore.
3043
3044         Fix getUserMedia callback bindings for JSC.
3045         https://bugs.webkit.org/show_bug.cgi?id=60174
3046
3047         This patch initializes the exception code variable to 0.
3048
3049         Test: fast/dom/MediaStream/argument-types.html
3050
3051         * bindings/js/JSNavigatorCustom.cpp:
3052         (WebCore::JSNavigator::webkitGetUserMedia):
3053
3054 2011-05-31  Oleg Romashin  <oleg.romashin@nokia.com>
3055
3056         Reviewed by Benjamin Poulain.
3057
3058         Fix compilation with debug enabled, m_lightSource.type is not valid anymore
3059         https://bugs.webkit.org/show_bug.cgi?id=61719
3060
3061         * platform/graphics/filters/arm/FELightingNEON.h:
3062         (WebCore::FELighting::platformApplyNeon):
3063
3064 2011-05-31  Oliver Varga  <Varga.Oliver@stud.u-szeged.hu>
3065
3066         Reviewed by Nikolas Zimmermann.
3067
3068         Invalid color handling is broken for SVG
3069         https://bugs.webkit.org/show_bug.cgi?id=58531
3070
3071         Fix invalid color fallback handling. If the fill/stroke attributes computed
3072         value leads to a an invalid color, inherit the desired color from the parent
3073         style instead. Matches Opera/FF and SVG 1.1 Second Edition (http://www.w3.org/TR/SVG/).
3074
3075         Tests: svg/custom/invalid-stroke-hex.svg
3076                svg/custom/invalid-uri-stroke.svg
3077
3078         * rendering/svg/RenderSVGResource.cpp:
3079         (WebCore::inheritColorFromParentStyleIfNeeded):
3080         (WebCore::requestPaintingResource):
3081
3082 2011-05-31  Vangelis Kokkevis  <vangelis@chromium.org>
3083
3084         Reviewed by Kent Tamura.
3085
3086         [chromium] Avoid double deletion of DrawingBuffer's color buffer
3087         texture.
3088         https://bugs.webkit.org/show_bug.cgi?id=61761
3089
3090         Test: Verified that the DCHECK in GraphicsContext3D implementation
3091         doesn't trigger.
3092
3093         * platform/graphics/chromium/DrawingBufferChromium.cpp:
3094         (WebCore::DrawingBuffer::~DrawingBuffer):
3095
3096 2011-05-30  Hayato Ito  <hayato@chromium.org>
3097
3098         Reviewed by Ryosuke Niwa.
3099
3100         Add a utility function for dumping a tree for the Node, including a document of a frame.
3101         https://bugs.webkit.org/show_bug.cgi?id=61727
3102
3103         No new tests since added functions are only available in debug builds.
3104
3105         * dom/Node.cpp:
3106         (WebCore::parentOrHostOrFrameOwner):
3107         (WebCore::traverseNextNodeAcrossFrame):
3108         (WebCore::Node::showTreeForThisAcrossFrame):
3109         * dom/Node.h:
3110
3111 2011-05-30  James Kozianski  <koz@chromium.org>
3112
3113         Reviewed by Kent Tamura.
3114
3115         [Chromium] Make isValidProtocol() accept protocols with '+'.
3116         https://bugs.webkit.org/show_bug.cgi?id=61759
3117
3118         Also, detect syntax errors before security errors; some syntax errors
3119         will also trigger a security error, but it's more helpful to the
3120         programmer to know if they have a syntax error, which are well-defined
3121         in the spec, rather than a security error, which aren't.
3122
3123         * page/Navigator.cpp:
3124         (WebCore::Navigator::registerProtocolHandler):
3125         Detect syntax errors before security errors.
3126         * platform/KURLGoogle.cpp:
3127         (WebCore::isSchemeChar):
3128         Include '+' in the list of valid characters.
3129
3130 2011-05-30  Andrey Petrov  <andrey.petrov@gmail.com>
3131
3132         Reviewed by Hajime Morita.
3133
3134         Using jQuery to show/hide IMG elements crashes WebKit
3135         https://bugs.webkit.org/show_bug.cgi?id=31721
3136
3137         For platform code, do not assert nodes always have renderer at
3138         the time context menu action is invoked.
3139         Renderer can actually be empty for a given node if it was hidden
3140         or removed from domtree by some non-user generated event (e.g timeout) 
3141         after the popup menu had been created.
3142
3143         Changing Chromium, Gtk, Mac, Qt, Win and WinCE.
3144
3145         Test: editing/pasteboard/copy-standalone-image-crash.html
3146
3147         * platform/chromium/PasteboardChromium.cpp:
3148         (WebCore::Pasteboard::writeImage):
3149         * platform/gtk/PasteboardGtk.cpp:
3150         (WebCore::Pasteboard::writeImage):
3151         * platform/mac/PasteboardMac.mm:
3152         (WebCore::Pasteboard::writeImage):
3153         * platform/qt/PasteboardQt.cpp:
3154         (WebCore::Pasteboard::writeImage):
3155         * platform/win/PasteboardWin.cpp:
3156         (WebCore::Pasteboard::writeImage):
3157         * platform/wince/PasteboardWinCE.cpp:
3158         (WebCore::Pasteboard::writeImage):
3159
3160 2011-05-30  Daniel Bates  <dbates@webkit.org>
3161
3162         Reviewed by Adam Barth.
3163
3164         Rename XSSFilter to XSSAuditor
3165         https://bugs.webkit.org/show_bug.cgi?id=61718
3166
3167         Currently we use the names XSSFilter and XSSAuditor throughout the project.
3168         Instead, we should choose one name for consistency.
3169
3170         No functionality was changed. So, no new tests.
3171
3172         * CMakeLists.txt:
3173         * GNUmakefile.list.am:
3174         * WebCore.gypi:
3175         * WebCore.pro:
3176         * WebCore.vcproj/WebCore.vcproj:
3177         * WebCore.xcodeproj/project.pbxproj:
3178         * html/parser/HTMLDocumentParser.cpp:
3179         (WebCore::HTMLDocumentParser::HTMLDocumentParser):
3180         (WebCore::HTMLDocumentParser::pumpTokenizer):
3181         * html/parser/HTMLDocumentParser.h:
3182         * html/parser/XSSAuditor.cpp: Copied from Source/WebCore/html/parser/XSSFilter.cpp.
3183         (WebCore::XSSAuditor::XSSAuditor):
3184         (WebCore::XSSAuditor::init):
3185         (WebCore::XSSAuditor::filterToken):
3186         (WebCore::XSSAuditor::filterTokenInitial):
3187         (WebCore::XSSAuditor::filterTokenAfterScriptStartTag):
3188         (WebCore::XSSAuditor::filterScriptToken):
3189         (WebCore::XSSAuditor::filterObjectToken):
3190         (WebCore::XSSAuditor::filterParamToken):
3191         (WebCore::XSSAuditor::filterEmbedToken):
3192         (WebCore::XSSAuditor::filterAppletToken):
3193         (WebCore::XSSAuditor::filterIframeToken):
3194         (WebCore::XSSAuditor::filterMetaToken):
3195         (WebCore::XSSAuditor::filterBaseToken):
3196         (WebCore::XSSAuditor::filterFormToken):
3197         (WebCore::XSSAuditor::eraseDangerousAttributesIfInjected):
3198         (WebCore::XSSAuditor::eraseAttributeIfInjected):
3199         (WebCore::XSSAuditor::snippetForRange):
3200         (WebCore::XSSAuditor::snippetForAttribute):
3201         (WebCore::XSSAuditor::isContainedInRequest):
3202         (WebCore::XSSAuditor::isSameOriginResource):
3203         * html/parser/XSSAuditor.h: Copied from Source/WebCore/html/parser/XSSFilter.h.
3204         * html/parser/XSSFilter.cpp: Removed.
3205         * html/parser/XSSFilter.h: Removed.
3206
3207 2011-05-30  No'am Rosenthal  <noam.rosenthal@nokia.com>
3208
3209         Reviewed by Simon Hausmann.
3210
3211         WebKit2: Enable serializing of data types needed for cross-process accelerated compositing
3212         https://bugs.webkit.org/show_bug.cgi?id=61694
3213
3214         Expose a public clearAll() function to reset WebCore::Animation.
3215
3216         No new functionality, so no new tests.
3217
3218         * platform/animation/Animation.h:
3219         (WebCore::Animation::clearAll):
3220
3221 2011-05-30  Eric Carlson  <eric.carlson@apple.com>
3222
3223         Reviewed by Alexey Proskuryakov.
3224
3225         Audio and video files saved to the Application Cache should preserve the original file extension
3226         https://bugs.webkit.org/show_bug.cgi?id=61750
3227         <rdar://9524922>
3228
3229         No new tests, it isn't possible to check the name of the file in the cache from within
3230         DRT. Changes verified manually.
3231
3232         * loader/appcache/ApplicationCacheStorage.cpp:
3233         (WebCore::ApplicationCacheStorage::store): Append the original file extension to the cache
3234             file name.
3235         (WebCore::ApplicationCacheStorage::writeDataToUniqueFileInDirectory): Add extension parameter.
3236         * loader/appcache/ApplicationCacheStorage.h:
3237
3238 2011-05-30  Jer Noble  <jer.noble@apple.com>
3239
3240         Reviewed by Dan Bernstein.
3241
3242         Play/Pause button in wrong state when entering full screen on Vimeo
3243         https://bugs.webkit.org/show_bug.cgi?id=61754
3244
3245         Update the play/pause button inside reset().  This ensures the button is in
3246         the correct state when the controls are created after playback has already
3247         started.
3248
3249         * html/shadow/MediaControlRootElement.cpp:
3250         (WebCore::MediaControlRootElement::reset):
3251
3252 2011-05-30  No'am Rosenthal  <noam.rosenthal@nokia.com>
3253
3254         Reviewed by Simon Hausmann.
3255
3256         WebKit2: Enable serializing of data types needed for cross-process accelerated compositing
3257         https://bugs.webkit.org/show_bug.cgi?id=61694
3258
3259         Added a public TimingFunction::type() method.
3260
3261         No new functionality, so no new tests.
3262
3263         * platform/animation/TimingFunction.h:
3264         (WebCore::TimingFunction::type):
3265
3266 2011-05-30  Noam Rosenthal  <noam.rosenthal@nokia.com>
3267
3268         BUILD FIX for r87697 on Windows/Symbian
3269
3270         For now enabling TextureMapper for Mac/Linux only.
3271
3272         * WebCore.pri:
3273
3274 2011-05-30  David Kilzer  <ddkilzer@apple.com>
3275
3276         BUILD FIX for r87692 with !ENABLE(FULLSCREEN_API)
3277
3278         * dom/EventDispatcher.cpp:
3279         (WebCore::EventDispatcher::determineDispatchBehavior): Mark
3280         shadowRoot as an unused parameter with !ENABLE(FULLSCREEN_API).
3281
3282 2011-05-30  No'am Rosenthal  <noam.rosenthal@nokia.com>
3283
3284         Reviewed by Andreas Kling.
3285
3286         [Texmap][Qt] Enable TextureMapper by default
3287         https://bugs.webkit.org/show_bug.cgi?id=61740
3288
3289         Make CONFIG+=texmap an opt-out instead of an opt-in.
3290
3291         No new functionality so no new tests.
3292
3293         * WebCore.pri:
3294
3295 2011-05-30  Martin Robinson  <mrobinson@igalia.com>
3296
3297         Reviewed by Xan Lopez.
3298
3299         [GTK] fast/css/font-face-zero-hash-key.html is crashing on the bots
3300         https://bugs.webkit.org/show_bug.cgi?id=61693
3301
3302         Do not try to read the FT_Face from m_scaledFont if it m_scaledFont is
3303         null. A recent change fixing 0-pixel-size fonts means that m_scaledFont
3304         may now be null.
3305
3306         No new tests. This change should cause fast/css/font-face-zero-hash-key.html
3307         to stop crashing.
3308
3309         * platform/graphics/freetype/FontPlatformDataFreeType.cpp:
3310         (WebCore::FontPlatformData::FontPlatformData): Do a null check before accessing
3311         m_scaledFont.
3312
3313 2011-05-30  Noam Rosenthal  <noam.rosenthal@nokia.com>
3314
3315         Reviewed by Kenneth Rohde Christiansen.
3316
3317         [Texmap][Qt] Disable accelerated plugins/media until they're working.
3318         https://bugs.webkit.org/show_bug.cgi?id=61687
3319
3320         Until this works properly, we should indicate that our media implementation
3321         in texture mapper doesn't support accelerated compositing.
3322
3323         This makes LayoutTests/compositing/video/* work again.
3324
3325         * platform/graphics/qt/MediaPlayerPrivateQt.h:
3326         (WebCore::MediaPlayerPrivateQt::supportsAcceleratedRendering):
3327         (WebCore::MediaPlayerPrivateQt::platformLayer):
3328
3329 2011-05-30  Mikhail Naganov  <mnaganov@chromium.org>
3330
3331         Reviewed by Adam Barth.
3332
3333         [Chromium] Fix regression after r87628.
3334         https://bugs.webkit.org/show_bug.cgi?id=61733
3335
3336         Having r87628 in place, Chrome reliability bot crashes in
3337         WebCore::HTMLLinkElement::onloadTimerFired.
3338
3339         This is because the change makes WebCore::CachedResource::setRequest to
3340         call checkNotify on request reset.  HTMLLinkElement registers itself as
3341         CachedResource client via m_cachedSheet, which can happen even if
3342         m_cachedLinkResource wasn't set.  As a result,
3343         WebCore::HTMLLinkElement::notifyFinished is got called with unset
3344         m_cachedLinkResource, which causes a crash in
3345         HTMLLinkElement::onloadTimerFired
3346
3347         * html/HTMLLinkElement.cpp:
3348         (WebCore::HTMLLinkElement::notifyFinished):
3349
3350 2011-05-30  Jer Noble  <jer.noble@apple.com>
3351
3352         Reviewed by Darin Adler and Simon Fraser.
3353
3354         REGRESSION (r87622): Scrubbing a Vimeo movie when in fullscreen stops playback; no way to make it start again
3355         https://bugs.webkit.org/show_bug.cgi?id=61717
3356         rdar://problem/9522272
3357
3358         May be some good way to test this later. No immediate idea about the best way.
3359
3360         When a media element is taken into full-screen mode, stop events from propagating
3361         outside the media element's shadow DOM, EventDispatcher::determineDispatchBehavior()
3362         has been changed to take a shadow root node. In our full screen media element check,
3363         we check to see if the passed shadow root is the shadow root of the full screen media
3364         element, and if so, specify events should StayInsideShadowDOM. The end result is that
3365         inside EventDispatcher::ensureEventAncestors, an ancestor chain is built up all the
3366         way from the SliderThumb to the video element's shadow root, but no further.
3367
3368         * dom/EventDispatcher.cpp:
3369         (WebCore::EventDispatcher::determineDispatchBehavior): Restrict events to the
3370         shadow DOM when showing a full screen video.
3371
3372         * html/HTMLMediaElement.cpp:
3373         (WebCore::HTMLMediaElement::HTMLMediaElement): Removed code to manage full screen controls.
3374         The events telling us about activity in the shadow DOM no longer bubble out so we need to
3375         handle this inside the shadow DOM on the root element.
3376         (WebCore::HTMLMediaElement::play): Ditto.
3377         (WebCore::HTMLMediaElement::playbackProgressTimerFired): Ditto.
3378         (WebCore::HTMLMediaElement::defaultEventHandler): Ditto.
3379         (WebCore::HTMLMediaElement::enterFullscreen): Ditto.
3380         (WebCore::HTMLMediaElement::exitFullscreen): Ditto.
3381         * html/HTMLMediaElement.h: Added isPlaying function, removed things moved to the root element.
3382
3383         * html/shadow/MediaControlElements.cpp:
3384         (WebCore::MediaControlVolumeSliderContainerElement::defaultEventHandler): Rolled out
3385         changes that tried to make special rules for events using preDispatchEventHandler and such.
3386         This rolls out both r87622 and r87655.
3387         (WebCore::MediaControlMuteButtonElement::defaultEventHandler): Ditto.
3388         (WebCore::MediaControlPanelMuteButtonElement::defaultEventHandler): Ditto.
3389         (WebCore::MediaControlPlayButtonElement::defaultEventHandler): Ditto.
3390         (WebCore::MediaControlSeekButtonElement::defaultEventHandler): Ditto.
3391         (WebCore::MediaControlRewindButtonElement::defaultEventHandler): Ditto.
3392         (WebCore::MediaControlReturnToRealtimeButtonElement::defaultEventHandler): Ditto.
3393         (WebCore::MediaControlToggleClosedCaptionsButtonElement::defaultEventHandler): Ditto.
3394         (WebCore::MediaControlTimelineElement::defaultEventHandler): Ditto.
3395         (WebCore::MediaControlVolumeSliderElement::defaultEventHandler): Ditto.
3396         (WebCore::MediaControlFullscreenButtonElement::defaultEventHandler): Ditto.
3397         (WebCore::MediaControlFullscreenVolumeMinButtonElement::defaultEventHandler): Ditto.
3398         (WebCore::MediaControlFullscreenVolumeMaxButtonElement::defaultEventHandler): Ditto.
3399         * html/shadow/MediaControlElements.h: Ditto.
3400
3401         * html/shadow/MediaControlRootElement.cpp:
3402         (WebCore::MediaControlRootElement::MediaControlRootElement): Initialize new data members.
3403         (WebCore::MediaControlRootElement::playbackStarted): Start the timer so we will consider
3404         hiding the controls later.
3405         (WebCore::MediaControlRootElement::playbackProgressed): Hide the controls if the mouse
3406         is no longer over the controls.
3407         (WebCore::MediaControlRootElement::playbackStopped): Stop the timer since we only hide
3408         automatically if we're playing.
3409         (WebCore::MediaControlRootElement::enteredFullscreen): Start the timer.
3410         (WebCore::MediaControlRootElement::exitedFullscreen): Stop the timer since we only care
3411         if we are full screen.
3412         (WebCore::MediaControlRootElement::containsRelatedTarget): Added. Helper for next function.
3413         (WebCore::MediaControlRootElement::defaultEventHandler): Do the hide/show and timer functions
3414         as the mouse is moved in and out.
3415         (WebCore::MediaControlRootElement::startHideFullscreenControlsTimer): Start the timer if
3416         needed.
3417         (WebCore::MediaControlRootElement::hideFullscreenControlsTimerFired): Hide if the conditions
3418         are met.
3419         (WebCore::MediaControlRootElement::stopHideFullscreenControlsTimer): Stop the timer.
3420
3421         * html/shadow/MediaControlRootElement.h: Added new functions and data members.
3422
3423
3424 2011-05-30  Gavin Peters  <gavinp@chromium.org>
3425
3426         Reviewed by Adam Barth.
3427
3428         prevent HTMLLinkElement from watching multiple CachedResources
3429         https://bugs.webkit.org/show_bug.cgi?id=61686
3430
3431         If we modify an existing link element, stop listening to the previous
3432         cached resource, to prevent double notifications (which crash).
3433
3434         Test: fast/dom/HTMLLinkElement/prefetch-too-many-clients.html
3435
3436         * html/HTMLLinkElement.cpp:
3437         (WebCore::HTMLLinkElement::process):
3438
3439 2011-05-30  Peter Varga  <pvarga@webkit.org>
3440
3441         Unreviewed build fix.
3442
3443         [Qt][V8] Fix debug build.
3444
3445         No new tests needed.
3446
3447         * css/CSSStyleDeclaration.cpp: Add missing header.
3448         * dom/Text.cpp: Ditto.
3449         * rendering/InlineTextBox.cpp: Ditto.
3450
3451 2011-05-30  Sheriff Bot  <webkit.review.bot@gmail.com>
3452
3453         Unreviewed, rolling out r87683.
3454         http://trac.webkit.org/changeset/87683
3455         https://bugs.webkit.org/show_bug.cgi?id=61729
3456
3457         Breaks inspector tests on Chromium (Requested by apavlov on
3458         #webkit).
3459
3460         * inspector/front-end/StylesSidebarPane.js:
3461         (WebInspector.StylesSidebarPane.prototype.update):
3462
3463 2011-05-25  Alexander Pavlov  <apavlov@chromium.org>
3464
3465         Reviewed by Yury Semikhatsky.
3466
3467         Web Inspector: node selection is slow in the Elements panel.
3468         https://bugs.webkit.org/show_bug.cgi?id=60813
3469
3470         Schedule full style updates rather than request all node styles from the backend up front.
3471
3472         * inspector/front-end/StylesSidebarPane.js:
3473         (WebInspector.StylesSidebarPane.prototype.update.reloadAllStyles):
3474         (WebInspector.StylesSidebarPane.prototype.update):
3475
3476 2011-05-30  Andrey Kosyakov  <caseq@chromium.org>
3477
3478         Reviewed by Pavel Feldman.
3479
3480         Web Inspector: do not issue frontendReused for reload or navigation.
3481         https://bugs.webkit.org/show_bug.cgi?id=61192
3482
3483        - only issue frontendReused when inspector is attached after main resource committed load
3484        - upon committing loading main resource, reset agents before sending FrameNavigated to page agent
3485        - Ensure main resource is set early so that abbreviations of URLs in resource tree are consistent after reload
3486        - do not enable agents explicitly in frontendReused (this is done by backend when resotring state from cookie)
3487
3488         * inspector/InspectorAgent.cpp:
3489         (WebCore::InspectorAgent::InspectorAgent):
3490         (WebCore::InspectorAgent::restore):
3491         (WebCore::InspectorAgent::clearFrontend):
3492         (WebCore::InspectorAgent::didCommitLoad):
3493         * inspector/InspectorAgent.h:
3494         * inspector/InspectorInstrumentation.cpp:
3495         (WebCore::InspectorInstrumentation::didCommitLoadImpl):
3496         * inspector/front-end/NetworkManager.js:
3497         * inspector/front-end/ResourceTreeModel.js:
3498         (WebInspector.ResourceTreeModel.prototype._processCachedResources):
3499         (WebInspector.ResourceTreeModel.prototype._frameNavigated):
3500         (WebInspector.ResourceTreeModel.prototype._cleanupFramesAfterNavigation):
3501         (WebInspector.ResourceTreeModel.prototype._addFramesRecursively):
3502         * inspector/front-end/ResourcesPanel.js:
3503         (WebInspector.ResourcesPanel.prototype.reset):
3504         (WebInspector.ResourcesPanel.prototype._resetResourcesTree):
3505         (WebInspector.DatabaseTreeElement.prototype.onpopulate):
3506         (WebInspector.SearchResultsTreeElementsTraverser.prototype._lastTreeElement):
3507         * inspector/front-end/inspector.js:
3508         (WebInspector.reset):
3509         (WebInspector.frontendReused):
3510
3511 2011-05-30  Ryan Sleevi  <rsleevi@chromium.org>
3512
3513         Reviewed by Darin Adler.
3514
3515         FEConvolveMatrix::getPixelValue() fails to properly check if y is within bounds, causing it to fail