Fix Chromium Mac build.
[WebKit.git] / WebCore / ChangeLog
1 2011-01-05  Darin Adler  <darin@apple.com>
2
3         Fix Chromium Mac build.
4
5         * platform/graphics/Gradient.h: Forward-declare CGContextRef.
6         This might even make it possible to remove the include of
7         <CoreGraphics/CoreGraphics.h> for PLATFORM(WIN), but I did not
8         do that at this time because I don't want to break the Windows
9         build when fixing the Chromium build.
10
11 2011-01-05  Xianzhu Wang  <wangxianzhu@google.com>
12
13         Reviewed by David Levin.
14
15         Implement RemoteFontStream's skip behavior (in FontCustomPlatformData.cpp)
16         https://bugs.webkit.org/show_bug.cgi?id=51736
17
18         No new tests. This change has potential effect on @font-face CSS feature
19         on ports using Skia. Tested on Chromium that this change won't break
20         fast/css/font-face-remote.html. This change can make the test pass on
21         other ports using Skia.
22
23         * platform/graphics/skia/FontCustomPlatformData.cpp:
24         (WebCore::RemoteFontStream::read):
25
26 2011-01-05  Helder Correia  <helder@sencha.com>
27
28         Reviewed by Simon Fraser.
29
30         Shadows are not drawn when filling a rect with a gradient fillStyle on Mac and Chromium-Mac
31         https://bugs.webkit.org/show_bug.cgi?id=51869
32
33         GraphicsContext::fillRect(const FloatRect&) is clipping to the rect.
34         The shadow is being drawn, but getting clipped to the rect being filled.
35         The solution is to draw the gradient into a CGLayer (when a shadow is
36         required), then render the layer to the GraphicsContext.
37
38         This patch also fixes:
39         canvas/philip/tests/2d.shadow.gradient.alpha.html
40         canvas/philip/tests/2d.shadow.gradient.basic.html
41         canvas/philip/tests/2d.shadow.gradient.transparent.2.html
42
43         Test: fast/canvas/canvas-fillRect-gradient-shadow.html
44
45         * platform/graphics/Gradient.h:
46         * platform/graphics/cg/GradientCG.cpp:
47         (WebCore::Gradient::paint):
48         * platform/graphics/cg/GraphicsContextCG.cpp:
49         (WebCore::GraphicsContext::fillRect):
50
51 2011-01-05  Steve Falkenburg  <sfalken@apple.com>
52
53         Reviewed by Darin Adler.
54
55         Debug and Release builds on Windows clobber each other
56         https://bugs.webkit.org/show_bug.cgi?id=49185
57
58         Changes the structure of WebKitBuild build products directory so we
59         completely separate each build configuration into independent directories.
60         
61         Although we previously had per-configuration directories for obj, this change adds
62         per-configuration directories for bin, lib, obj, and include. Each configuration's
63         build products are stored within a directory inside of WebKitBuild.
64         
65         Most use of $(WebKitOutputDir) in the build files has been replaced by $(ConfigurationBuildDir),
66         defined in common.vsprops to be $(WebKitOutputDir)\$(ConfigurationName).
67
68         * WebCore.vcproj/QTMovieWinCommon.vsprops:
69         * WebCore.vcproj/QTMovieWinPostBuild.cmd:
70         * WebCore.vcproj/QTMovieWinPreBuild.cmd:
71         * WebCore.vcproj/WebCore.make:
72         * WebCore.vcproj/WebCore.vcproj:
73         * WebCore.vcproj/WebCoreCommon.vsprops:
74         * WebCore.vcproj/WebCoreGeneratedCairo.vsprops:
75         * WebCore.vcproj/WebCoreGeneratedCommon.vsprops:
76         * WebCore.vcproj/WebCoreMediaQT.vsprops:
77         * WebCore.vcproj/WebCorePostBuild.cmd:
78         * WebCore.vcproj/WebCorePreBuild.cmd:
79         * WebCore.vcproj/copyForwardingHeaders.cmd:
80         * WebCore.vcproj/copyInspectorFiles.cmd:
81
82 2011-01-05  Simon Fraser  <simon.fraser@apple.com>
83
84         Reviewed by Ariya Hidayat.
85
86         Directly composited SVG images fail to render
87         https://bugs.webkit.org/show_bug.cgi?id=51975
88         
89         There was already code, added in r67900, to detect whether an image
90         may be directly composited, by checking to see if it's a bitmap image.
91         
92         However, CachedImage::image() returns the nullImage() if m_image is null,
93         which is a BitmapImage, confusing this test.
94
95         Test: compositing/images/direct-svg-image.html
96
97         * loader/cache/CachedImage.cpp: Remove nullImage(), since Image has
98         exactly the same method.
99         (WebCore::CachedImage::image): Use Image::nullImage().
100         * loader/cache/CachedImage.h:
101         (WebCore::CachedImage::hasImage): New method to ask whether the m_image is
102         non-null.
103         * rendering/RenderLayerBacking.cpp:
104         (WebCore::RenderLayerBacking::isDirectlyCompositedImage): Use hasImage()
105         so that we don't test the nullImage.
106
107 2011-01-05  Simon Fraser  <simon.fraser@apple.com>
108
109         Reviewed by Darin Adler.
110
111         Fix percentage values in radius of radial gradients
112         https://bugs.webkit.org/show_bug.cgi?id=51979
113         
114         Handle percentage values for the ending size of radial gradients.
115
116         Test: fast/gradients/css3-radial-gradients3.html
117
118         * css/CSSGradientValue.cpp:
119         (WebCore::CSSRadialGradientValue::resolveRadius): Add parameter for height or width, which is
120         non-null if percentage values are allowed, and compute percentage values when we see them.
121         (WebCore::CSSRadialGradientValue::createGradient): Pass height or width down to say that
122         percentages are OK when resolving end radii.
123         * css/CSSGradientValue.h: New parameter for resolveRadius.
124
125 2011-01-05  James Simonsen  <simonjam@chromium.org>
126
127         Reviewed by Adam Barth.
128
129         [Web Timing] Zero out some values on cross-origin redirects
130         https://bugs.webkit.org/show_bug.cgi?id=49294
131
132         Tests: http/tests/misc/webtiming-cross-origin-redirect.php
133                http/tests/misc/webtiming-origins.html
134
135         * loader/DocumentLoadTiming.h:
136         (WebCore::DocumentLoadTiming::DocumentLoadTiming): Add flags for cross-origin redirects and same-origin navigation.
137         * loader/FrameLoader.cpp:
138         (WebCore::FrameLoader::~FrameLoader):
139         (WebCore::FrameLoader::stopLoading): Don't overwrite previous unload times.
140         (WebCore::FrameLoader::completed):
141         (WebCore::FrameLoader::loadWithDocumentLoader): Remember previous URL to see if navigation is same-origin.
142         (WebCore::FrameLoader::commitProvisionalLoad): Set flag if navigation is same-origin.
143         * loader/FrameLoader.h:
144         * loader/MainResourceLoader.cpp:
145         (WebCore::MainResourceLoader::willSendRequest): Set flag on cross-origin redirects.
146         * page/PerformanceNavigation.cpp:
147         (WebCore::PerformanceNavigation::redirectCount): Clear if cross-origin redirect flag is set.
148         * page/PerformanceTiming.cpp:
149         (WebCore::PerformanceTiming::redirectStart): Ditto.
150         (WebCore::PerformanceTiming::redirectEnd): Ditto.
151         (WebCore::PerformanceTiming::unloadEventStart): Clear if cross-origin navigation is set.
152         (WebCore::PerformanceTiming::unloadEventEnd): Ditto.
153
154 2011-01-05  Helder Correia  <helder@sencha.com>
155
156         Reviewed by Ariya Hidayat.
157
158         [Qt] Default focus ring is too wide
159         https://bugs.webkit.org/show_bug.cgi?id=51854
160
161         This is an intermediate step to solve this bug. Use QPalette::Highlight
162         instead of default half-transparent black as the focus ring color.
163
164         * platform/graphics/qt/GraphicsContextQt.cpp:
165         (WebCore::drawFocusRingForPath):
166         * platform/qt/RenderThemeQt.cpp:
167         (WebCore::RenderThemeQt::platformFocusRingColor):
168         * platform/qt/RenderThemeQt.h:
169
170 2011-01-05  James Simonsen  <simonjam@chromium.org>
171
172         Reviewed by Darin Fisher.
173
174         [Web Timing] requestStart and responseStart should be available even if the document is still loading
175         https://bugs.webkit.org/show_bug.cgi?id=51368
176
177         Test: http/tests/misc/webtiming-slow-load.php
178
179         * page/PerformanceTiming.cpp:
180         (WebCore::getPossiblySkewedTimeInKnownRange): Handle case where response is not yet complete.
181         (WebCore::PerformanceTiming::resourceLoadTimeRelativeToAbsolute): Use full upper bound.
182
183 2011-01-05  Chris Rogers  <crogers@google.com>
184
185         Reviewed by Darin Fisher.
186
187         Add WebKitClient::createAudioDevice() for Chromium port of web audio API
188         https://bugs.webkit.org/show_bug.cgi?id=51424
189
190         No new tests since audio API is not yet implemented.
191
192         * WebCore.gyp/WebCore.gyp:
193         * WebCore.gypi:
194
195 2011-01-05  Anders Carlsson  <andersca@apple.com>
196
197         Try again.
198
199         * WebCore.exp.in:
200
201 2011-01-05  Anders Carlsson  <andersca@apple.com>
202
203         Attempt to fix Leopard build.
204
205         * WebCore.exp.in:
206
207 2011-01-05  Evan Martin  <evan@chromium.org>
208
209         Reviewed by Tony Chang.
210
211         [chromium] refactor complex text on Linux
212         https://bugs.webkit.org/show_bug.cgi?id=51956
213
214         Pull out TextRunWalker from FontLinux.cpp.  Put it in its own file.
215         Rename it to ComplexTextController, to match platform/graphics/mac
216         more closely.
217
218         No tests because the change is just renaming a class.
219
220         * WebCore.gyp/WebCore.gyp:
221         * platform/graphics/chromium/ComplexTextControllerLinux.cpp: Added.
222         (WebCore::ComplexTextController::ComplexTextController):
223         (WebCore::ComplexTextController::~ComplexTextController):
224         (WebCore::ComplexTextController::isWordBreak):
225         (WebCore::ComplexTextController::determineWordBreakSpacing):
226         (WebCore::ComplexTextController::setPadding):
227         (WebCore::ComplexTextController::reset):
228         (WebCore::ComplexTextController::setBackwardsIteration):
229         (WebCore::ComplexTextController::nextScriptRun):
230         (WebCore::ComplexTextController::widthOfFullRun):
231         (WebCore::ComplexTextController::setupFontForScriptRun):
232         (WebCore::ComplexTextController::allocHarfbuzzFont):
233         (WebCore::ComplexTextController::deleteGlyphArrays):
234         (WebCore::ComplexTextController::createGlyphArrays):
235         (WebCore::ComplexTextController::resetGlyphArrays):
236         (WebCore::ComplexTextController::shapeGlyphs):
237         (WebCore::ComplexTextController::setGlyphXPositions):
238         (WebCore::ComplexTextController::normalizeSpacesAndMirrorChars):
239         (WebCore::ComplexTextController::getNormalizedTextRun):
240         * platform/graphics/chromium/ComplexTextControllerLinux.h: Added.
241         (WebCore::ComplexTextController::setWordSpacingAdjustment):
242         (WebCore::ComplexTextController::setLetterSpacingAdjustment):
243         (WebCore::ComplexTextController::letterSpacing):
244         (WebCore::ComplexTextController::setXOffsetToZero):
245         (WebCore::ComplexTextController::rtl):
246         (WebCore::ComplexTextController::glyphs):
247         (WebCore::ComplexTextController::length):
248         (WebCore::ComplexTextController::xPositions):
249         (WebCore::ComplexTextController::advances):
250         (WebCore::ComplexTextController::width):
251         (WebCore::ComplexTextController::logClusters):
252         (WebCore::ComplexTextController::numCodePoints):
253         (WebCore::ComplexTextController::fontPlatformDataForScriptRun):
254         (WebCore::ComplexTextController::isCodepointSpace):
255         * platform/graphics/chromium/FontLinux.cpp:
256         (WebCore::Font::drawComplexText):
257         (WebCore::Font::floatWidthForComplexText):
258         (WebCore::glyphIndexForXPositionInScriptRun):
259         (WebCore::Font::offsetForPositionForComplexText):
260         (WebCore::Font::selectionRectForComplexText):
261
262 2011-01-05  Pratik Solanki  <psolanki@apple.com>
263
264         Reviewed by Darin Adler.
265
266         Merge cf and mac header files with same name
267         https://bugs.webkit.org/show_bug.cgi?id=51916
268
269         Since most of the code in the header files is identical, we can merge them and have #if
270         USE(CFNETWORK) to separate out the network specific parts.
271
272         * WebCore.xcodeproj/project.pbxproj:
273         * platform/network/cf/AuthenticationChallenge.h:
274         (WebCore::AuthenticationChallenge::sender):
275         (WebCore::AuthenticationChallenge::nsURLAuthenticationChallenge):
276         * platform/network/cf/ResourceError.h:
277         (WebCore::ResourceError::ResourceError):
278         * platform/network/cf/ResourceRequest.h:
279         (WebCore::ResourceRequest::ResourceRequest):
280         * platform/network/cf/ResourceResponse.h:
281         (WebCore::ResourceResponse::ResourceResponse):
282         * platform/network/mac/AuthenticationChallenge.h: Removed.
283         * platform/network/mac/ResourceError.h: Removed.
284         * platform/network/mac/ResourceRequest.h: Removed.
285         * platform/network/mac/ResourceResponse.h: Removed.
286
287 2011-01-05  Anders Carlsson  <andersca@apple.com>
288
289         Reviewed by Adele Peterson.
290
291         Implement word transformation
292         https://bugs.webkit.org/show_bug.cgi?id=51943
293
294         Export Editor functions needed by WebKit2.
295
296         * WebCore.exp.in:
297
298 2011-01-05  Simon Fraser  <simon.fraser@apple.com>
299
300         Reviewed by Dave Hyatt.
301
302         Implement repeating CSS3 gradients
303         https://bugs.webkit.org/show_bug.cgi?id=51843
304         
305         Add support for repeating gradients, via the new gradient functions
306         -webkit-repeating-linear-gradient and -webkit-repeating-radial-gradient.
307
308         Tests: fast/gradients/css3-repeating-linear-gradients.html
309                fast/gradients/css3-repeating-radial-gradients.html
310
311         * css/CSSGradientValue.h:
312         (WebCore::CSSGradientValue::isRepeating): Accessor for whethe the gradient repeats.
313         (WebCore::CSSGradientValue::CSSGradientValue): Pass CSSGradientRepeat in.
314         (WebCore::CSSLinearGradientValue::create): Pass CSSGradientRepeat.
315         (WebCore::CSSLinearGradientValue::CSSLinearGradientValue): Ditto
316         (WebCore::CSSRadialGradientValue::create): Ditto.
317         (WebCore::CSSRadialGradientValue::CSSRadialGradientValue): Ditto.
318
319         * css/CSSGradientValue.cpp:
320         (WebCore::CSSGradientValue::addStops): Pass maxLengthForRepeat, which
321         is used for repeating radial gradients. Add code to repeat the stops,
322         adding stops before the start, and after the end until the 0-N range is
323         covered, where N is large enough to ensure the box is covered. Fix an issue
324         with repeating gradients where if both stops were < 0, it would fail to clamp
325         them to 0.
326         
327         (WebCore::CSSLinearGradientValue::cssText): Output strings for repeating gradients.
328         (WebCore::CSSLinearGradientValue::createGradient): maxExtent for linear gradients is 1,
329         because they are guaranteed to fill the box already.
330         (WebCore::CSSRadialGradientValue::cssText): Output strings for repeating gradients.
331         (WebCore::CSSRadialGradientValue::createGradient): Compute the distance to the furthest
332         corner in order to inform addStops() how much additional extent is required.
333
334         * css/CSSParser.cpp:
335         (WebCore::CSSParser::parseDeprecatedGradient): Old gradients never repeat.
336         (WebCore::CSSParser::parseLinearGradient): Pass down CSSGradientRepeat.
337         (WebCore::CSSParser::parseRadialGradient): Ditto.
338         (WebCore::CSSParser::isGeneratedImageValue): Add repeating gradient functions.
339         (WebCore::CSSParser::parseGeneratedImage): Ditto.
340         * css/CSSParser.h: Pass CSSGradientRepeat to gradient functions.
341         * platform/graphics/cg/GradientCG.cpp: Remove unused #include.
342
343 2011-01-05  Martin Robinson  <mrobinson@igalia.com>
344
345         Reviewed by Ariya Hidayat.
346
347         ContextShadow::blurLayerImage() not endian-safe
348         https://bugs.webkit.org/show_bug.cgi?id=51822
349
350         Correct the channel map in ContextShadow to reflect the different
351         ordering of pixels on processors with different endianness.
352
353         No new tests. This is covered by the existing shadow tests. It was
354         not discovered, because all of the bots using ContextShadow are
355         little-endian.
356
357         * platform/graphics/ContextShadow.cpp:
358         (WebCore::ContextShadow::blurLayerImage): Initialize the channel mapping
359         based on machine endianness.
360
361 2011-01-05  Mihai Parparita  <mihaip@chromium.org>
362
363         Reviewed by Nate Chapin.
364
365         [Chromium] Crash when drawing PDF plug-in scrollbars
366         https://bugs.webkit.org/show_bug.cgi?id=51942
367
368         Pepper plug-in scrollbars don't have a parent, guard against that before
369         seeing if the parent is a FrameView.
370
371         Not testable via layout tests, verified fix by hand.
372         
373         * platform/chromium/ScrollbarThemeChromiumMac.mm:
374         (WebCore::ScrollbarThemeChromiumMac::paint):
375
376 2011-01-05  Abhishek Arya  <inferno@chromium.org>
377
378         Unreviewed.
379
380         Update FIXME comment to sound better. Also initialize the block to fix compile.
381
382         * rendering/RenderBlock.cpp:
383         (WebCore::RenderBlock::removeChild):
384
385 2011-01-05  Abhishek Arya  <inferno@chromium.org>
386
387         Reviewed by Dave Hyatt.
388
389         Do not merge anonymous blocks when one of them is the one getting removed.
390         https://bugs.webkit.org/show_bug.cgi?id=51919
391
392         Test: fast/block/merge-anonymous-block-remove-child-crash.html
393
394         * rendering/RenderBlock.cpp:
395         (WebCore::RenderBlock::removeChild):
396
397 2011-01-05  Ryosuke Niwa  <rniwa@webkit.org>
398
399         Reviewed by Eric Seidel.
400
401         ApplyStyleCommand::applyRelativeFontStyleChange should take EditingStyle*
402         https://bugs.webkit.org/show_bug.cgi?id=50641
403
404         Modified applyRelativeFontStyleChange to take EditingStyle instead of CSSMutableStyleDeclaration.
405         Also extracted the logic to obtain the font size delta from ApplyStyleCommand to EditingStyle.
406         The font size delta is now stored as a member variable of EditingStyle as supposed to a property
407         in CSSMutableStyleDeclration as soon as EditingStyle is instantiated.
408
409         No new tests are added since this is a refactoring.
410
411         * editing/ApplyStyleCommand.cpp:
412         (WebCore::ApplyStyleCommand::doApply): Calls applyRelativeFontStyleChange.
413         (WebCore::ApplyStyleCommand::applyRelativeFontStyleChange): Takes EditingStyle.
414         * editing/ApplyStyleCommand.h:
415         * editing/EditingStyle.cpp:
416         (WebCore::EditingStyle::EditingStyle): Initializes m_fontSizeDelta.
417         (WebCore::EditingStyle::init): Ditto.
418         (WebCore::EditingStyle::extractFontSizeDelta): Extracted from applyRelativeFontStyleChange.
419         (WebCore::EditingStyle::isEmpty): Takes care of m_fontSizeDelta.
420         (WebCore::EditingStyle::setStyle): Calls extractFontSizeDelta.
421         (WebCore::EditingStyle::overrideWithStyle): Ditto.
422         (WebCore::EditingStyle::clear): Initializes m_fontSizeDelta.
423         (WebCore::EditingStyle::copy): Calls extractFontSizeDelta.
424         * editing/EditingStyle.h:
425         (WebCore::EditingStyle::fontSizeDelta): Added.
426         (WebCore::EditingStyle::hasFontSizeDelta): Added.
427         * editing/Editor.h:
428
429 2011-01-05  Dan Bernstein  <mitz@apple.com>
430
431         Reviewed by Darin Adler.
432
433         <rdar://problem/8799835> hyphenate-character: auto should fall back to hyphen-minus if the primary font lacks a hyphen glyph
434         https://bugs.webkit.org/show_bug.cgi?id=51915
435
436         This changes the results of existing tests in fast/text.
437
438         * platform/graphics/Font.h:
439         * platform/graphics/FontFastPath.cpp:
440         (WebCore::Font::primaryFontHasGlyphForCharacter): Added.
441         * rendering/style/RenderStyle.cpp:
442         * platform/graphics/qt/FontQt.cpp:
443         (WebCore::Font::primaryFontHasGlyphForCharacter): Added a stub.
444         (WebCore::RenderStyle::hyphenString): For hyphenate-character: auto, return a
445         hyphen only if the primary font has a hyphen glyph, and otherwise return a
446         hyphen-minus.
447
448 2011-01-05  Laszlo Gombos  <laszlo.1.gombos@nokia.com>
449
450         Reviewed by Ariya Hidayat.
451
452         [Qt] [Symbian] Make CONFIG-=def_files the default configuration for trunk builds
453         https://bugs.webkit.org/show_bug.cgi?id=51888
454
455         Overrule Qt's default from qconfig.pri for non-production builds so
456         that CONFIG(def_files) evaluates to false and QtWebKit trunk builds succeed.
457
458         No new tests as there is no new functionality.
459
460         * WebCore.pro:
461
462 2011-01-05  Sheriff Bot  <webkit.review.bot@gmail.com>
463
464         Unreviewed, rolling out r74778.
465         http://trac.webkit.org/changeset/74778
466         https://bugs.webkit.org/show_bug.cgi?id=51930
467
468         Android and QtWebKit-V8 uses V8DOMWindowShell::setContext.
469         (Requested by bbandix on #webkit).
470
471         * bindings/v8/V8DOMWindowShell.cpp:
472         (WebCore::V8DOMWindowShell::setContext):
473         * bindings/v8/V8DOMWindowShell.h:
474
475 2011-01-05  Yi Shen  <yi.4.shen@nokia.com>
476
477         Reviewed by Andreas Kling.
478
479         [Qt] Animated GIF images does not animate 10x as expected by default.
480         https://bugs.webkit.org/show_bug.cgi?id=36818
481
482         Add a test animated GIF which should be displayed 2 times and stop.
483
484         * manual-tests/animated-gif-looping.html:
485         * manual-tests/resources/animated-2x.gif: Added.
486
487 2011-01-05  Carlos Garcia Campos  <cgarcia@igalia.com>
488
489         Reviewed by Martin Robinson.
490
491         [GTK] Fork code of ScrollbarThemeGtk that will differ for GTK+ 3
492         https://bugs.webkit.org/show_bug.cgi?id=51923
493
494         Split out pieces of ScrollbarThemeGtk into ScrollbarThemeGtk2 and
495         ScrollbarThemeGtk3 that will differ between GTK+ 2 and GTK+ 3.
496
497         No new tests. This should not change functionality.
498
499         * GNUmakefile.am: Add ScrollbarThemeGtk2.cpp and ScrollbarThemeGtk3.cpp
500         * platform/gtk/ScrollbarThemeGtk.cpp:
501         (WebCore::ScrollbarThemeGtk::updateScrollbarsFrameThickness):
502         * platform/gtk/ScrollbarThemeGtk.h:
503         * platform/gtk/ScrollbarThemeGtk2.cpp: Added.
504         (WebCore::ScrollbarThemeGtk::updateThemeProperties):
505         (WebCore::ScrollbarThemeGtk::paintTrackBackground):
506         (WebCore::ScrollbarThemeGtk::paintScrollbarBackground):
507         (WebCore::ScrollbarThemeGtk::paintThumb):
508         (WebCore::ScrollbarThemeGtk::paintButton):
509         * platform/gtk/ScrollbarThemeGtk3.cpp: Added.
510         (WebCore::ScrollbarThemeGtk::updateThemeProperties):
511         (WebCore::ScrollbarThemeGtk::paintTrackBackground):
512         (WebCore::ScrollbarThemeGtk::paintScrollbarBackground):
513         (WebCore::ScrollbarThemeGtk::paintThumb):
514         (WebCore::ScrollbarThemeGtk::paintButton):
515
516 2011-01-05  Patrick Gansterer  <paroga@webkit.org>
517
518         Reviewed by Andreas Kling.
519
520         [CMake] Fix the usage of SOURCE_GROUP
521         https://bugs.webkit.org/show_bug.cgi?id=51739
522
523         * CMakeLists.txt:
524
525 2011-01-05  Andras Becsi  <abecsi@webkit.org>
526
527         Reviewed by Csaba Osztrogonác.
528
529         [Qt][V8] Fix the build after recent changes.
530
531         No new tests needed.
532
533         * WebCore.pro: Add missing files, and remove obsolete ones.
534
535 2011-01-05  Yong Li  <yoli@rim.com>
536
537         Reviewed by Adam Barth.
538
539         Suspend HTMLParserScheduler when page load is deferred to
540         avoid potential JS re-entrancy. Otherwise, when JS execution is triggered
541         from an external script or by events, and is blocked by a modal dialog,
542         WebKit can parse more HTML source and also start another JS execution.
543         
544         https://bugs.webkit.org/show_bug.cgi?id=48077
545
546         Test case: WebCore/manual-tests/bugzilla-48077.html.
547
548         * dom/DocumentParser.cpp:
549         (WebCore::DocumentParser::suspendScheduledTasks):
550         (WebCore::DocumentParser::resumeScheduledTasks):
551         * dom/DocumentParser.h:
552         * html/parser/HTMLDocumentParser.cpp:
553         (WebCore::HTMLDocumentParser::suspendScheduledTasks):
554         (WebCore::HTMLDocumentParser::resumeScheduledTasks):
555         * html/parser/HTMLParserScheduler.cpp:
556         (WebCore::HTMLParserScheduler::HTMLParserScheduler):
557         (WebCore::HTMLParserScheduler::suspend):
558         (WebCore::HTMLParserScheduler::resume):
559         * html/parser/HTMLParserScheduler.h:
560         (WebCore::HTMLParserScheduler::isScheduledForResume):
561         * page/PageGroupLoadDeferrer.cpp:
562         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
563         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
564
565 2011-01-05  Simon Hausmann  <simon.hausmann@nokia.com>
566
567         Reviewed by Kenneth Rohde Christiansen, Gustavo Noronha Silva
568
569         [GStreamer] MediaPlayerPrivateGStreamer::totalBytes() does not work reliably
570         https://bugs.webkit.org/show_bug.cgi?id=51926
571
572         Work around potential upstream bug: Querying a GstBin for the duration,
573         will forward the query to all sink children. Our WebKitWebSrc however
574         is a bin with only source children, therefore the query fails. Until
575         this is changed upstream, this patch works around it as follows,
576         based on suggestion by Philippe Normand and Sebastian Dröge:
577
578         When the initial query fails, attempt the same query on all source
579         pads and take the maximum length reported.
580
581         * platform/graphics/gstreamer/MediaPlayerPrivateGStreamer.cpp:
582         (WebCore::MediaPlayerPrivateGStreamer::totalBytes):
583
584 2011-01-05  Philippe Normand  <pnormand@igalia.com>
585
586         Rubber-stamped by Eric Seidel.
587
588         [GStreamer] build fails with gstreamer core 0.10.31 and -plugins-base 0.10.30
589         https://bugs.webkit.org/show_bug.cgi?id=51810
590
591         Based on a patch by Mart Raudsepp.
592
593         No new tests, build fix only.
594
595         * platform/graphics/gstreamer/GStreamerGWorld.cpp:
596         (WebCore::GStreamerGWorld::setWindowOverlay): Use the new xoverlay
597         API if the GST_CHECK_PLUGINS_BASE_VERSION macro is defined. It was
598         introduced in same version as the xoverlay API change.
599
600 2011-01-05  Leo Yang  <leo.yang@torchmobile.com.cn>
601
602         Reviewed by Dirk Schulze.
603
604         Malformed SVG causes crash in updateContainerOffset
605         https://bugs.webkit.org/show_bug.cgi?id=44610
606
607         We should check recursive <use> at the begining of
608         WebCore::SVGUseElement::buildInstanceTree instead
609         of at the end of it because the target element's
610         children may cause infinite recursive <use>.
611
612         Test: svg/custom/recursive-use.svg
613
614         * svg/SVGUseElement.cpp:
615         (WebCore::SVGUseElement::buildInstanceTree):
616         (WebCore::SVGUseElement::hasCycleUseReferencing):
617         * svg/SVGUseElement.h:
618
619 2011-01-04  Antti Koivisto  <antti@apple.com>
620
621         Reviewed by Dan Bernstein.
622
623         https://bugs.webkit.org/show_bug.cgi?id=51907
624         Style selector should only be recalculated when the pending sheet count goes to zero
625         
626         Shark says this is a significant performance improvement on some sites with lots of stylesheets.
627
628         * dom/Document.cpp:
629         (WebCore::Document::removePendingSheet):
630
631 2011-01-05  Carlos Garcia Campos  <cgarcia@igalia.com>
632
633         Reviewed by Martin Robinson.
634
635         [GTK] Use GtkStyleContext to get platform colors
636         https://bugs.webkit.org/show_bug.cgi?id=51830
637
638         Use GtkStyleContext API to get platform colors when building with
639         GTK+ 3.x.
640
641         No new tests. This should not change functionality.
642
643         * platform/graphics/Color.h: Add specialized constructor for GdkRGBA.
644         * platform/graphics/gtk/ColorGtk.cpp:
645         (WebCore::Color::Color):
646         (WebCore::Color::operator GdkRGBA):
647         * platform/gtk/RenderThemeGtk3.cpp:
648         (WebCore::RenderThemeGtk::platformActiveSelectionBackgroundColor):
649         (WebCore::RenderThemeGtk::platformInactiveSelectionBackgroundColor):
650         (WebCore::RenderThemeGtk::platformActiveSelectionForegroundColor):
651         (WebCore::RenderThemeGtk::platformInactiveSelectionForegroundColor):
652         (WebCore::RenderThemeGtk::activeListBoxSelectionBackgroundColor):
653         (WebCore::RenderThemeGtk::inactiveListBoxSelectionBackgroundColor):
654         (WebCore::RenderThemeGtk::activeListBoxSelectionForegroundColor):
655         (WebCore::RenderThemeGtk::inactiveListBoxSelectionForegroundColor):
656         (WebCore::RenderThemeGtk::systemColor):
657
658 2011-01-05  Carlos Garcia Campos  <cgarcia@igalia.com>
659
660         Unreviewed. Build fix for GTK when using gtk+-3 after r75009.
661
662         * platform/gtk/RenderThemeGtk3.cpp:
663         (WebCore::RenderThemeGtk::getStockIcon): Use adoptGRef instead of
664         adoptGRefPtr which doesn't exist.
665
666 2011-01-05  Alexey Proskuryakov  <ap@apple.com>
667
668         Reviewed by Sam Weinig.
669
670         https://bugs.webkit.org/show_bug.cgi?id=51903
671         Tell UI process which subframe is largest
672
673         * WebCore.exp.in: Exported FrameView::contentsSize().
674
675 2011-01-04  Chris Fleizach  <cfleizach@apple.com>
676
677         Unreviewed. GTK build fix.
678
679         WK2: Support Accessibility
680         https://bugs.webkit.org/show_bug.cgi?id=51859
681
682         * page/FrameView.cpp:
683         (WebCore::FrameView::axObjectCache):
684
685 2011-01-04  Sheriff Bot  <webkit.review.bot@gmail.com>
686
687         Unreviewed, rolling out r74992.
688         http://trac.webkit.org/changeset/74992
689         https://bugs.webkit.org/show_bug.cgi?id=51917
690
691         Crash in HTMLDocumentParser::suspendScheduledTasks()
692         (Requested by tkent on #webkit).
693
694         * dom/DocumentParser.cpp:
695         * dom/DocumentParser.h:
696         * html/parser/HTMLDocumentParser.cpp:
697         * html/parser/HTMLDocumentParser.h:
698         * html/parser/HTMLParserScheduler.cpp:
699         (WebCore::HTMLParserScheduler::HTMLParserScheduler):
700         * html/parser/HTMLParserScheduler.h:
701         (WebCore::HTMLParserScheduler::isScheduledForResume):
702         * page/PageGroupLoadDeferrer.cpp:
703         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
704         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
705
706 2011-01-04  Benjamin Poulain  <benjamin.poulain@nokia.com>
707
708         Reviewed by Kenneth Rohde Christiansen.
709
710         [Qt] [WK2] Add support for non-trivial context menu action
711         https://bugs.webkit.org/show_bug.cgi?id=51902
712
713         Fix the preprocessor guard for ContextMenuItemTagSelectAll in
714         the implementation of ContextMenuController::contextMenuItemSelected(). The guard was
715         inconsistent with what is defined in ContextMenuItem.h.
716
717         * page/ContextMenuController.cpp:
718         (WebCore::ContextMenuController::contextMenuItemSelected):
719
720 2011-01-04  Tony Gentilcore  <tonyg@chromium.org>
721
722         Reviewed by Ryosuke Niwa.
723
724         Avoid manual ref/deref in AsyncScriptRunner by using PendingScript
725         https://bugs.webkit.org/show_bug.cgi?id=51723
726
727         ScriptElement should also be able to keep its Element+CachedScript in
728         a PendingScript, and then executeScriptSoon can accept a PendingScript.
729         Once HTMLScriptRunner, ScriptElement, and AsyncScriptRunner all use
730         PendingScripts, then generic request and execute which operate on
731         PendingScripts can be factored out to avoid code duplicate that we have.
732
733         No new tests because no new functionality.
734
735         * dom/AsyncScriptRunner.cpp:
736         (WebCore::AsyncScriptRunner::~AsyncScriptRunner):
737         (WebCore::AsyncScriptRunner::executeScriptSoon):
738         (WebCore::AsyncScriptRunner::timerFired):
739         * dom/AsyncScriptRunner.h:
740         * dom/PendingScript.h: Add ctor which sets element and cachedScript. Rename adoptElement->setElement.
741         * dom/HTMLScriptRunner.cpp:
742         (WebCore::HTMLScriptRunner::requestPendingScript):
743
744 2011-01-04  Jeff Miller  <jeffm@apple.com>
745
746         Reviewed by Darin Adler.
747
748         Member variable and method naming cleanup to be consistent with WebKit2.
749         https://bugs.webkit.org/show_bug.cgi?id=51228
750
751         * page/win/EventHandlerWin.cpp:
752         (WebCore::EventHandler::eventActivatedView):
753         Rename activatedWebView() to didActivateWebView().
754         
755         * platform/PlatformMouseEvent.h:
756         Rename m_activatedWebView to m_didActivateWebView.
757         
758         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
759         Initialize platform-specific member variables in PlatformMouseEvent constructors.
760         
761         (WebCore::PlatformMouseEvent::didActivateWebView):
762         Rename activatedWebView() to didActivateWebView().
763
764         * platform/win/PlatformMouseEventWin.cpp:
765         (WebCore::PlatformMouseEvent::PlatformMouseEvent):
766         Rename m_activatedWebView to m_didActivateWebView.
767
768 2011-01-04  Yael Aharon  <yael.aharon@nokia.com>
769
770         Reviewed by Darin Adler.
771
772         CSS3 :nth-child selector and valid whitespace test fails
773         https://bugs.webkit.org/show_bug.cgi?id=36279
774
775         Teach the tokenizer to allow white spaces around [+/-] signs in nth constructs.
776
777         Test: fast/css/css3-nth-space.html
778
779         * css/tokenizer.flex:
780
781 2011-01-04  Chris Fleizach  <cfleizach@apple.com>
782
783         Unreviewed. Build fix.
784
785         WK2: Support Accessibility
786         https://bugs.webkit.org/show_bug.cgi?id=51859
787
788         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
789         (fallbackObject):
790
791 2011-01-04  Cosmin Truta  <ctruta@chromium.org>
792
793         Reviewed by Eric Seidel.
794
795         [chromium] PNG compression settings optimized for speed
796         https://bugs.webkit.org/show_bug.cgi?id=51719
797
798         Although Z_HUFFMAN_ONLY is the fastest on hard-to-compress images,
799         it is also the slowest, by a wide margin, on easy-to-compress images.
800         Use a more balanced configuration, based on the libpng compression defaults,
801         but with a faster compression level (3 instead of 6), and a faster filter
802         ("sub" instead of "all").
803
804         No change in behaviour, so no new tests.
805
806         * platform/image-encoders/skia/PNGImageEncoder.cpp:
807         (WebCore::PNGImageEncoder::encode):
808
809 2011-01-04  Chris Fleizach  <cfleizach@apple.com>
810
811         Reviewed by Sam Weinig.
812
813         WK2: Support Accessibility
814         https://bugs.webkit.org/show_bug.cgi?id=51859
815
816         WK2 doesn't use platform scroll views anymore. Accessibility code
817         needs to have its own scroll views. 
818
819         Test: platform/mac/accessibility/webkit-scrollarea.html
820
821         * CMakeLists.txt:
822         * GNUmakefile.am:
823         * WebCore.exp.in:
824         * WebCore.gypi:
825         * WebCore.pro:
826         * WebCore.vcproj/WebCore.vcproj:
827         * WebCore.xcodeproj/project.pbxproj:
828         * accessibility/AXObjectCache.cpp:
829         (WebCore::AXObjectCache::AXObjectCache):
830         (WebCore::AXObjectCache::get):
831         (WebCore::AXObjectCache::getOrCreate):
832         (WebCore::AXObjectCache::rootObject):
833         (WebCore::AXObjectCache::remove):
834         (WebCore::AXObjectCache::handleScrollbarUpdate):
835         * accessibility/AXObjectCache.h:
836         (WebCore::AXObjectCache::handleScrollbarUpdate):
837         * accessibility/AccessibilityARIAGrid.h:
838         * accessibility/AccessibilityAllInOne.cpp:
839         * accessibility/AccessibilityImageMapLink.cpp:
840         * accessibility/AccessibilityImageMapLink.h:
841         * accessibility/AccessibilityListBoxOption.cpp:
842         * accessibility/AccessibilityListBoxOption.h:
843         * accessibility/AccessibilityObject.cpp:
844         (WebCore::AccessibilityObject::updateChildrenIfNecessary):
845         (WebCore::AccessibilityObject::elementAccessibilityHitTest):
846         (WebCore::AccessibilityObject::axObjectCache):
847         (WebCore::AccessibilityObject::focusedUIElement):
848         * accessibility/AccessibilityObject.h:
849         (WebCore::AccessibilityObject::isAccessibilityScrollView):
850         (WebCore::AccessibilityObject::isScrollView):
851         (WebCore::AccessibilityObject::canSetNumericValue):
852         (WebCore::AccessibilityObject::scrollBar):
853         (WebCore::AccessibilityObject::size):
854         (WebCore::AccessibilityObject::setValue):
855         * accessibility/AccessibilityRenderObject.cpp:
856         (WebCore::AccessibilityRenderObject::parentObject):
857         (WebCore::AccessibilityRenderObject::accessibilityHitTest):
858         (WebCore::AccessibilityRenderObject::updateChildrenIfNecessary):
859         (WebCore::AccessibilityRenderObject::addChildren):
860         * accessibility/AccessibilityRenderObject.h:
861         * accessibility/AccessibilityScrollView.cpp: Added.
862         (WebCore::AccessibilityScrollView::AccessibilityScrollView):
863         (WebCore::AccessibilityScrollView::create):
864         (WebCore::AccessibilityScrollView::scrollBar):
865         (WebCore::AccessibilityScrollView::children):
866         (WebCore::AccessibilityScrollView::updateChildrenIfNecessary):
867         (WebCore::AccessibilityScrollView::removeChildScrollbar):
868         (WebCore::AccessibilityScrollView::addChildScrollbar):
869         (WebCore::AccessibilityScrollView::addChildren):
870         (WebCore::AccessibilityScrollView::webAreaObject):
871         (WebCore::AccessibilityScrollView::accessibilityHitTest):
872         (WebCore::AccessibilityScrollView::document):
873         (WebCore::AccessibilityScrollView::elementRect):
874         (WebCore::AccessibilityScrollView::parentObject):
875         * accessibility/AccessibilityScrollView.h: Added.
876         (WebCore::AccessibilityScrollView::roleValue):
877         (WebCore::AccessibilityScrollView::scrollView):
878         (WebCore::AccessibilityScrollView::accessibilityIsIgnored):
879         (WebCore::AccessibilityScrollView::isAccessibilityScrollView):
880         (WebCore::toAccessibilityScrollView):
881         * accessibility/AccessibilityScrollbar.cpp:
882         (WebCore::AccessibilityScrollbar::AccessibilityScrollbar):
883         (WebCore::AccessibilityScrollbar::create):
884         (WebCore::AccessibilityScrollbar::elementRect):
885         (WebCore::AccessibilityScrollbar::document):
886         (WebCore::AccessibilityScrollbar::orientation):
887         (WebCore::AccessibilityScrollbar::isEnabled):
888         (WebCore::AccessibilityScrollbar::valueForRange):
889         (WebCore::AccessibilityScrollbar::setValue):
890         * accessibility/AccessibilityScrollbar.h:
891         (WebCore::AccessibilityScrollbar::setParent):
892         (WebCore::AccessibilityScrollbar::canSetValueAttribute):
893         (WebCore::AccessibilityScrollbar::canSetNumericValue):
894         (WebCore::AccessibilityScrollbar::isAccessibilityScrollbar):
895         (WebCore::AccessibilityScrollbar::parentObject):
896         (WebCore::AccessibilityScrollbar::roleValue):
897         * accessibility/mac/AccessibilityObjectMac.mm:
898         (WebCore::AccessibilityObject::accessibilityIgnoreAttachment):
899         * accessibility/mac/AccessibilityObjectWrapper.mm:
900         (-[AccessibilityObjectWrapper accessibilityAttributeNames]):
901         (-[AccessibilityObjectWrapper remoteAccessibilityParentObject]):
902         (-[AccessibilityObjectWrapper position]):
903         (-[AccessibilityObjectWrapper scrollViewParent]):
904         (-[AccessibilityObjectWrapper accessibilityAttributeValue:]):
905         (-[AccessibilityObjectWrapper accessibilityHitTest:]):
906         (-[AccessibilityObjectWrapper accessibilitySetValue:forAttribute:]):
907         * dom/Document.cpp:
908         (WebCore::Document::axObjectCache):
909         * loader/EmptyClients.h:
910         (WebCore::EmptyFrameLoaderClient::accessibilityRemoteObject):
911         * loader/FrameLoaderClient.h:
912         * page/FrameView.cpp:
913         (WebCore::FrameView::~FrameView):
914         (WebCore::FrameView::axObjectCache):
915         * page/FrameView.h:
916         * platform/ScrollView.cpp:
917         (WebCore::ScrollView::setHasHorizontalScrollbar):
918         (WebCore::ScrollView::setHasVerticalScrollbar):
919         * platform/Scrollbar.cpp:
920         (WebCore::Scrollbar::~Scrollbar):
921         (WebCore::Scrollbar::scroll):
922         (WebCore::Scrollbar::axObjectCache):
923         * platform/Scrollbar.h:
924         * platform/Widget.h:
925         (WebCore::Widget::axObjectCache):
926
927 2011-01-04  W. James MacLean  <wjmaclean@chromium.org>
928
929         Reviewed by Kenneth Russell.
930
931         [chromium] Add support to compositor to composite to offscreen texture.
932         https://bugs.webkit.org/show_bug.cgi?id=50833
933
934         A patch to extend compositor to be able to composite into an offscreen texture instead
935         of just directly to the display buffer. Builds on RenderSurfaceChromium support.
936         Explicitly resets alpha channel before rendering to display.
937
938         * platform/graphics/chromium/LayerRendererChromium.cpp:
939         (WebCore::LayerRendererChromium::LayerRendererChromium):
940         (WebCore::LayerRendererChromium::updateAndDrawRootLayer):
941         (WebCore::LayerRendererChromium::drawLayers):
942         (WebCore::LayerRendererChromium::setCompositeOffscreen):
943         (WebCore::LayerRendererChromium::useRenderSurface):
944         (WebCore::LayerRendererChromium::setScissorToRect):
945         * platform/graphics/chromium/LayerRendererChromium.h:
946         (WebCore::LayerRendererChromium::isCompositingOffscreen):
947         (WebCore::LayerRendererChromium::getOffscreenLayerTexture):
948
949 2011-01-04  Evan Martin  <evan@chromium.org>
950
951         Reviewed by Tony Chang.
952
953         [chromium] depend on harfbuzz explicitly
954         https://bugs.webkit.org/show_bug.cgi?id=51895
955
956         platform/graphics/chromium uses Harfbuzz directly.  Rather than
957         expecting Skia to adjust the include paths, be explicit about
958         the dependency.
959
960         * WebCore.gyp/WebCore.gyp:
961
962 2011-01-04  Darin Adler  <darin@apple.com>
963
964         Reviewed by Brady Eidson.
965
966         Add back/forward encoding and decoding to WebKit2
967         https://bugs.webkit.org/show_bug.cgi?id=51901
968
969         * WebCore.exp.in: Export functions used in WebKit2.
970
971         * history/HistoryItem.cpp:
972         (WebCore::HistoryItem::encodeBackForwardTree): Use references instead of pointers.
973         (WebCore::HistoryItem::encodeBackForwardTreeNode): Ditto.
974         (WebCore::HistoryItem::decodeBackForwardTree): Ditto.
975         * history/HistoryItem.h: Ditto.
976         * platform/network/FormData.cpp:
977         (WebCore::encode): Ditto.
978         (WebCore::decode): Ditto.
979         (WebCore::FormData::encodeForBackForward): Ditto.
980         (WebCore::FormData::decodeForBackForward): Ditto.
981         * platform/network/FormData.h: Ditto.
982
983 2011-01-04  Xiaomei Ji  <xji@chromium.org>
984
985         Reviewed by Dan Bernstein.
986
987         Implement sel.modify('move', 'left'/'right', 'lineBoundary').
988         https://bugs.webkit.org/show_bug.cgi?id=33435
989
990         * editing/SelectionController.cpp:
991         (WebCore::SelectionController::modifyMovingRight):
992         (WebCore::SelectionController::modifyMovingLeft):
993         * editing/visible_units.cpp:
994         (WebCore::logicalStartOfLine):
995         (WebCore::logicalEndOfLine):
996         (WebCore::leftBoundaryOfLine):
997         (WebCore::rightBoundaryOfLine):
998         * editing/visible_units.h:
999
1000 2011-01-04  Martin Robinson  <mrobinson@igalia.com>
1001
1002         Reviewed by Xan Lopez.
1003
1004         [GTK] Use the default CSS text input control border width of relying on the GTK+ theme
1005         https://bugs.webkit.org/show_bug.cgi?id=51887
1006
1007         Do not rely on the GTK+ theme to determine text control borders. This simplifies
1008         the RenderTheme code, prevents metrics differences between GTK+ 2.x and 3.x and
1009         doesn't break the rendering of any theme that I've encountered.
1010
1011         * platform/gtk/RenderThemeGtk.cpp:
1012         (WebCore::RenderThemeGtk::adjustSearchFieldStyle): No longer call setTextInputBorders, but
1013         still disable any border radius.
1014         * platform/gtk/RenderThemeGtk.h: Remove setTextInputBorders and no longer override the
1015         default style of text areas and text input controls.
1016         * platform/gtk/RenderThemeGtk2.cpp: Ditto.
1017         * platform/gtk/RenderThemeGtk3.cpp: Ditto.
1018
1019 2011-01-03  Martin Robinson  <mrobinson@igalia.com>
1020
1021         Reviewed by Darin Adler.
1022
1023         Remove the last non-GObject usage of PlatformRefPtr and move the code to GRefPtr
1024         https://bugs.webkit.org/show_bug.cgi?id=51846
1025
1026         No new tests. This should not introduce any functional changes.
1027
1028         Changed all references to PlatformRefPtr in GTK+ code to GRefPtr. Changed
1029         all references to PlatformRefPtr in Brew code to RefPtr.
1030
1031 2011-01-04  David Kilzer  <ddkilzer@apple.com>
1032
1033         <http://webkit.org/b/51890> Move ResourceLoadPriority.h into WebCore/platform/network
1034
1035         Reviewed by Antti Koivisto.
1036
1037         This is needed to prevent a WebCore/platform policy violation in
1038         my next patch.
1039
1040         * WebCore.gypi: Updated for moved header.
1041         * WebCore.pro: Ditto.
1042         * WebCore.vcproj/WebCore.vcproj: Ditto.
1043         * WebCore.xcodeproj/project.pbxproj: Ditto.
1044         * platform/network/ResourceLoadPriority.h: Renamed from WebCore/loader/ResourceLoadPriority.h.
1045
1046 2011-01-04  Brady Eidson  <beidson@apple.com>
1047
1048         Reviewed by a spell checker.
1049
1050         * storage/StorageMap.h: mesured?  Really?
1051
1052 2011-01-04  Carlos Garcia Campos  <cgarcia@igalia.com> and Martin Robinson  <mrobinson@igalia.com>
1053
1054         Reviewed by Xan Lopez.
1055
1056         [GTK] Port stock icon painting to GtkStyleContext
1057         https://bugs.webkit.org/show_bug.cgi?id=51764
1058
1059         Port stock icon painting for media and search input elements to
1060         GtkStyleContext. Also create the initial machinery for accessing
1061         style contexts for all GTK+ 3.x based widgets.
1062
1063         No new tests. This should not change functionality.
1064
1065         * platform/gtk/RenderThemeGtk.cpp:
1066         (WebCore::paintGdkPixbuf):
1067         (WebCore::RenderThemeGtk::paintSearchFieldResultsDecoration):
1068         (WebCore::RenderThemeGtk::paintSearchFieldCancelButton):
1069         (WebCore::RenderThemeGtk::paintMediaButton):
1070         * platform/gtk/RenderThemeGtk.h:
1071         * platform/gtk/RenderThemeGtk2.cpp:
1072         (WebCore::RenderThemeGtk::getStockIcon):
1073         * platform/gtk/RenderThemeGtk3.cpp:
1074         (WebCore::gtkStyleChangedCallback):
1075         (WebCore::styleContextMap):
1076         (WebCore::getStyleContext):
1077         (WebCore::RenderThemeGtk::paintMenuList):
1078
1079 2010-12-31  Antti Koivisto  <antti@apple.com>
1080
1081         Reviewed by Dave Hyatt.
1082
1083         Scripts should not be executed before preceding stylesheets are loaded
1084         https://bugs.webkit.org/show_bug.cgi?id=8852
1085
1086         Block inline script execution on pending stylesheet loads. This matches
1087         other browsers and HTML5.
1088
1089         Tests: fast/tokenizer/inline-script-stylesheet-write.html
1090                fast/tokenizer/inline-script-stylesheet.html
1091
1092         * dom/PendingScript.cpp:
1093         (WebCore::PendingScript::releaseElementAndClear):
1094         * dom/PendingScript.h:
1095         (WebCore::PendingScript::PendingScript):
1096         (WebCore::PendingScript::operator=):
1097         (WebCore::PendingScript::startingPosition):
1098         (WebCore::PendingScript::setStartingPosition):
1099         * html/HTMLLinkElement.cpp:
1100         (WebCore::HTMLLinkElement::process):
1101         
1102         This fixes an unrelated bug with beforeload events that was exposed by the other
1103         changes (fast/dom/beforeload/remove-link-in-beforeload-listener.html).
1104         
1105         * html/parser/HTMLScriptRunner.cpp:
1106         (WebCore::HTMLScriptRunner::sourceFromPendingScript):
1107         (WebCore::HTMLScriptRunner::runScript):
1108
1109 2011-01-04  Xianzhu Wang  <wangxianzhu@google.com>
1110
1111         Reviewed by Darin Adler.
1112
1113         Let DataView.getInt8() and DataView.setInt8() use int8_t instead of
1114         ambiguous 'char' to fix fast/canvas/webgl/data-view-test.html failure
1115         on ARM.
1116         https://bugs.webkit.org/show_bug.cgi?id=51861
1117
1118         By the way, changed other getIntXX() and setIntXX() methods to use
1119         more precise integer types.
1120
1121         * bindings/js/JSDataViewCustom.cpp:
1122         (WebCore::setDataViewMember):
1123         * bindings/v8/custom/V8DataViewCustom.cpp:
1124         (WebCore::V8DataView::getInt8Callback):
1125         (WebCore::V8DataView::setInt8Callback):
1126         * html/canvas/DataView.cpp:
1127         (WebCore::DataView::getInt8):
1128         (WebCore::DataView::setInt8):
1129         * html/canvas/DataView.h:
1130         * html/canvas/DataView.idl:
1131
1132 2011-01-04  Yong Li  <yoli@rim.com>
1133
1134         Reviewed by Adam Barth.
1135
1136         Suspend HTMLParserScheduler when page load is deferred to
1137         avoid potential JS re-entrancy. Otherwise, when JS execution is triggered
1138         from an external script or by events, and is blocked by a modal dialog,
1139         WebKit can parse more HTML source and also start another JS execution.
1140         
1141         https://bugs.webkit.org/show_bug.cgi?id=48077
1142
1143         Test case: WebCore/manual-tests/bugzilla-48077.html.
1144
1145         * dom/DocumentParser.cpp:
1146         (WebCore::DocumentParser::suspendScheduledTasks):
1147         (WebCore::DocumentParser::resumeScheduledTasks):
1148         * dom/DocumentParser.h:
1149         * html/parser/HTMLDocumentParser.cpp:
1150         (WebCore::HTMLDocumentParser::suspendScheduledTasks):
1151         (WebCore::HTMLDocumentParser::resumeScheduledTasks):
1152         * html/parser/HTMLParserScheduler.cpp:
1153         (WebCore::HTMLParserScheduler::HTMLParserScheduler):
1154         (WebCore::HTMLParserScheduler::suspend):
1155         (WebCore::HTMLParserScheduler::resume):
1156         * html/parser/HTMLParserScheduler.h:
1157         (WebCore::HTMLParserScheduler::isScheduledForResume):
1158         * page/PageGroupLoadDeferrer.cpp:
1159         (WebCore::PageGroupLoadDeferrer::PageGroupLoadDeferrer):
1160         (WebCore::PageGroupLoadDeferrer::~PageGroupLoadDeferrer):
1161
1162 2011-01-04  Tony Gentilcore  <tonyg@chromium.org>
1163
1164         Unreviewed build fix.
1165
1166         Include glib-object.h for GObject
1167         https://bugs.webkit.org/show_bug.cgi?id=51876
1168
1169         * bindings/gobject/DOMObjectCache.cpp:
1170
1171 2011-01-04  Ryosuke Niwa  <rniwa@webkit.org>
1172
1173         Reviewed by Dan Bernstein.
1174
1175         Clicking on the first or the last letter of LTR/RTL text in a RTL/LTR block puts caret on the opposite side.
1176         https://bugs.webkit.org/show_bug.cgi?id=50992
1177
1178         Fixed the bug by interchanging the offset when the direction of inline text box and the containing block
1179         does not match. Reused the code added by http://trac.webkit.org/changeset/73553.
1180
1181         Test: editing/selection/caret-bidi-first-and-last-letters.html
1182
1183         * rendering/InlineTextBox.cpp:
1184         (WebCore::InlineTextBox::offsetForPosition):
1185
1186 2010-12-29  Tony Gentilcore  <tonyg@chromium.org>
1187
1188         Reviewed by Darin Adler.
1189
1190         Remove 2 unnecessary includes from Document.h
1191         https://bugs.webkit.org/show_bug.cgi?id=51727
1192
1193         No new tests because no changed functionality.
1194
1195         * dom/Document.cpp:
1196         * dom/Document.h:
1197         * editing/Editor.cpp:
1198         * editing/SpellChecker.h:
1199         * editing/SplitTextNodeCommand.cpp:
1200         * editing/TextCheckingHelper.cpp:
1201         * page/FrameView.cpp:
1202         * page/Page.cpp:
1203         * rendering/HitTestResult.cpp:
1204         * rendering/InlineTextBox.cpp:
1205         * rendering/InlineTextBox.h:
1206         * rendering/svg/SVGInlineFlowBox.cpp:
1207
1208 2011-01-04  Patrick Gansterer  <paroga@webkit.org>
1209
1210         Unreviewed WinCE build fix.
1211
1212         * CMakeListsWinCE.txt: Added missing include directories, files and libraries.
1213
1214 2011-01-04  Yi Shen  <yi.4.shen@nokia.com>
1215
1216         Reviewed by Simon Hausmann.
1217
1218         Provide an interface to require using fullscreen mediaplayer
1219         https://bugs.webkit.org/show_bug.cgi?id=51133
1220
1221         Only video should be displayed in fullscreen when 
1222         requiresFullscreenForVideoPlayback is specified.
1223
1224         No new tests because no client implements requiresFullscreenForVideoPlayback yet.
1225
1226         * html/HTMLMediaElement.cpp:
1227         (WebCore::HTMLMediaElement::updatePlayState):
1228
1229 2011-01-04  Benjamin Poulain  <benjamin.poulain@nokia.com>
1230
1231         Reviewed by Kenneth Rohde Christiansen.
1232
1233         [Qt] [WK2] create an initial implementation of the context menu handling for WebKit 2
1234         https://bugs.webkit.org/show_bug.cgi?id=51825
1235
1236         Implement contextMenuItemVector() for Qt, this method is used in WebKit 2 to get the
1237         platform independent menu informations.
1238
1239         * platform/qt/ContextMenuQt.cpp:
1240         (WebCore::contextMenuItemVector):
1241
1242 2011-01-04  Sheriff Bot  <webkit.review.bot@gmail.com>
1243
1244         Unreviewed, rolling out r74960.
1245         http://trac.webkit.org/changeset/74960
1246         https://bugs.webkit.org/show_bug.cgi?id=51868
1247
1248         Rollout since we hit an assert after this patch. (Requested by
1249         krit on #webkit).
1250
1251         * svg/SVGUseElement.cpp:
1252         (WebCore::SVGUseElement::buildInstanceTree):
1253
1254 2011-01-04  Sheriff Bot  <webkit.review.bot@gmail.com>
1255
1256         Unreviewed, rolling out r74961.
1257         http://trac.webkit.org/changeset/74961
1258         https://bugs.webkit.org/show_bug.cgi?id=51867
1259
1260         breaks 32/64-bits debug bots build (Requested by philn-tp on
1261         #webkit).
1262
1263         * platform/graphics/gstreamer/GStreamerGWorld.cpp:
1264         (WebCore::GStreamerGWorld::setWindowOverlay):
1265
1266 2011-01-03  Philippe Normand  <pnormand@igalia.com>
1267
1268         Rubber-stamped by Eric Seidel.
1269
1270         [GStreamer] build fails with gstreamer core 0.10.31 and -plugins-base 0.10.30
1271         https://bugs.webkit.org/show_bug.cgi?id=51810
1272
1273         Based on a patch by Mart Raudsepp.
1274
1275         No new tests, build fix only.
1276
1277         * platform/graphics/gstreamer/GStreamerGWorld.cpp:
1278         (WebCore::GStreamerGWorld::setWindowOverlay): Use the new xoverlay
1279         API if the GST_CHECK_PLUGINS_BASE_VERSION macro is defined. It was
1280         introduced in same version as the xoverlay API change.
1281
1282 2011-01-04  Leo Yang  <leo.yang@torchmobile.com.cn>
1283
1284         Reviewed by Dirk Schulze.
1285
1286         Malformed SVG causes crash in updateContainerOffset
1287         https://bugs.webkit.org/show_bug.cgi?id=44610
1288
1289         We should check recursive <use> at the begining of
1290         WebCore::SVGUseElement::buildInstanceTree instead
1291         of at the end of it because the target element's
1292         children may cause infinite recursive <use>.
1293
1294         Test: svg/custom/recursive-use.svg
1295
1296         * svg/SVGUseElement.cpp:
1297         (WebCore::SVGUseElement::buildInstanceTree):
1298
1299 2011-01-04  Kent Tamura  <tkent@chromium.org>
1300
1301         Unreviewed, build fix.
1302
1303         Try to fix Clang build.
1304
1305         * css/CSSParser.cpp:
1306         (WebCore::valueFromSideKeyword):
1307         (WebCore::CSSParser::parseLinearGradient):
1308
1309 2011-01-03  Julie-Jeongeun-Kim  <Jeongeun.Kim@obigo.com>
1310
1311         Reviewed by Darin Adler.
1312
1313         HTML5 Conformance Test failure: approved/xhtml5/object_border_pixel.xhtml
1314         https://bugs.webkit.org/show_bug.cgi?id=48596
1315         
1316         border attribute was not parsed in HTMLObjectElement.
1317         I added code for it as HTMLImageElement handled.
1318
1319         new test:fast/html/object-border.html
1320
1321         * html/HTMLObjectElement.cpp:
1322         (WebCore::HTMLObjectElement::parseMappedAttribute):
1323
1324 2011-01-03  Darin Adler  <darin@apple.com>
1325
1326         Try to fix Chromium build.
1327
1328         * history/HistoryItem.cpp:
1329         (WebCore::HistoryItem::encodeBackForwardTreeNode): Added a V8 case here.
1330         Not sure this ever will be used with V8.
1331         (WebCore::HistoryItem::decodeBackForwardTree): Ditto.
1332
1333 2011-01-03  Darin Adler  <darin@apple.com>
1334
1335         Try to fix Leopard build.
1336
1337         * history/HistoryItem.cpp: Use a consistent type, uint64_t, for the
1338         size variable.
1339
1340 2011-01-03  Abhishek Arya  <inferno@chromium.org>
1341
1342         Reviewed by Darin Adler.
1343
1344         Fixes before child calculation when adding anonymous childs to table parts.
1345         https://bugs.webkit.org/show_bug.cgi?id=50932
1346
1347         Fix in r74364 was incomplete. When before child is equal to the table part(to
1348         which the new child is getting added), it confuses the table part to add it
1349         incorrectly as an after child. The patch fixes by passing the before child as
1350         the table part's first child.
1351
1352         Tests: fast/css-generated-content/table-before-after-child-add.html
1353                fast/css-generated-content/table-cell-before-after-child-add.html
1354                fast/css-generated-content/table-row-before-after-child-add.html
1355                fast/css-generated-content/table-row-before-after-child-add.html
1356
1357         * rendering/RenderTable.cpp:
1358         (WebCore::RenderTable::addChild):
1359         * rendering/RenderTableRow.cpp:
1360         (WebCore::RenderTableRow::addChild):
1361         * rendering/RenderTableSection.cpp:
1362         (WebCore::RenderTableSection::addChild):
1363
1364 2011-01-03  Dan Bernstein  <mitz@apple.com>
1365
1366         Reviewed by Simon Fraser.
1367
1368         Shrink HTMLTableCellElement
1369         https://bugs.webkit.org/show_bug.cgi?id=51858
1370
1371         * html/HTMLTableCellElement.cpp:
1372         (WebCore::HTMLTableCellElement::HTMLTableCellElement): Removed intialization of m_row and
1373         m_col.
1374         * html/HTMLTableCellElement.h: Removed m_row and m_col and their accessors.
1375
1376 2011-01-03  Darin Adler  <darin@apple.com>
1377
1378         Fix build.
1379
1380         * platform/network/FormData.cpp:
1381         (WebCore::FormData::create): Roll back uint8_t change.
1382         (WebCore::FormData::flatten): Ditto.
1383         (WebCore::FormData::flattenToString): Ditto.
1384         (WebCore::encode): Ditto.
1385         (WebCore::decode): Ditto.
1386         (WebCore::FormData::encodeForBackForward):
1387         * platform/network/FormData.h: Ditto.
1388         * platform/network/mac/FormDataStreamMac.mm:
1389         (WebCore::advanceCurrentStream): Ditto.
1390
1391 2011-01-03  Darin Adler  <darin@apple.com>
1392
1393         Reviewed by Brady Eidson.
1394
1395         Add code to encode/decode the back/forward tree
1396         https://bugs.webkit.org/show_bug.cgi?id=51853
1397
1398         * history/HistoryItem.cpp:
1399         (WebCore::HistoryItem::encodeBackForwardTree): Added.
1400         (WebCore::HistoryItem::encodeBackForwardTreeNode): Added.
1401         (WebCore::HistoryItem::decodeBackForwardTree): Added.
1402         * history/HistoryItem.h: Added functions above.
1403
1404         * platform/network/FormData.cpp:
1405         (WebCore::FormData::create): Changed type to Vector<uint8_t> instead of
1406         Vector<char>. This type is used in our newer code for vectors of bytes.
1407         (WebCore::FormData::flatten): Ditto.
1408         (WebCore::FormData::flattenToString): Ditto. Had to add a cast here.
1409         (WebCore::FormData::encodeForBackForward): Added.
1410         (WebCore::FormData::decodeForBackForward): Added.
1411         * platform/network/FormData.h: Changed type to Vector<uint8_t> instead of
1412         Vector<char>. Also made some single-argument constructors explicit.
1413         Also added the new functions.
1414
1415         * platform/network/mac/FormDataStreamMac.mm:
1416         (WebCore::advanceCurrentStream): Changed to use uint8_t to match above.
1417
1418 2011-01-03  Simon Fraser  <simon.fraser@apple.com>
1419
1420         Attempt to fix GTK build.
1421
1422         * platform/graphics/gtk/FontGtk.cpp:
1423         (WebCore::drawGlyphsShadow):
1424
1425 2011-01-03  Helder Correia  <helder@sencha.com>
1426
1427         Reviewed by Simon Fraser.
1428
1429         ContextShadow can avoid code duplication for getting the CTM
1430         https://bugs.webkit.org/show_bug.cgi?id=51799
1431
1432         ContextShadow defines its own getTransformationMatrixFromContext()
1433         which does exactly the same as GraphicsContext::getCTM().
1434
1435         Existing tests: fast/canvas/canvas*shadow*html
1436
1437         * platform/graphics/ContextShadow.cpp:
1438         (WebCore::ContextShadow::mustUseContextShadow):
1439         (WebCore::ContextShadow::adjustBlurDistance):
1440         (WebCore::ContextShadow::calculateLayerBoundingRect):
1441         * platform/graphics/ContextShadow.h:
1442         * platform/graphics/cairo/ContextShadowCairo.cpp:
1443         (WebCore::ContextShadow::beginShadowLayer):
1444         (WebCore::ContextShadow::endShadowLayer):
1445         (WebCore::ContextShadow::drawRectShadowWithoutTiling):
1446         * platform/graphics/cairo/FontCairo.cpp:
1447         (WebCore::drawGlyphsShadow):
1448         * platform/graphics/cairo/GraphicsContextCairo.cpp:
1449         (WebCore::drawPathShadow):
1450         * platform/graphics/cairo/ImageCairo.cpp:
1451         (WebCore::BitmapImage::draw):
1452         * platform/graphics/gtk/FontGtk.cpp:
1453         (WebCore::drawGlyphsShadow):
1454         * platform/graphics/qt/ContextShadowQt.cpp:
1455         (WebCore::ContextShadow::beginShadowLayer):
1456         (WebCore::ContextShadow::endShadowLayer):
1457         * platform/graphics/qt/FontQt.cpp:
1458         (WebCore::drawTextCommon):
1459         * platform/graphics/qt/GraphicsContextQt.cpp:
1460         (WebCore::GraphicsContext::fillPath):
1461         (WebCore::GraphicsContext::strokePath):
1462         (WebCore::GraphicsContext::fillRect):
1463         (WebCore::GraphicsContext::fillRoundedRect):
1464         * platform/graphics/qt/ImageQt.cpp:
1465         (WebCore::BitmapImage::draw):
1466         * platform/graphics/qt/StillImageQt.cpp:
1467         (WebCore::StillImage::draw):
1468
1469 2011-01-03  Darin Adler  <darin@apple.com>
1470
1471         Reviewed by Dan Bernstein.
1472
1473         InsertTextCommand::m_charactersAdded is unused
1474         https://bugs.webkit.org/show_bug.cgi?id=51849
1475
1476         * editing/InsertTextCommand.cpp:
1477         (WebCore::InsertTextCommand::InsertTextCommand): Don't initialize m_charactersAdded.
1478         (WebCore::InsertTextCommand::input): Don't update m_charactersAdded.
1479         * editing/InsertTextCommand.h: Removed charactersAdded function and
1480         m_charactersAdded data member.
1481
1482 2011-01-03  Carlos Garcia Campos  <cgarcia@igalia.com>
1483
1484         Reviewed by Martin Robinson.
1485
1486         [GTK] Move paintMenuListButton() to RenderThemeGtk.cpp
1487         https://bugs.webkit.org/show_bug.cgi?id=51832
1488
1489         Method paintMenuListButton() contains code common to both gtk 2
1490         and 3, so it can be moved to RenderThemeGtk.cpp instead of
1491         duplicating it.
1492
1493         * platform/gtk/RenderThemeGtk.cpp:
1494         (WebCore::RenderThemeGtk::paintMenuListButton):
1495         * platform/gtk/RenderThemeGtk2.cpp:
1496         * platform/gtk/RenderThemeGtk3.cpp:
1497
1498 2011-01-03  Pratik Solanki  <psolanki@apple.com>
1499
1500         Reviewed by Darin Adler.
1501
1502         https://bugs.webkit.org/show_bug.cgi?id=51850
1503         Put CFNetwork loader code inside USE(CFNETWORK)
1504
1505         Add USE(CFNETWORK) macros around all the cf/mac network files. Also added all CFNetwork
1506         files to the WebCore Xcode project.
1507
1508         * WebCore.xcodeproj/project.pbxproj:
1509         * loader/cf/ResourceLoaderCFNet.cpp:
1510         * loader/mac/ResourceLoaderMac.mm:
1511         * platform/network/cf/AuthenticationCF.cpp:
1512         * platform/network/cf/AuthenticationCF.h:
1513         * platform/network/cf/CookieJarCFNet.cpp:
1514         * platform/network/cf/CookieStorageCFNet.cpp:
1515         * platform/network/cf/CookieStorageCFNet.h:
1516         * platform/network/cf/CredentialStorageCFNet.cpp:
1517         * platform/network/cf/FormDataStreamCFNet.cpp:
1518         * platform/network/cf/FormDataStreamCFNet.h:
1519         * platform/network/cf/LoaderRunLoopCF.cpp:
1520         * platform/network/cf/LoaderRunLoopCF.h:
1521         * platform/network/cf/ResourceError.h:
1522         * platform/network/cf/ResourceHandleCFNet.cpp:
1523         * platform/network/cf/ResourceRequest.h:
1524         * platform/network/cf/ResourceRequestCFNet.cpp:
1525         * platform/network/cf/ResourceRequestCFNet.h:
1526         * platform/network/cf/ResourceResponse.h:
1527         * platform/network/cf/ResourceResponseCFNet.cpp:
1528         * platform/network/mac/AuthenticationMac.h:
1529         * platform/network/mac/AuthenticationMac.mm:
1530         * platform/network/mac/FormDataStreamMac.h:
1531         * platform/network/mac/FormDataStreamMac.mm:
1532         * platform/network/mac/ResourceError.h:
1533         * platform/network/mac/ResourceHandleMac.mm:
1534         * platform/network/mac/ResourceRequest.h:
1535         * platform/network/mac/ResourceRequestMac.mm:
1536         * platform/network/mac/ResourceResponse.h:
1537         * platform/network/mac/ResourceResponseMac.mm:
1538
1539 2011-01-03  Yi Shen  <yi.4.shen@nokia.com>
1540
1541         Reviewed by Adam Barth.
1542
1543         [Qt] Add SelectAll option to the context menu for the editor
1544         https://bugs.webkit.org/show_bug.cgi?id=50049
1545
1546         Enable SelectAll for the Qt context menu.
1547
1548         * page/ContextMenuController.cpp:
1549         (WebCore::ContextMenuController::populate):
1550         * platform/ContextMenuItem.h:
1551         * platform/LocalizationStrategy.h:
1552         * platform/LocalizedStrings.cpp:
1553         (WebCore::contextMenuItemTagSelectAll):
1554         * platform/LocalizedStrings.h:
1555
1556 2011-01-03  Dan Bernstein  <mitz@apple.com>
1557
1558         Reviewed by Darin Adler.
1559
1560         Shrink RootInlineBox
1561         https://bugs.webkit.org/show_bug.cgi?id=51847
1562
1563         * rendering/RootInlineBox.cpp:
1564         (WebCore::RootInlineBox::alignBoxesInBlockDirection): Changed to use the baselineType()
1565         accessor.
1566         * rendering/RootInlineBox.h: Rolled m_baselineType into a bitfield. Changed its type to
1567         unsigned because otherwise MSVC treats it as signed.
1568         (WebCore::RootInlineBox::baselineType): Added a cast.
1569
1570 2011-01-03  Gustavo Noronha Silva  <gustavo.noronha@collabora.co.uk>
1571
1572         Reviewed by Martin Robinson.
1573
1574         [GTK] Split webkitprivate.{cpp,h} in more manageable chunks
1575         https://bugs.webkit.org/show_bug.cgi?id=50698
1576
1577         Fix DOM bindings generation to no longer include the now-gone
1578         webkitprivate.h header, including the appropriate replacements
1579         instead.
1580
1581         * bindings/scripts/CodeGeneratorGObject.pm:
1582
1583 2011-01-03  Brady Eidson  <beidson@apple.com>
1584
1585         Reviewed by Darin Adler.
1586
1587         Add Encode/Decode machinery Darin and I plan to work with for back/forward stuff in WebKit2.
1588
1589         * ForwardingHeaders/wtf/Decoder.h: Added.
1590         * ForwardingHeaders/wtf/Encoder.h: Added.
1591
1592 2011-01-03  Chris Fleizach  <cfleizach@apple.com>
1593
1594         Reviewed by Darin Adler.
1595
1596         AX: Regression: WebKit no longer auto-scrolls with VoiceOver navigation
1597         https://bugs.webkit.org/show_bug.cgi?id=51833
1598
1599         Make sure the web area returns the contentsSize, not the same size as what is displayed.
1600
1601         Test: platform/mac/accessibility/webarea-size-equals-content-size.html
1602
1603         * accessibility/AccessibilityRenderObject.cpp:
1604         (WebCore::AccessibilityRenderObject::boundingBoxRect):
1605
1606 2011-01-03  Simon Fraser  <simon.fraser@apple.com>
1607
1608         Fix warning in 32-bit builds.
1609
1610         * css/CSSGradientValue.cpp:
1611         (WebCore::CSSLinearGradientValue::createGradient):
1612
1613 2011-01-03  Benjamin C Meyer  <bmeyer@rim.com>
1614
1615         Reviewed by Daniel Bates.
1616
1617         In the cmake build system move logic related to ENABLE_NOTIFICATIONS into its own block.
1618         https://bugs.webkit.org/show_bug.cgi?id=51827
1619
1620         * CMakeLists.txt:
1621
1622 2011-01-03  Dan Bernstein  <mitz@apple.com>
1623
1624         Reviewed by Simon Fraser.
1625
1626         Remove the unused RenderTableCell::m_percentageHeight
1627         https://bugs.webkit.org/show_bug.cgi?id=51837
1628
1629         * rendering/RenderTableCell.cpp:
1630         (WebCore::RenderTableCell::RenderTableCell): Removed initialization of m_percentageHeight.
1631         * rendering/RenderTableCell.h: Removed m_percentageHeight.
1632
1633 2011-01-03  Simon Fraser  <simon.fraser@apple.com>
1634
1635         Reviewed by David Hyatt.
1636
1637         Implement -webkit-linear-gradient and -webkit-radial-gradient
1638         https://bugs.webkit.org/show_bug.cgi?id=28152
1639
1640         Add support for -webkit-radial-gradients.
1641
1642         Tests: fast/gradients/css3-radial-gradients.html
1643                fast/gradients/css3-radial-gradients2.html
1644
1645         * css/CSSGradientValue.cpp:
1646         (WebCore::blend): Used to blend colors, which is necessary when truncating
1647         the start of radial gradients.
1648         (WebCore::GradientStop): Small struct to aid gradient stop processing.
1649         (WebCore::CSSGradientValue::addStops): Rename 'positions' to 'stops', and store
1650         the color so that we can blend it when truncating radial gradients. Changed
1651         to handle both linear and radial gradients.
1652         (WebCore::CSSRadialGradientValue::cssText): Update to follow the spec.
1653         (WebCore::CSSRadialGradientValue::resolveRadius): Stylistic change.
1654         (WebCore::distanceToClosestCorner): New utility method.
1655         (WebCore::distanceToFarthestCorner): Ditto.
1656         (WebCore::CSSRadialGradientValue::createGradient): New logic to deal with shape and
1657         fill rules.
1658
1659         * css/CSSGradientValue.h:
1660         (WebCore::CSSGradientValue::isLinearGradient): Color-stop processing needs to know what
1661         kind of gradient it's dealing with, so add new isFooGradient methods.
1662         (WebCore::CSSGradientValue::isRadialGradient): Ditto.
1663         (WebCore::CSSLinearGradientValue::isLinearGradient):
1664         (WebCore::CSSRadialGradientValue::setShape): New setters for shape, size etc.
1665         (WebCore::CSSRadialGradientValue::setSizingBehavior):
1666         (WebCore::CSSRadialGradientValue::setEndHorizontalSize):
1667         (WebCore::CSSRadialGradientValue::setEndVerticalSize):
1668         (WebCore::CSSRadialGradientValue::isRadialGradient):
1669
1670         * css/CSSParser.h:
1671         * css/CSSParser.h: Pass a CSSParserValueList* into parseFillPositionXY() and parseFillPosition()
1672         so we can use parseFillPosition() when parsing a gradient function.
1673         * css/CSSParser.cpp:
1674         (WebCore::CSSParser::parseFillPositionXY): Pass in a CSSParserValueList*
1675         (WebCore::CSSParser::parseFillPosition): Ditto
1676         (WebCore::CSSParser::parseFillProperty): Pass m_valueList to parseFillPosition.
1677         (WebCore::CSSParser::parseTransformOriginShorthand): Ditto
1678         (WebCore::CSSParser::parseRadialGradient): Flesh out radial gradient parsing.
1679         (WebCore::CSSParser::parseTransformOrigin): Pass m_valueList to parseFillPosition.
1680         (WebCore::CSSParser::parsePerspectiveOrigin): Ditto
1681
1682         * css/CSSValueKeywords.in: New keywords for radial gradient shape and fill behaviors.
1683
1684         * platform/graphics/Gradient.cpp:
1685         (WebCore::Gradient::Gradient): Pass aspect ratio for elliptical gradients.
1686         * platform/graphics/Gradient.h: Add aspect ratio for elliptical gradients.
1687         (WebCore::Gradient::create):
1688         (WebCore::Gradient::startRadius): Expose radii.
1689         (WebCore::Gradient::endRadius):
1690         (WebCore::Gradient::setStartRadius): Setters are required for when we need to scale color stops.
1691         (WebCore::Gradient::setEndRadius):
1692         (WebCore::Gradient::aspectRatio):
1693         * platform/graphics/cg/GradientCG.cpp:
1694         (WebCore::Gradient::paint): For elliptical gradients, scale the CTM.
1695         * platform/graphics/wince/GraphicsContextWinCE.cpp:
1696         (WebCore::GraphicsContext::fillRect): Use start/endRadius() rather than r0() and r1().
1697
1698 2011-01-03  Simon Fraser  <simon.fraser@apple.com>
1699
1700         Reviewed by David Hyatt.
1701
1702         Implement -webkit-linear-gradient and -webkit-radial-gradient
1703         https://bugs.webkit.org/show_bug.cgi?id=28152
1704         
1705         Add support for the parsing and rendering of non-repeating CSS3 linear gradients,
1706         according to <http://dev.w3.org/csswg/css3-images/#linear-gradients>.
1707
1708         Tests: fast/gradients/css3-color-stop-units.html
1709                fast/gradients/css3-color-stops.html
1710                fast/gradients/css3-gradient-parsing.html
1711                fast/gradients/css3-linear-angle-gradients.html
1712
1713         * css/CSSGradientValue.h:
1714         Add subclasses of CSSGradientValue for linear and radial gradients.
1715         
1716         * css/CSSGradientValue.cpp:
1717         (WebCore::CSSGradientValue::image): Add FIXME comment about why we can't cache
1718         the gradient sometimes.
1719         (WebCore::compareStops): positions are CSSValues now.
1720         (WebCore::CSSGradientValue::sortStopsIfNeeded): Add assertion that this is only called
1721         for old-style gradients.
1722         (WebCore::CSSGradientValue::addStops): New method that handles the spec rules about
1723         missing positions, ensuring that stop position is ordered, and spacing out stops
1724         without positions. Also normalize gradients which use stops outside the 0-1 range
1725         so that platforms can render them correctly.
1726         (WebCore::positionFromValue): Determin the position on the gradient line for percentage,
1727         number and length values.
1728         (WebCore::CSSGradientValue::computeEndPoint):
1729         (WebCore::CSSLinearGradientValue::cssText):
1730         (WebCore::endPointsFromAngle): Compute endpoints for a gradient which covers the rectangle
1731         given an angle.
1732         (WebCore::CSSLinearGradientValue::createGradient):
1733         (WebCore::CSSRadialGradientValue::cssText):
1734         (WebCore::CSSRadialGradientValue::resolveRadius):
1735         (WebCore::CSSRadialGradientValue::createGradient):
1736
1737         * css/CSSParser.cpp:
1738         (WebCore::CSSParser::parseValue): Style fix.
1739         (WebCore::CSSParser::parseContent): Use isGeneratedImageValue() and parseGeneratedImage()
1740         (WebCore::CSSParser::parseFillImage): Use isGeneratedImageValue() and parseGeneratedImage()
1741         (WebCore::CSSParser::parseBorderImage): Use isGeneratedImageValue() and parseGeneratedImage()
1742         (WebCore::parseDeprecatedGradientPoint): Renamed to indicate that it's only used for -webkit-gradient.
1743         (WebCore::parseDeprecatedGradientColorStop): Renamed to indicate that it's only used for -webkit-gradient,
1744         and fixed to store CSSValues for the stop position.
1745         (WebCore::CSSParser::parseDeprecatedGradient): Renamed to indicate that it's only used for -webkit-gradient,
1746         and create CSSLinearGradientValue and CSSRadialGradientValue as appropriate.
1747         (WebCore::valueFromSideKeyword):
1748         (WebCore::parseGradientColorOrKeyword): Color parsing utility.
1749         (WebCore::CSSParser::parseLinearGradient): New method to parse linear gradients.
1750         (WebCore::CSSParser::parseRadialGradient): Stub for new method to parse radial gradients.
1751         (WebCore::CSSParser::isGeneratedImageValue): Detect gradients and CSS canvas.
1752         (WebCore::CSSParser::parseGeneratedImage): Parser for generated images like gradients
1753         and CSS canvas.
1754         * css/CSSParser.h:
1755         * platform/graphics/Gradient.h:
1756         (WebCore::Gradient::setP0): We need to be able to change the points when normalizing gradients.
1757         (WebCore::Gradient::setP1): Ditto.
1758
1759 2011-01-03  Noam Rosenthal  <noam.rosenthal@nokia.com>
1760
1761         Reviewed by Andreas Kling.
1762
1763         [Qt] document.getElementById(...) doesn't return the right object in combination with QGraphicsWidget
1764         https://bugs.webkit.org/show_bug.cgi?id=51464
1765
1766         Added a way to bind any QObject created as a plugin to JavaScript, 
1767         by adding a custom member (qtObject) to WebCore::Widget. 
1768         Added a test to tst_qwebpage to make sure plugins created 
1769         as QGraphicsWidget are accessible through JavaScript.
1770
1771         * bindings/js/ScriptControllerQt.cpp:
1772         (WebCore::ScriptController::createScriptInstanceForWidget):
1773         * platform/Widget.h:
1774         * platform/qt/WidgetQt.cpp:
1775         (WebCore::Widget::Widget):
1776         (WebCore::Widget::setBindingObject):
1777         (WebCore::Widget::bindingObject):
1778
1779 2011-01-03  David Hyatt  <hyatt@apple.com>
1780
1781         Reviewed by Simon Fraser.
1782
1783         https://bugs.webkit.org/show_bug.cgi?id=51328
1784
1785         Printing on a page with body { height: 100% } clips out the overflow contents.  This happened
1786         because the computePageRects function was never correct.  It was using the layer's width and height
1787         for the document's width and height, and the layer no longer includes overflow in its width and
1788         height.  It was also incorrectly assuming the first page would begin at (0,0), and this is an invalid
1789         assumption in RTL or vertical text environments.
1790
1791         Added printing/page-count-percentage-height.html
1792
1793         * page/PrintContext.cpp:
1794         (WebCore::PrintContext::computePageRects):
1795         (WebCore::PrintContext::computePageRectsWithPageSizeInternal):
1796
1797 2011-01-03  Csaba Osztrogonác  <ossy@webkit.org>
1798
1799         [Qt] Unreviewed buildfix for --minimal build after r74895.
1800
1801         * html/InputType.cpp: Missing include added.
1802         * html/NumberInputType.cpp: Missing include added.
1803
1804 2011-01-02  Darin Adler  <darin@apple.com>
1805
1806         Reviewed by Kent Tamura.
1807
1808         Eliminate HTMLInputElement::m_deprecatedTypeNumber, other input refactoring and renaming
1809         https://bugs.webkit.org/show_bug.cgi?id=51791
1810
1811         * dom/InputElement.h: Make sanitizeValueForTextField public so it can
1812         be called by InputType.
1813
1814         * html/BaseButtonInputType.cpp:
1815         (WebCore::BaseButtonInputType::accessKeyAction): Added.
1816         (WebCore::BaseButtonInputType::storesValueSeparateFromAttribute): Added.
1817         * html/BaseButtonInputType.h: Ditto.
1818
1819         * html/BaseCheckableInputType.cpp:
1820         (WebCore::BaseCheckableInputType::canSetStringValue): Added.
1821         (WebCore::BaseCheckableInputType::accessKeyAction): Added.
1822         (WebCore::BaseCheckableInputType::fallbackValue): Added.
1823         (WebCore::BaseCheckableInputType::storesValueSeparateFromAttribute): Added.
1824         (WebCore::BaseCheckableInputType::isCheckable): Added.
1825         * html/BaseCheckableInputType.h: Ditto.
1826
1827         * html/BaseDateAndTimeInputType.cpp:
1828         (WebCore::BaseDateAndTimeInputType::hasSpinButton): Added.
1829         * html/BaseDateAndTimeInputType.h: Ditto.
1830
1831         * html/BaseTextInputType.h: Made more functions private.
1832
1833         * html/ButtonInputType.cpp:
1834         (WebCore::ButtonInputType::isTextButton): Added.
1835         * html/ButtonInputType.h: Ditto.
1836
1837         * html/CheckboxInputType.cpp:
1838         (WebCore::CheckboxInputType::willDispatchClick): Added.
1839         (WebCore::CheckboxInputType::didDispatchClick): Added.
1840         (WebCore::CheckboxInputType::isCheckbox): Added.
1841         * html/CheckboxInputType.h: Ditto.
1842
1843         * html/DateTimeInputType.cpp:
1844         (WebCore::DateTimeInputType::scaledStepValueShouldBeInteger): Fixed
1845         typo in name of this function.
1846         * html/DateTimeInputType.h: Ditto.
1847         * html/DateTimeLocalInputType.cpp:
1848         (WebCore::DateTimeLocalInputType::scaledStepValueShouldBeInteger): Ditto.
1849         * html/DateTimeLocalInputType.h: Ditto.
1850
1851         * html/EmailInputType.cpp:
1852         (WebCore::EmailInputType::isEmailField): Added.
1853         * html/EmailInputType.h: Ditto.
1854
1855         * html/FileInputType.cpp:
1856         (WebCore::FileInputType::FileInputType): Added.
1857         (WebCore::FileInputType::canSetStringValue): Added.
1858         (WebCore::FileInputType::canChangeFromAnotherType): Added.
1859         (WebCore::FileInputType::files): Added.
1860         (WebCore::FileInputType::canSetValue): Added.
1861         (WebCore::FileInputType::getTypeSpecificValue): Added.
1862         (WebCore::FileInputType::storesValueSeparateFromAttribute): Added.
1863         (WebCore::FileInputType::setFileList): Added.
1864         (WebCore::FileInputType::isFileUpload): Added.
1865         * html/FileInputType.h: Ditto.
1866
1867         * html/HTMLInputElement.cpp:
1868         (WebCore::HTMLInputElement::HTMLInputElement): Updated for data member
1869         renaming and removal.
1870         (WebCore::HTMLInputElement::isValidValue): Call canSetStringValue
1871         instead of checking specific type numbers.
1872         (WebCore::HTMLInputElement::getAllowedValueStepWithDecimalPlaces):
1873         Use fastGetAttribute and fixed typo in the name of the
1874         scaledStepValueShouldBeInteger function.
1875         (WebCore::HTMLInputElement::isKeyboardFocusable): Call
1876         InputType::isKeyboardFocusable; moved most of the type-specific
1877         logic there.
1878         (WebCore::HTMLInputElement::shouldUseInputMethod): Call
1879         InputType::shouldUseInputMethod; moved the type-specific logic there.
1880         (WebCore::HTMLInputElement::handleBlurEvent): Call
1881         InputType::handleBlurEvent; moved the type-specific logic there.
1882         (WebCore::HTMLInputElement::setType): Tweak the names and types
1883         in this function.
1884         (WebCore::HTMLInputElement::updateType): Removed the code that
1885         set m_deprecatedTypeNumber. Compare types by comparing the value
1886         from formControlType. Removed file-specific logic and instead call
1887         InputType::canChangeFromAnotherType. Streamlined the logic for
1888         activation callbacks.
1889         (WebCore::HTMLInputElement::accessKeyAction): Call
1890         InputType::accessKeyAction; moved the type-specific logic there.
1891         (WebCore::HTMLInputElement::mapToEntry): Call
1892         InputType::shouldRespectHeightAndWidthAttributes and
1893         InputType::shouldRespectAlignAttribute.
1894         (WebCore::HTMLInputElement::parseMappedAttribute): Updated
1895         for name changes and the removal of m_defaultChecked. Changed the
1896         alt attribute logic to be based on the class of the renderer.
1897         Call InputType::srcAttributeChanged and moved the type-specific
1898         logic there. Call shouldRespectAlignAttribute and
1899         shouldRespectHeightAndWidthAttributes rather than having
1900         type-specific logic here. Call minOrMaxAttributeChanged.
1901         (WebCore::HTMLInputElement::rendererIsNeeded): Call
1902         InputType::rendererIsNeeded; moved the type-specific logic there.
1903         (WebCore::HTMLInputElement::attach): Removed the unneeded m_inited
1904         flag, which was redundant with the m_haveType flag. Call
1905         InputType::attach; moved the type-specific logic there.
1906         (WebCore::HTMLInputElement::altText): Use fastGetAttribute.
1907         (WebCore::HTMLInputElement::isSuccessfulSubmitButton): Call
1908         InputType::canBeSuccessfulSubmitButton; moved the type-specific
1909         logic there.
1910         (WebCore::HTMLInputElement::isActivatedSubmit): Updated for
1911         name changes.
1912         (WebCore::HTMLInputElement::setActivatedSubmit): Ditto.
1913         (WebCore::HTMLInputElement::reset): Updated to use
1914         InputType::storesValueSeparateFromAttribute. Also use
1915         hasAttribute(checkedAttr) rather than m_defaultChecked,
1916         since both are the same. Also updated for name change.
1917         (WebCore::HTMLInputElement::setChecked): Updated for name
1918         changes. Also added call to
1919         InputType::shouldSendChangeEventAfterCheckedChanged and
1920         moved the type-specific logic there.
1921         (WebCore::HTMLInputElement::setIndeterminate): Call
1922         isCheckable to see if indeterminate is allowed.
1923         Also updated for name changes.
1924         (WebCore::HTMLInputElement::copyNonAttributeProperties):
1925         Updated for name changes and removed data members.
1926         (WebCore::HTMLInputElement::value): Call
1927         InputType::getTypeSpecificValue and InputType::fallbackValue.
1928         Moved the type-specific logic there.
1929         (WebCore::HTMLInputElement::valueWithDefault): Call
1930         InputType::defaultValue. Moved the type-specific logic there.
1931         (WebCore::HTMLInputElement::setSuggestedValue): Call
1932         InputType::canSetSuggestedValue. Moved the type-specific logic
1933         there.
1934         (WebCore::HTMLInputElement::setValue): Call
1935         InputType::canSetValue. Moved the type-specific logic there.
1936         Clear the file list if it exists rather than checking the
1937         type explicitly. We could probably do that a more elegant way.
1938         (WebCore::HTMLInputElement::placeholder): Use fastGetAttribute.
1939         (WebCore::HTMLInputElement::setValueFromRenderer): Use the
1940         isFileUpload function in the assertion.
1941         (WebCore::HTMLInputElement::setFileListFromRenderer): Put most
1942         of the code from this function into FileInputType::setFileList.
1943         (WebCore::HTMLInputElement::preDispatchEventHandler): Changed
1944         to call InputType::willDispatchClick, which does the type-specific
1945         work. Still need to use a single struct for all types, because
1946         the type of the element could change during the event handling.
1947         (WebCore::HTMLInputElement::postDispatchEventHandler): Changed
1948         to call InputType::didDispatchClick.
1949         (WebCore::HTMLInputElement::defaultValue): Use fastGetAttribute.
1950         (WebCore::HTMLInputElement::accept): Use fastGetAttribute.
1951         (WebCore::HTMLInputElement::alt): Use fastGetAttribute.
1952         (WebCore::HTMLInputElement::src): Use fastGetAttribute.
1953         (WebCore::HTMLInputElement::setAutofilled): Updated for name
1954         changes.
1955         (WebCore::HTMLInputElement::files): Use InputType::files.
1956         (WebCore::HTMLInputElement::isAcceptableValue): Use
1957         InputType::isAcceptableValue.
1958         (WebCore::HTMLInputElement::sanitizeValue): Use
1959         InputType::sanitizeValue.
1960         (WebCore::HTMLInputElement::hasUnacceptableValue): Use
1961         InputType::hasUnacceptableValue.
1962         (WebCore::HTMLInputElement::needsActivationCallback): Use
1963         InputType::shouldResetOnDocumentActivation.
1964         (WebCore::HTMLInputElement::willMoveToNewOwnerDocument): Use
1965         InputType::willMoveToNewOwnerDocument.
1966         (WebCore::HTMLInputElement::dataList): Use
1967         InputType::shouldRespectListAttribute.
1968         (WebCore::HTMLInputElement::selectedOption): Tweaked logic
1969         and naming a bit.
1970         (WebCore::HTMLInputElement::stepUpFromRenderer): Use
1971         fastGetAttribute.
1972         (WebCore::HTMLInputElement::isSpeechEnabled): Use
1973         InputType::shouldRespectSpeechAttribute.
1974         (WebCore::HTMLInputElement::isTextButton): No longer inline.
1975         Calls through to InputType.
1976         (WebCore::HTMLInputElement::isRadioButton): Ditto.
1977         (WebCore::HTMLInputElement::isSearchField): Ditto.
1978         (WebCore::HTMLInputElement::isInputTypeHidden): Ditto.
1979         (WebCore::HTMLInputElement::isPasswordField): Ditto.
1980         (WebCore::HTMLInputElement::isCheckbox): Ditto.
1981         (WebCore::HTMLInputElement::isText): Ditto.
1982         (WebCore::HTMLInputElement::isEmailField): Ditto.
1983         (WebCore::HTMLInputElement::isFileUpload): Ditto.
1984         (WebCore::HTMLInputElement::isImageButton): Ditto.
1985         (WebCore::HTMLInputElement::isNumberField): Ditto.
1986         (WebCore::HTMLInputElement::isSubmitButton): Ditto.
1987         (WebCore::HTMLInputElement::isTelephoneField): Ditto.
1988         (WebCore::HTMLInputElement::isURLField): Ditto.
1989         (WebCore::HTMLInputElement::isEnumeratable): Ditto.
1990         (WebCore::HTMLInputElement::isChecked): No longer inline.
1991         Calls InputType::isCheckable.
1992         (WebCore::HTMLInputElement::hasSpinButton): No longer inline.
1993         Calls through to InputType.
1994         (WebCore::HTMLInputElement::supportsPlaceholder): No longer
1995         inline. Calls isTextType as before, but with no special case
1996         for ISINDEX. That special case was unneeded since it returns
1997         true from isTextType.
1998         (WebCore::HTMLInputElement::checkedRadioButtons): No longer
1999         inline.
2000         (WebCore::HTMLInputElement::handleBeforeTextInsertedEvent):
2001         No longer inline.
2002
2003         * html/HTMLInputElement.h: Removed multiple unneeded includes.
2004         The big one is probably InputType.h, but also HTMLFormElement.h.
2005         Removed unneeded forward declarations. Made many functions
2006         no longer inline since they now need to make virtual function
2007         dispatches. Removed the unneeded defaultChecked and
2008         webkitdirectory functions. Both are handled by HTML attribute
2009         reflection for DOM bindings, and the callers instead can get
2010         at the attribute. Made updateCheckedRadioButtons public so it
2011         can be called by an InputType class. Removed
2012         DeprecatedInputType, InputTypeMap, createTypeMap,
2013         deprecatedInputType, allowsIndeterminate,
2014         respectHeightAndWidthAttrs, storesValueSeparateFromAttribute,
2015         m_imageLoader, m_fileList, m_deprecatedTypeNumber,
2016         m_defaultChecked, and m_inited. Renamed m_checked to
2017         m_isChecked, m_useDefaultChecked to m_reflectsCheckedAttribute,
2018         m_indeterminate tom_isIndeterminate, m_haveType to m_hasType,
2019         m_activeSubmit to m_isActivatedSubmit, and m_autofilled to
2020         m_isAutofilled.
2021         
2022         * html/HiddenInputType.cpp:
2023         (WebCore::HiddenInputType::accessKeyAction): Added.
2024         (WebCore::HiddenInputType::rendererIsNeeded) Added.:
2025         (WebCore::HiddenInputType::storesValueSeparateFromAttribute): Added.
2026         (WebCore::HiddenInputType::isHiddenType): Added.
2027         (WebCore::HiddenInputType::shouldRespectHeightAndWidthAttributes): Added.
2028         * html/HiddenInputType.h: Ditto.
2029
2030         * html/ImageInputType.cpp:
2031         (WebCore::ImageInputType::ImageInputType): Moved out of the header file.
2032         (WebCore::ImageInputType::srcAttributeChanged): Added.
2033         (WebCore::ImageInputType::attach): Added.
2034         (WebCore::ImageInputType::willMoveToNewOwnerDocument): Added.
2035         (WebCore::ImageInputType::shouldRespectAlignAttribute): Added.
2036         (WebCore::ImageInputType::canBeSuccessfulSubmitButton): Added.
2037         (WebCore::ImageInputType::isImageButton): Added.
2038         (WebCore::ImageInputType::isEnumeratable): Added.
2039         (WebCore::ImageInputType::shouldRespectHeightAndWidthAttributes): Added.
2040         * html/ImageInputType.h: Ditto.
2041
2042         * html/InputType.cpp:
2043         (WebCore::InputType::create): Changed argument type to String. There
2044         is no value in taking an AtomicString here.
2045         (WebCore::InputType::scaledStepValueShouldBeInteger): Fixed typo in
2046         this function name.
2047         (WebCore::InputType::canSetStringValue): Added.
2048         (WebCore::InputType::isKeyboardFocusable): Added.
2049         (WebCore::InputType::shouldUseInputMethod): Added.
2050         (WebCore::InputType::handleBlurEvent): Added.
2051         (WebCore::InputType::accessKeyAction): Added.
2052         (WebCore::InputType::attach): Added.
2053         (WebCore::InputType::srcAttributeChanged): Added.
2054         (WebCore::InputType::willMoveToNewOwnerDocument): Added.
2055         (WebCore::InputType::shouldRespectAlignAttribute): Added.
2056         (WebCore::InputType::canChangeFromAnotherType): Added.
2057         (WebCore::InputType::minOrMaxAttributeChanged): Added.
2058         (WebCore::InputType::canBeSuccessfulSubmitButton): Added.
2059         (WebCore::InputType::rendererIsNeeded): Added.
2060         (WebCore::InputType::files): Added.
2061         (WebCore::InputType::getTypeSpecificValue): Added.
2062         (WebCore::InputType::fallbackValue): Added.
2063         (WebCore::InputType::defaultValue): Added.
2064         (WebCore::InputType::canSetSuggestedValue): Added.
2065         (WebCore::InputType::shouldSendChangeEventAfterCheckedChanged): Added.
2066         (WebCore::InputType::storesValueSeparateFromAttribute): Added.
2067         (WebCore::InputType::canSetValue): Added.
2068         (WebCore::InputType::willDispatchClick): Added.
2069         (WebCore::InputType::didDispatchClick): Added.
2070         (WebCore::InputType::isAcceptableValue): Added.
2071         (WebCore::InputType::sanitizeValue): Added.
2072         (WebCore::InputType::hasUnacceptableValue): Added.
2073         (WebCore::InputType::setFileList): Added.
2074         (WebCore::InputType::shouldResetOnDocumentActivation): Added.
2075         (WebCore::InputType::shouldRespectListAttribute): Added.
2076         (WebCore::InputType::shouldRespectSpeechAttribute): Added.
2077         (WebCore::InputType::isTextButton): Added.
2078         (WebCore::InputType::isRadioButton): Added.
2079         (WebCore::InputType::isSearchField): Added.
2080         (WebCore::InputType::isHiddenType): Added.
2081         (WebCore::InputType::isPasswordField): Added.
2082         (WebCore::InputType::isCheckbox): Added.
2083         (WebCore::InputType::isEmailField): Added.
2084         (WebCore::InputType::isFileUpload): Added.
2085         (WebCore::InputType::isImageButton): Added.
2086         (WebCore::InputType::isNumberField): Added.
2087         (WebCore::InputType::isSubmitButton): Added.
2088         (WebCore::InputType::isTelephoneField): Added.
2089         (WebCore::InputType::isURLField): Added.
2090         (WebCore::InputType::isEnumeratable): Added.
2091         (WebCore::InputType::isCheckable): Added.
2092         (WebCore::InputType::hasSpinButton): Added.
2093         (WebCore::InputType::shouldRespectHeightAndWidthAttributes): Added.
2094
2095         * html/InputType.h: Removed unneeded ExceptionCode.h include and
2096         used a typedef instead as we do when we want for forward declare it.
2097         Added includes and forward declarations needed for new functions.
2098         Added ClickHandlingState structure. Changed the argument to create
2099         to a String rather than AtomicString. Added many virtual functions.
2100         
2101         * html/IsIndexInputType.cpp:
2102         (WebCore::IsIndexInputType::shouldRespectListAttribute): Added.
2103         * html/IsIndexInputType.h: Ditto.
2104
2105         * html/NumberInputType.cpp:
2106         (WebCore::NumberInputType::handleBlurEvent): Added.
2107         (WebCore::NumberInputType::isAcceptableValue): Added.
2108         (WebCore::NumberInputType::sanitizeValue): Added.
2109         (WebCore::NumberInputType::hasUnacceptableValue): Added.
2110         (WebCore::NumberInputType::shouldRespectSpeechAttribute): Added.
2111         (WebCore::NumberInputType::isNumberField): Added.
2112         (WebCore::NumberInputType::hasSpinButton): Added.
2113         * html/NumberInputType.h: Ditto.
2114
2115         * html/PasswordInputType.cpp:
2116         (WebCore::PasswordInputType::shouldUseInputMethod): Added.
2117         (WebCore::PasswordInputType::shouldResetOnDocumentActivation): Added.
2118         (WebCore::PasswordInputType::shouldRespectListAttribute): Added.
2119         (WebCore::PasswordInputType::shouldRespectSpeechAttribute): Added.
2120         (WebCore::PasswordInputType::isPasswordField): Added.
2121         * html/PasswordInputType.h: Ditto.
2122
2123         * html/RadioInputType.cpp:
2124         (WebCore::RadioInputType::isKeyboardFocusable): Added.
2125         (WebCore::RadioInputType::attach): Added.
2126         (WebCore::RadioInputType::shouldSendChangeEventAfterCheckedChanged): Added.
2127         (WebCore::RadioInputType::willDispatchClick): Added.
2128         (WebCore::RadioInputType::didDispatchClick): Added.
2129         (WebCore::RadioInputType::isRadioButton): Added.
2130         * html/RadioInputType.h: Ditto.
2131
2132         * html/RangeInputType.cpp:
2133         (WebCore::RangeInputType::accessKeyAction): Added.
2134         (WebCore::RangeInputType::minOrMaxAttributeChanged): Added.
2135         (WebCore::RangeInputType::fallbackValue): Added.
2136         (WebCore::RangeInputType::sanitizeValue): Added.
2137         (WebCore::RangeInputType::shouldRespectListAttribute): Added.
2138         * html/RangeInputType.h: Ditto.
2139
2140         * html/ResetInputType.cpp:
2141         (WebCore::ResetInputType::defaultValue): Added.
2142         (WebCore::ResetInputType::isTextButton): Added.
2143         * html/ResetInputType.h: Ditto.
2144
2145         * html/SearchInputType.cpp:
2146         (WebCore::SearchInputType::shouldRespectSpeechAttribute): Added.
2147         (WebCore::SearchInputType::isSearchField): Added.
2148         * html/SearchInputType.h: Ditto.
2149
2150         * html/SubmitInputType.cpp:
2151         (WebCore::SubmitInputType::canBeSuccessfulSubmitButton): Added.
2152         (WebCore::SubmitInputType::defaultValue): Added.
2153         (WebCore::SubmitInputType::isSubmitButton): Added.
2154         (WebCore::SubmitInputType::isTextButton): Added.
2155         * html/SubmitInputType.h: Ditto.
2156
2157         * html/TelephoneInputType.cpp:
2158         (WebCore::TelephoneInputType::shouldRespectSpeechAttribute): Added.
2159         (WebCore::TelephoneInputType::isTelephoneField): Added.
2160         * html/TelephoneInputType.h: Ditto.
2161
2162         * html/TextFieldInputType.cpp:
2163         (WebCore::TextFieldInputType::shouldUseInputMethod): Added.
2164         (WebCore::TextFieldInputType::sanitizeValue): Added.
2165         (WebCore::TextFieldInputType::shouldRespectListAttribute): Added.
2166         * html/TextFieldInputType.h: Ditto.
2167
2168         * html/TextInputType.cpp:
2169         (WebCore::TextInputType::canSetSuggestedValue): Added.
2170         (WebCore::TextInputType::shouldRespectSpeechAttribute): Added.
2171         * html/TextInputType.h: Ditto.
2172
2173         * html/TimeInputType.cpp:
2174         (WebCore::TimeInputType::scaledStepValueShouldBeInteger): Fixed
2175         typo in the name of this function.
2176         * html/TimeInputType.h: Ditto.
2177
2178         * html/URLInputType.cpp:
2179         (WebCore::URLInputType::isURLField): Added.
2180         * html/URLInputType.h: Ditto.
2181
2182 2011-01-03  Mihai Parparita  <mihaip@chromium.org>
2183
2184         Unreviewed.
2185
2186         NSScrollView-based scrollbars and ScrollBarTheme-based scrollbars don't look the same
2187         https://bugs.webkit.org/show_bug.cgi?id=51151
2188
2189         Flip switch to use WebThemeEngine for Chromium/Mac scrollbar rendering,
2190         so that it can match Safari's (and thus use the same baselines).
2191
2192         No new tests, should be covered by layout tests (which will need
2193         expectation changes)
2194
2195         * platform/chromium/ScrollbarThemeChromiumMac.mm:
2196
2197 2011-01-03  Antonio Gomes  <agomes@rim.com>
2198
2199         Unreviewed build fix for WebKit/Gtk+.
2200
2201         RenderThemeGtk::initMediaColors() in RenderThemeGtk2.cpp needs to be
2202         guarded by ENABLE(VIDEO), as it is in its header.
2203
2204         No new tests.
2205
2206         * platform/gtk/RenderThemeGtk2.cpp:
2207
2208 2011-01-02  Dan Bernstein  <mitz@apple.com>
2209
2210         Rubber-stamped by Simon Fraser.
2211
2212         <rdar://problem/8812159> Update copyright strings
2213
2214         * Info.plist:
2215
2216 2011-01-02  Dan Bernstein  <mitz@apple.com>
2217
2218         Reviewed by Sam Weinig.
2219
2220         <rdar://problem/8806570> REGRESSION (r73337): Incorrect text match count when a match occurs in a text field
2221         https://bugs.webkit.org/show_bug.cgi?id=51623
2222
2223         * editing/Editor.cpp:
2224         (WebCore::Editor::countMatchesForText): Actually remember the original search range end
2225         container and offset and restore them when needed, instead of using two references to the
2226         same Range.
2227         * manual-tests/find-count-matches-after-text-control.html: Added.
2228
2229 2011-01-02  Benjamin Poulain  <benjamin.poulain@nokia.com>
2230
2231         Reviewed by Csaba Osztrogonác.
2232
2233         WebKit 2 does not build on 64bits with a recent GCC
2234         https://bugs.webkit.org/show_bug.cgi?id=51754
2235
2236         Use explicitely 64 bits types for the attributes of DatabaseDetails.
2237
2238         * storage/DatabaseDetails.h:
2239         (WebCore::DatabaseDetails::expectedUsage):
2240         (WebCore::DatabaseDetails::currentUsage):
2241
2242 2011-01-02  Patrick Gansterer  <paroga@webkit.org>
2243
2244         Unreviewed WinCE build fix for r74868.
2245
2246         * platform/graphics/wince/ImageBufferWinCE.cpp:
2247         (WebCore::getImageData):
2248
2249 2011-01-02  Sheriff Bot  <webkit.review.bot@gmail.com>
2250
2251         Unreviewed, rolling out r74847.
2252         http://trac.webkit.org/changeset/74847
2253         https://bugs.webkit.org/show_bug.cgi?id=51803
2254
2255         "Preprocessor guards should be in header files" (Requested by
2256         ap on #webkit).
2257
2258         * bindings/js/JSDOMWindowBase.cpp:
2259         * dom/Document.cpp:
2260         (WebCore::Document::recalcStyle):
2261         * html/HTMLDocument.cpp:
2262         * loader/FrameLoader.cpp:
2263         * loader/ResourceLoadNotifier.cpp:
2264         * page/Chrome.cpp:
2265         * page/Console.cpp:
2266         * page/ContextMenuController.cpp:
2267         * page/DOMWindow.cpp:
2268         (WebCore::DOMWindow::dispatchEvent):
2269         * page/EventHandler.cpp:
2270         * page/Page.cpp:
2271         * storage/Database.cpp:
2272         * workers/AbstractWorker.cpp:
2273         * workers/DefaultSharedWorkerRepository.cpp:
2274         * workers/SharedWorker.cpp:
2275         * workers/Worker.cpp:
2276         * workers/WorkerContext.cpp:
2277         * workers/WorkerMessagingProxy.cpp:
2278         * xml/XMLHttpRequest.cpp:
2279         (WebCore::XMLHttpRequest::callReadyStateChangeListener):
2280
2281 2011-01-02  Patrick Gansterer  <paroga@webkit.org>
2282
2283         [CMake] Unreviewed build fix.
2284
2285         * CMakeLists.txt:
2286
2287 2011-01-02  Dirk Schulze  <krit@webkit.org>
2288
2289         Reviewed by Simon Fraser.
2290
2291         Clarify ImageBuffer and ImageData relationship
2292         https://bugs.webkit.org/show_bug.cgi?id=51297
2293
2294         Remove references to ImageData and CanvasPixelArray from ImageBuffer and SVG filter/masker code,
2295         since this was a layering violation, and replaced it by ByteArray.
2296
2297         No change of functionality, so no new test added.
2298
2299         * html/ImageData.cpp:
2300         (WebCore::ImageData::create):
2301         (WebCore::ImageData::ImageData):
2302         * html/ImageData.h: Added new constructor with ByteArray input.
2303         (WebCore::ImageData::width):
2304         (WebCore::ImageData::height):
2305         (WebCore::ImageData::data):
2306         * html/canvas/CanvasPixelArray.cpp:
2307         (WebCore::CanvasPixelArray::create):
2308         (WebCore::CanvasPixelArray::CanvasPixelArray):
2309         * html/canvas/CanvasPixelArray.h: New conctructor with ByteArray input, used by HTML Canvas.
2310         (WebCore::CanvasPixelArray::data):
2311         (WebCore::CanvasPixelArray::length):
2312         (WebCore::CanvasPixelArray::set):
2313         (WebCore::CanvasPixelArray::get):
2314         * html/canvas/CanvasRenderingContext2D.cpp:
2315         (WebCore::CanvasRenderingContext2D::getImageData):
2316         (WebCore::CanvasRenderingContext2D::putImageData):
2317         * platform/graphics/ImageBuffer.h:
2318         * platform/graphics/cairo/ImageBufferCairo.cpp:
2319         (WebCore::getImageData):
2320         (WebCore::ImageBuffer::getUnmultipliedImageData):
2321         (WebCore::ImageBuffer::getPremultipliedImageData):
2322         (WebCore::putImageData):
2323         (WebCore::ImageBuffer::putUnmultipliedImageData):
2324         (WebCore::ImageBuffer::putPremultipliedImageData):
2325         * platform/graphics/cg/ImageBufferCG.cpp:
2326         (WebCore::getImageData):
2327         (WebCore::ImageBuffer::getUnmultipliedImageData):
2328         (WebCore::ImageBuffer::getPremultipliedImageData):
2329         (WebCore::putImageData):
2330         (WebCore::ImageBuffer::putUnmultipliedImageData):
2331         (WebCore::ImageBuffer::putPremultipliedImageData):
2332         * platform/graphics/filters/FEBlend.cpp:
2333         (WebCore::FEBlend::apply):
2334         * platform/graphics/filters/FEColorMatrix.cpp:
2335         (WebCore::FEColorMatrix::apply):
2336         * platform/graphics/filters/FEComponentTransfer.cpp:
2337         (WebCore::FEComponentTransfer::apply):
2338         * platform/graphics/filters/FEComposite.cpp:
2339         (WebCore::FEComposite::apply):
2340         * platform/graphics/filters/FEConvolveMatrix.cpp:
2341         (WebCore::setDestinationPixels):
2342         (WebCore::FEConvolveMatrix::apply):
2343         * platform/graphics/filters/FEConvolveMatrix.h:
2344         * platform/graphics/filters/FEDisplacementMap.cpp:
2345         (WebCore::FEDisplacementMap::apply):
2346         * platform/graphics/filters/FEGaussianBlur.cpp:
2347         (WebCore::FEGaussianBlur::apply):
2348         * platform/graphics/filters/FELighting.cpp:
2349         (WebCore::FELighting::apply):
2350         * platform/graphics/filters/FEMorphology.cpp:
2351         (WebCore::FEMorphology::apply):
2352         * platform/graphics/filters/FETurbulence.cpp:
2353         (WebCore::FETurbulence::apply):
2354         * platform/graphics/filters/FilterEffect.cpp:
2355         (WebCore::FilterEffect::asImageBuffer):
2356         (WebCore::FilterEffect::asUnmultipliedImage):
2357         (WebCore::FilterEffect::asPremultipliedImage):
2358         (WebCore::FilterEffect::copyImageBytes):
2359         (WebCore::FilterEffect::copyUnmultipliedImage):
2360         (WebCore::FilterEffect::copyPremultipliedImage):
2361         (WebCore::FilterEffect::createUnmultipliedImageResult):
2362         (WebCore::FilterEffect::createPremultipliedImageResult):
2363         * platform/graphics/filters/FilterEffect.h:
2364         * platform/graphics/qt/ImageBufferQt.cpp:
2365         (WebCore::getImageData):
2366         (WebCore::ImageBuffer::getUnmultipliedImageData):
2367         (WebCore::ImageBuffer::getPremultipliedImageData):
2368         (WebCore::putImageData):
2369         (WebCore::ImageBuffer::putUnmultipliedImageData):
2370         (WebCore::ImageBuffer::putPremultipliedImageData):
2371         * platform/graphics/skia/ImageBufferSkia.cpp:
2372         (WebCore::getImageData):
2373         (WebCore::ImageBuffer::getUnmultipliedImageData):
2374         (WebCore::ImageBuffer::getPremultipliedImageData):
2375         (WebCore::putImageData):
2376         (WebCore::ImageBuffer::putUnmultipliedImageData):
2377         (WebCore::ImageBuffer::putPremultipliedImageData):
2378         * platform/graphics/wince/ImageBufferWinCE.cpp:
2379         (WebCore::getImageData):
2380         (WebCore::ImageBuffer::getUnmultipliedImageData):
2381         (WebCore::ImageBuffer::getPremultipliedImageData):
2382         (WebCore::putImageData):
2383         (WebCore::ImageBuffer::putUnmultipliedImageData):
2384         (WebCore::ImageBuffer::putPremultipliedImageData):
2385         * platform/graphics/wx/ImageBufferWx.cpp:
2386         (WebCore::ImageBuffer::getUnmultipliedImageData):
2387         (WebCore::ImageBuffer::getPremultipliedImageData):
2388         (WebCore::ImageBuffer::putUnmultipliedImageData):
2389         (WebCore::ImageBuffer::putPremultipliedImageData):
2390         * rendering/RenderSVGResourceMasker.cpp:
2391         (WebCore::RenderSVGResourceMasker::drawContentIntoMaskImage):
2392
2393 2011-01-01  Adam Barth  <abarth@webkit.org>
2394
2395         Reviewed by Eric Seidel.
2396
2397         Move JavaScriptCore to Source
2398         https://bugs.webkit.org/show_bug.cgi?id=51604
2399
2400         Update references to JavaScriptCore.
2401
2402         * Android.derived.jscbindings.mk:
2403         * Android.v8bindings.mk:
2404         * CMakeLists.txt:
2405         * WebCore.gyp/WebCore.gyp:
2406         * WebCore.pro:
2407           - These changes are subtle and might not be 100% correct.
2408         * move-js-headers.sh:
2409
2410 2011-01-01  Adam Barth  <abarth@webkit.org>
2411
2412         Reviewed by Eric Seidel.
2413
2414         forbid sandboxed frames to call top.close() when allow-same-origin is not setted
2415         https://bugs.webkit.org/show_bug.cgi?id=38340
2416
2417         We now pass the ScriptExecutionContext to window.close so it can find
2418         the Frame and check whether navigation is allowed.  This check will
2419         almost always pass because you can only close top-level frames, but the
2420         check will fail when the calling script is sandboxed.
2421
2422         Tests: fast/frames/sandboxed-iframe-close-top-noclose.html
2423                fast/frames/sandboxed-iframe-close-top.html
2424
2425         * page/DOMWindow.cpp:
2426         (WebCore::DOMWindow::close):
2427         * page/DOMWindow.h:
2428         * page/DOMWindow.idl:
2429
2430 2011-01-01  Adam Barth  <abarth@webkit.org>
2431
2432         Reviewed by Eric Seidel.
2433
2434         sandbox iframes have access to top.history methods
2435         https://bugs.webkit.org/show_bug.cgi?id=38152
2436
2437         To enforce the sandbox restrictions on History, we need to pass the
2438         ScriptExecutionContext to WebCore.  This patch leaves the original
2439         History methods in place because they are used directly by folks who
2440         don't care about security checks.
2441
2442         Test: fast/frames/sandboxed-iframe-history-denied.html
2443
2444         * page/History.cpp:
2445         (WebCore::History::back):
2446         (WebCore::History::forward):
2447         (WebCore::History::go):
2448         * page/History.h:
2449         * page/History.idl:
2450
2451 2011-01-01  Adam Barth  <abarth@webkit.org>
2452
2453         Remove empty file.
2454
2455         * Android.mk:
2456         * CMakeLists.txt:
2457         * GNUmakefile.am:
2458         * WebCore.gypi:
2459         * WebCore.pro:
2460         * WebCore.vcproj/WebCore.vcproj:
2461         * WebCore.xcodeproj/project.pbxproj:
2462         * dom/DOMAllInOne.cpp:
2463         * dom/Entity.cpp: Removed.
2464
2465 2011-01-01  Adam Barth  <abarth@webkit.org>
2466
2467         Remove empty file.
2468
2469         * CMakeLists.txt:
2470         * GNUmakefile.am:
2471         * WebCore.pro:
2472         * WebCore.vcproj/WebCore.vcproj:
2473         * WebCore.xcodeproj/project.pbxproj:
2474         * bindings/js/JSBindingsAllInOne.cpp:
2475         * bindings/js/JSPopStateEventCustom.cpp: Removed.
2476
2477 2011-01-01  Adam Barth  <abarth@webkit.org>
2478
2479         Remove empty files.
2480
2481         * GNUmakefile.am:
2482         * WebCore.gypi:
2483         * WebCore.vcproj/WebCore.vcproj:
2484         * WebCore.xcodeproj/project.pbxproj:
2485         * bindings/generic/BindingFrame.h: Removed.
2486         * bindings/generic/BindingLocation.h: Removed.
2487
2488 2011-01-01  Konstantin Tokarev  <annulen@yandex.ru>
2489
2490         Reviewed by Darin Adler.
2491
2492         Don't include Inspector headers when Inspector is disabled
2493         https://bugs.webkit.org/show_bug.cgi?id=51789
2494
2495         * bindings/js/JSDOMWindowBase.cpp: Include Inspector headers when
2496         Inspector is enabled
2497         * dom/Document.cpp: Include Inspector headers when
2498         Inspector is enabled
2499         (WebCore::Document::recalcStyle): Disabled InspectorInstrumentationCookie
2500         handling
2501         * html/HTMLDocument.cpp: Include Inspector headers when
2502         Inspector is enabled
2503         * loader/FrameLoader.cpp: Include Inspector headers when
2504         Inspector is enabled
2505         * loader/ResourceLoadNotifier.cpp: Include Inspector headers when
2506         Inspector is enabled
2507         * page/Chrome.cpp: Include Inspector headers when
2508         Inspector is enabled
2509         * page/Console.cpp: Include Inspector headers when
2510         Inspector is enabled
2511         * page/ContextMenuController.cpp: Include Inspector headers when
2512         Inspector is enabled
2513         * page/DOMWindow.cpp: Include Inspector headers when
2514         Inspector is enabled
2515         (WebCore::DOMWindow::dispatchEvent): Disabled InspectorInstrumentationCookie
2516         handling
2517         * page/EventHandler.cpp: Include Inspector headers when
2518         Inspector is enabled
2519         * page/Page.cpp: Include Inspector headers when
2520         Inspector is enabled
2521         * storage/Database.cpp: Include Inspector headers when
2522         Inspector is enabled
2523         * workers/AbstractWorker.cpp: Include Inspector headers when
2524         Inspector is enabled
2525         * workers/DefaultSharedWorkerRepository.cpp: Include Inspector headers when
2526         Inspector is enabled
2527         * workers/SharedWorker.cpp: Include Inspector headers when
2528         Inspector is enabled
2529         * workers/Worker.cpp: Include Inspector headers when
2530         Inspector is enabled
2531         * workers/WorkerContext.cpp: Include Inspector headers when
2532         Inspector is enabled
2533         * workers/WorkerMessagingProxy.cpp: Include Inspector headers when
2534         Inspector is enabled
2535         * xml/XMLHttpRequest.cpp: Include Inspector headers when
2536         Inspector is enabled
2537         (WebCore::XMLHttpRequest::callReadyStateChangeListener): Disabled
2538         InspectorInstrumentationCookie handling
2539
2540 2010-12-31  Adam Barth  <abarth@webkit.org>
2541
2542         Reviewed by Darin Adler.
2543
2544         fast/loader/about-blank-hash-change.html fails on Chromium
2545         https://bugs.webkit.org/show_bug.cgi?id=51788
2546
2547         I'm unable to reproduce the failure locally, so this patch is slightly
2548         speculative.  We need to be slighly more careful how we compare the
2549         fragment identifiers for Chromium because Chromium uses a URL parser
2550         that is more agressive about canonicalization.
2551
2552         * page/Location.cpp:
2553         (WebCore::Location::setHash):
2554
2555 2010-12-31  Martin Robinson  <mrobinson@igalia.com>
2556
2557         Reviewed by Xan Lopez.
2558
2559         [GTK] Use GLib/GIO API for FileSystemGtk implementation
2560         https://bugs.webkit.org/show_bug.cgi?id=51617
2561
2562         Complete implementation of FileSystem platform code for GLib. This
2563         converts remaining API points using POSIX calls to platform-independent
2564         GLib calls and fixes other compilation errors.
2565
2566         No new tests. This code will be tested when an implementation
2567         of beginDragWithFiles is complete.
2568
2569         (WebCore::JSDirectoryEntry::getFile):
2570         (WebCore::JSDirectoryEntry::getDirectory):
2571         * platform/FileSystem.h: Added forward declarations for GLib types to
2572         avoid GLib includes and changed the PlatformFileHandle to be a GIOStream.
2573         * platform/gtk/FileSystemGtk.cpp:
2574         (WebCore::openTemporaryFile): Reimplement using only GLib calls.
2575         (WebCore::openFile): Ditto.
2576         (WebCore::closeFile): Ditto.
2577         (WebCore::seekFile): Added implementation.
2578         (WebCore::writeToFile): Reimplement using only GLib calls.
2579         (WebCore::readFromFile): Ditto.
2580
2581 2010-12-31  Darin Adler  <darin@apple.com>
2582
2583         Reviewed by Dan Bernstein.
2584
2585         Some renaming and refactoring of form element code
2586         https://bugs.webkit.org/show_bug.cgi?id=51784
2587
2588         * bindings/js/JSHTMLSelectElementCustom.cpp:
2589         (WebCore::JSHTMLSelectElement::remove): Call new overload of remove
2590         for option elements instead of putting the logic in the binding.
2591
2592         * html/HTMLButtonElement.cpp:
2593         (WebCore::HTMLButtonElement::HTMLButtonElement): Updated for name changes.
2594         (WebCore::HTMLButtonElement::defaultEventHandler): Renamed argument to
2595         "event" instead of "evt". Also updated for name changes.
2596         (WebCore::HTMLButtonElement::isActivatedSubmit): Ditto.
2597         (WebCore::HTMLButtonElement::setActivatedSubmit): Ditto.
2598         (WebCore::HTMLButtonElement::appendFormData): Ditto.
2599         * html/HTMLButtonElement.h: Renamed m_activeSubmit to m_isActivatedSubmit
2600         to match the getter function name. The name still doesn't seem great.
2601
2602         * html/HTMLFormElement.cpp:
2603         (WebCore::HTMLFormElement::HTMLFormElement): Updated for name changes.
2604         (WebCore::HTMLFormElement::~HTMLFormElement): Use autoComplete function
2605         instead of m_autocomplete data member.
2606         (WebCore::HTMLFormElement::rendererIsNeeded): Use m_wasDemoted data member
2607         instead of otherwise-unused isDemoted function.
2608         (WebCore::HTMLFormElement::submitImplicitly): Updated for name changes.
2609         (WebCore::HTMLFormElement::validateInteractively): Removed code to clear
2610         m_insubmit. This is now handled by the caller, prepareForSubmission.
2611         (WebCore::HTMLFormElement::prepareForSubmission): Renamed. Updated for
2612         name changes. Moved code to clear m_isSubmittingOrPreparingForSubmission
2613         here from validateInteractively. Removed unneeded check of m_doingsubmit
2614         boolean before setting it.
2615         (WebCore::HTMLFormElement::submit): Factored this function into two.
2616         One for JavaScript and one for non-JavaScript. Neither function needs a frame
2617         argument, because the question being asked, anyPageIsProcessingUserGesture,
2618         is a question asked of an entire page group, not a specific frame or page,
2619         so it's not important which is the active frame.
2620         (WebCore::HTMLFormElement::submitFromJavaScript): Ditto.
2621         (WebCore::HTMLFormElement::reset): Updated for name changes.
2622         (WebCore::HTMLFormElement::parseMappedAttribute): Removed code to parse
2623         acceptAttr and got rid of code to set m_autocomplete.
2624         (WebCore::HTMLFormElement::elementForAlias): Changed return type to a raw
2625         pointer.
2626         (WebCore::HTMLFormElement::getNamedElements): Updated to use raw pointer
2627         and the vector find function. Added a FIXME about the comment.
2628         (WebCore::HTMLFormElement::documentDidBecomeActive): Use autoComplete
2629         function instead of m_autocomplete data member.
2630         (WebCore::HTMLFormElement::willMoveToNewOwnerDocument): Ditto.
2631         (WebCore::HTMLFormElement::didMoveToNewOwnerDocument): Ditto.
2632         (WebCore::HTMLFormElement::autoComplete): Ditto.
2633         * html/HTMLFormElement.h: Added a FIXME about renaming the autoComplete
2634         function. Renamed prepareSubmit to prepareForSubmission. Got rid of the
2635         frame argument from the submit function and added a new submitFromJavaScript
2636         variant. Removed the unneeded isDemoted function. Changed the return type
2637         of elementForAlias to a raw pointer. Removed m_autocomplete. Renamed
2638         m_insubmit to m_isSubmittingOrPreparingForSubmission, m_doingsubmit to
2639         m_shouldSubmit, m_inreset to m_inResetFunction, m_malformed to m_wasMalformed,
2640         m_demoted to m_wasDemoted. Use plain bool instead of bitfields.
2641
2642         * html/HTMLFormElement.idl: Use the function named submitFromJavaScript
2643         instead of using CallWith=DynamicFrame because we don't need to know
2644         what frame is calling. If we did, it's not clear that the "dynamic"
2645         frame would be the right one anyway.
2646
2647         * html/HTMLSelectElement.cpp:
2648         (WebCore::HTMLSelectElement::remove): Added an overload that takes an option
2649         element, since the JavaScript binding supports this.
2650         * html/HTMLSelectElement.h: Ditto.
2651
2652         * html/ImageInputType.cpp:
2653         (WebCore::ImageInputType::handleDOMActivateEvent): Updated for name changes.
2654         * html/ImageInputType.h: Ditto.
2655         * html/SubmitInputType.cpp:
2656         (WebCore::SubmitInputType::handleDOMActivateEvent): Ditto.
2657
2658 2010-12-31  Daniel Bates  <dbates@rim.com>
2659
2660         Reviewed by Darin Adler.
2661
2662         Pass style for <area> instead of associated <img> when querying whether
2663         the theme draws the focus ring for an <area>
2664         https://bugs.webkit.org/show_bug.cgi?id=51632
2665
2666         Fixes an issue where the style for the associated <img> of an <area>
2667         was passed when considering whether the theme should draw a focus ring
2668         for the <area>. Instead, we should pass the theme the style for the <area>.
2669
2670         It's not possible to test this at this time since there are no themes
2671         that override focus ring drawing for <area>s.
2672
2673         * rendering/RenderImage.cpp:
2674         (WebCore::RenderImage::paintFocusRing): Moved call to RenderTheme::supportsFocusRing()
2675         such that it's called with respect to the focused <area>.
2676
2677 2010-12-31  Darin Adler  <darin@apple.com>
2678
2679         * WebCore.xcodeproj/project.pbxproj: Added back the language.
2680         Developers should be using Xcode 3.2.5 or newer.
2681
2682 2010-12-31  Adam Barth  <abarth@webkit.org>
2683
2684         Reviewed by Eric Seidel.
2685
2686         Move V8 to WebCore Location implementation
2687         https://bugs.webkit.org/show_bug.cgi?id=51768
2688
2689         * bindings/generic/BindingFrame.h:
2690         * bindings/generic/BindingLocation.h:
2691         * bindings/v8/V8Binding.h:
2692         * bindings/v8/V8DOMWindowShell.cpp:
2693         (WebCore::V8DOMWindowShell::setLocation):
2694         * bindings/v8/V8Utilities.cpp:
2695         * bindings/v8/V8Utilities.h:
2696         * bindings/v8/custom/V8LocationCustom.cpp:
2697         (WebCore::V8Location::hashAccessorSetter):
2698         (WebCore::V8Location::hostAccessorSetter):
2699         (WebCore::V8Location::hostnameAccessorSetter):
2700         (WebCore::V8Location::hrefAccessorSetter):
2701         (WebCore::V8Location::pathnameAccessorSetter):
2702         (WebCore::V8Location::portAccessorSetter):
2703         (WebCore::V8Location::protocolAccessorSetter):
2704         (WebCore::V8Location::searchAccessorSetter):
2705         (WebCore::V8Location::reloadCallback):
2706         (WebCore::V8Location::replaceCallback):
2707         (WebCore::V8Location::assignCallback):
2708
2709 2010-12-31  Yi Shen  <yi.4.shen@nokia.com>
2710
2711         Reviewed by Eric Seidel.
2712
2713         Make retrieving extraMediaControlsStyleSheet be page dependent.
2714         https://bugs.webkit.org/show_bug.cgi?id=51752
2715
2716         Use themeForPage to retrieve extraMediaControlsStyleSheet for media
2717         controls.
2718
2719         No new tests because no platform-specific theme implementation uses
2720         the passed page pointer yet.
2721
2722         * css/CSSStyleSelector.cpp:
2723         (WebCore::CSSStyleSelector::styleForElement):
2724
2725 2010-12-31  Ilya Tikhonovsky  <loislo@chromium.org>
2726
2727         Reviewed by Pavel Feldman.
2728
2729         Web Inspector: [REGRESSION] WebInspector.ResourcesPanel.prototype.canShowSourceLine() broken.
2730
2731         https://bugs.webkit.org/show_bug.cgi?id=51709
2732
2733         * inspector/front-end/ResourcesPanel.js:
2734         (WebInspector.ResourcesPanel.prototype.canShowSourceLine):
2735
2736 2010-12-31  Patrick Gansterer  <paroga@webkit.org>
2737
2738         Unreviewed build fix after r74800.
2739
2740         * bindings/js/JSDOMWindowCustom.cpp: Add missing header.
2741         * bindings/js/JSLocationCustom.cpp: Ditto.
2742
2743 2010-12-31  Adam Barth  <abarth@webkit.org>
2744
2745         Rubber-stamped by Eric Seidel.
2746
2747         Move HTML and XML parser benchmarks into PerformanceTests/Parser
2748         https://bugs.webkit.org/show_bug.cgi?id=51772
2749
2750         Remove the benchmarks folder now that it's empty.  Future benchmarks
2751         should go in the PerformanceTests directory.
2752
2753         * benchmarks: Removed.
2754         * benchmarks/parser: Removed.
2755         * benchmarks/parser/html-parser.html: Removed.
2756         * benchmarks/parser/resources: Removed.
2757         * benchmarks/parser/resources/html5.html: Removed.
2758         * benchmarks/parser/resources/runner.js: Removed.
2759         * benchmarks/parser/xml-parser.html: Removed.
2760
2761 2010-12-31  Patrick Gansterer  <paroga@webkit.org>
2762
2763         Reviewed by Adam Barth.
2764
2765         Add XML parser benchmark
2766         https://bugs.webkit.org/show_bug.cgi?id=51612
2767
2768         Move the JavaScript code of html parser into a separate file to share it with xml parser.
2769
2770         * benchmarks/parser/html-parser.html:
2771         * benchmarks/parser/resources/runner.js: Copied from WebCore/benchmarks/parser/html-parser.html.
2772         (runFunction):
2773         (run):
2774         (start):
2775         * benchmarks/parser/xml-parser.html: Copied from WebCore/benchmarks/parser/html-parser.html.
2776
2777 2010-12-29  Zhenyao Mo  <zmo@google.com>
2778
2779         Reviewed by Kenneth Russell.
2780
2781         Update validation of stencil mask and ref values
2782         https://bugs.webkit.org/show_bug.cgi?id=50716
2783
2784         * html/canvas/WebGLRenderingContext.cpp:
2785         (WebCore::WebGLRenderingContext::initializeNewContext): Initialize cached stencil settings.
2786         (WebCore::WebGLRenderingContext::drawArrays): Validate stencil settings.
2787         (WebCore::WebGLRenderingContext::drawElements): Ditto.
2788         (WebCore::WebGLRenderingContext::stencilFunc): Cache stencil settings, but generate no error.
2789         (WebCore::WebGLRenderingContext::stencilFuncSeparate): Ditto.
2790         (WebCore::WebGLRenderingContext::stencilMask): Ditto.
2791         (WebCore::WebGLRenderingContext::stencilMaskSeparate): Ditto.
2792         (WebCore::WebGLRenderingContext::validateStencilSettings): Helper function to validate stencil settings.
2793         * html/canvas/WebGLRenderingContext.h: Declare stencil setting members.
2794
2795 2010-12-30  Martin Robinson  <mrobinson@igalia.com>
2796
2797         Reviewed by Xan Lopez.
2798
2799         [GTK] Fork pieces of RenderThemeGtk that will differ for GTK+ 3
2800         https://bugs.webkit.org/show_bug.cgi?id=51755
2801
2802         Split out pieces of RenderThemeGtk into RenderThemeGtk2 and RenderThemeGtk3
2803         if they are going to differ between GTK+ 2.x and GTK+ 3.x. This is the preliminary
2804         step to landing support for the new GTK+ 3.x theming API.
2805
2806         No new tests. This should not change functionality.
2807
2808         * GNUmakefile.am: Add RenderThemeGtk2 and RenderThemeGtk3 to the sources list.
2809         * platform/gtk/RenderThemeGtk.cpp:
2810         (WebCore::RenderThemeGtk::adjustTextFieldStyle): Call the setTextInputBorders static method.
2811         (WebCore::RenderThemeGtk::adjustTextAreaStyle): Ditto.
2812         (WebCore::RenderThemeGtk::paintMediaButton): Ditto.
2813         (WebCore::RenderThemeGtk::adjustProgressBarStyle): ditto.
2814         * platform/gtk/RenderThemeGtk.h: Make setTextInputBorders a method, so that
2815         it can be exist in RenderThemeGtk{2,3} and be called from RenderThemeGtk.
2816         * platform/gtk/RenderThemeGtk2.cpp: Added. A fork of the bits of RenderThemeGtk
2817         that will eventually be platform-dependent.
2818         * platform/gtk/RenderThemeGtk3.cpp: Added. Ditto.
2819
2820 2010-12-30  Justin Schuh  <jschuh@chromium.org>
2821
2822         Reviewed by James Robinson.
2823
2824         Reverting r74292 because it introduced a crash with ruby text.
2825         https://bugs.webkit.org/show_bug.cgi?id=51637
2826
2827         Test: fast/css/counters/counter-ruby-text-cleared.html
2828
2829         * rendering/RenderCounter.cpp:
2830         (WebCore::findPlaceForCounter):
2831         * rendering/RenderObject.cpp:
2832         (WebCore::RenderObject::addChild):
2833         * rendering/RenderObjectChildList.cpp:
2834         (WebCore::RenderObjectChildList::appendChildNode):
2835         (WebCore::RenderObjectChildList::insertChildNode):
2836
2837 2010-12-30  Darin Adler  <darin@apple.com>
2838
2839         Reviewed by David Kilzer.
2840
2841         Remove unused JSBinding source files
2842         https://bugs.webkit.org/show_bug.cgi?id=51762
2843
2844         * bindings/js/JSBinding.h: Removed.
2845         * bindings/js/specialization: Removed.
2846         * bindings/js/specialization/JSBindingState.cpp: Removed.
2847         * bindings/js/specialization/JSBindingState.h: Removed.
2848
2849         * CMakeLists.txt: Removed references to files.
2850         * GNUmakefile.am: Ditto.
2851         * WebCore.gypi: Ditto.
2852         * WebCore.pro: Ditto.
2853         * WebCore.vcproj/WebCore.vcproj: Ditto.
2854         * bindings/js/JSBindingsAllInOne.cpp: Ditto.
2855
2856 2010-12-30  Tony Gentilcore  <tonyg@chromium.org>
2857
2858         Reviewed by Darin Adler.
2859
2860         Remove Document.h include from some headers where it isn't necessary
2861         https://bugs.webkit.org/show_bug.cgi?id=51730
2862
2863         No new tests because no new functionality.
2864
2865         * editing/EditingStyle.cpp:
2866         * editing/EditingStyle.h:
2867         * editing/SelectionController.h:
2868         * editing/visible_units.h:
2869         * html/HTMLAudioElement.h:
2870         * html/HTMLBodyElement.h:
2871         * inspector/InspectorCSSAgent.h:
2872         * inspector/InspectorDOMAgent.h:
2873         * inspector/InspectorInstrumentation.h:
2874         * xml/DOMParser.cpp:
2875         * xml/DOMParser.h:
2876         (WebCore::DOMParser::create):
2877         (WebCore::DOMParser::DOMParser):
2878
2879 2010-12-30  Benjamin C Meyer  <bmeyer@rim.com>
2880
2881         Reviewed by Darin Adler.
2882
2883         bindings/js/JSDesktopNotificationsCustom.cpp is not included in the cmake build
2884         which is required when NOTIFICATIONS is enabled.
2885
2886         https://bugs.webkit.org/show_bug.cgi?id=51761
2887
2888         * CMakeLists.txt:
2889
2890 2010-12-30  Antti Koivisto  <antti@apple.com>
2891
2892         Not reviewed.
2893
2894         Revert accidental project file change.
2895
2896         * WebCore.xcodeproj/project.pbxproj:
2897
2898 2010-12-30  Antti Koivisto  <antti@apple.com>
2899
2900         Reviewed by Darin Adler.
2901
2902         https://bugs.webkit.org/show_bug.cgi?id=51134
2903         Move loading related code from MemoryCache to CachedResourceLoader
2904
2905         - Merge MemoryCache::requestResource to CachedResourceLoader::requestResource
2906         - Merge MemoryCache::requestUserCSSStyleSheet to CachedResourceLoader::requestUserCSSStyleSheet
2907         - Move MemoryCache::revalidateResource to CachedResourceLoader::revalidateResource
2908         - Add MemoryCache::add
2909         - Refactor the decision on whether to reload, revalidate or use the existing resource to 
2910           a single function, CachedResourceLoader::determineRevalidationPolicy
2911
2912         * css/CSSImageValue.cpp:
2913         (WebCore::CSSImageValue::cachedImage):
2914             
2915             Remove a code path that called MemoryCache::requestResource directly. This code path would have crashed
2916             if ever taken (since it passes null CachedResourceLoader pointer).
2917             
2918         * loader/ImageLoader.cpp:
2919         (WebCore::ImageLoader::updateFromElement):
2920         * loader/cache/CachedImage.cpp:
2921         * loader/cache/CachedResource.cpp:
2922         (WebCore::CachedResource::CachedResource):
2923         (WebCore::CachedResource::~CachedResource):
2924         (WebCore::CachedResource::mustRevalidateDueToCacheHeaders):
2925         
2926             Moved tests that were not about cache headers to CachedResourceLoader::determineRevalidationPolicy and renamed.
2927         
2928         (WebCore::CachedResource::setLoadPriority):
2929         
2930             Check for Unresolved value before setting.
2931         
2932         * loader/cache/CachedResource.h:
2933         (WebCore::CachedResource::setOwningCachedResourceLoader):
2934         
2935             Rename to be bit less mysterious.
2936         
2937         * loader/cache/CachedResourceLoader.cpp:
2938         (WebCore::createResource):
2939         
2940             This was moved from MemoryCache.
2941         
2942         (WebCore::CachedResourceLoader::~CachedResourceLoader):
2943         (WebCore::CachedResourceLoader::determineRevalidationPolicy):
2944         (WebCore::CachedResourceLoader::requestUserCSSStyleSheet):
2945         
2946             This was moved/merged from MemoryCache.
2947         
2948         (WebCore::CachedResourceLoader::canRequest):
2949         (WebCore::CachedResourceLoader::requestResource):
2950         
2951             This combines MemoryCache::requestResource and the existing method.
2952         
2953         (WebCore::CachedResourceLoader::revalidateResource):
2954         
2955             This was moved from MemoryCache.
2956         
2957         (WebCore::CachedResourceLoader::loadResource):
2958         
2959             New method for initiating loading.
2960         
2961         (WebCore::CachedResourceLoader::notifyLoadedFromMemoryCache):
2962         
2963             Renamed the mysterious CachedResourceLoader::checkCacheObjectStatus
2964         
2965         * loader/cache/CachedResourceLoader.h:
2966         * loader/cache/MemoryCache.cpp:
2967         (WebCore::MemoryCache::add):
2968         * loader/cache/MemoryCache.h:
2969         (WebCore::MemoryCache::remove):
2970
2971 2010-12-30  Steve Block  <steveblock@google.com>
2972
2973         Reviewed by Gavin Barraclough.
2974
2975         Enable JSC Rich Source Info for Android even when Inspector and Debugger are disabled
2976         https://bugs.webkit.org/show_bug.cgi?id=51740
2977
2978         This is a policy decision for Android.
2979
2980         No new tests, simply enabling existing, tested code on Android.
2981
2982         * bindings/js/JSDOMWindowBase.cpp:
2983         (WebCore::JSDOMWindowBase::supportsRichSourceInfo):
2984
2985 2010-12-30  Yael Aharon  <yael.aharon@nokia.com>
2986
2987         Reviewed by Adam Barth.
2988
2989         REGRESSION: fast/dom/cssTarget-crash.html fails
2990         https://bugs.webkit.org/show_bug.cgi?id=20342
2991
2992         Do not reload the page when submitting a form, using "GET" method, and the
2993         form action url matches the location url, except for the fragment.
2994       
2995         Test: fast/forms/submit-change-fragment.html
2996
2997         * loader/FrameLoader.cpp:
2998         (WebCore::FrameLoader::loadURL):
2999         (WebCore::FrameLoader::loadWithDocumentLoader):
3000         (WebCore::FrameLoader::shouldScrollToAnchor):
3001         * loader/FrameLoader.h:
3002
3003 2010-12-30  Darin Adler  <darin@apple.com>
3004
3005         Reviewed by Adam Barth.
3006
3007         Move security logic out of the JavaScript binding for location into the DOM class
3008         https://bugs.webkit.org/show_bug.cgi?id=51714
3009
3010         * WebCore.xcodeproj/project.pbxproj: Removed JSBindingState.cpp, JSBindingState.h,
3011         and JSBinding.h. Later, we'll remove them from other project files and delete
3012         the source files.
3013
3014         * bindings/js/JSBinding.h: Emptied out, marked for later deletion.
3015
3016         * bindings/js/JSDOMBinding.cpp: Removed unused overload of the jsOwnedStringOrNull
3017         function, unused shouldAllowNavigation function, unused allowSettingSrcToJavascriptURL
3018         function, unused toLexicalFrame function, unused completeURL function, unused
3019         getCachedDOMStructure and cacheDOMStructure overloads, and unused
3020         getCachedDOMConstructor and cacheDOMConstruction functions.
3021         (WebCore::activeDOMWindow): Added.
3022         (WebCore::firstDOMWindow): Added.
3023         (WebCore::toDynamicFrame): Changed to use firstDOMWindow instead of calling through
3024         JSBindingState, since the latter is an unneeded abstraction.
3025         (WebCore::processingUserGesture): Changed to call ScriptController's function
3026         rather than calling through JSBindingState, which is an unneeded abstraction
3027
3028         * bindings/js/JSDOMBinding.h: Removed the functions mentioned above. Added
3029         activeDOMWindow and firstDOMWindow. Also added a FIXME for the extremely poorly
3030         named allowsAccessFromFrame functions, which answer the question of whether
3031         script is allowed access *to* a frame.
3032
3033         * bindings/js/JSDOMWindowCustom.cpp: Removed many unneeded includes.
3034         (WebCore::JSDOMWindow::setLocation): Streamlined by using the new
3035         activeDOMWindow and firstDOMWindow functions.
3036         (WebCore::JSDOMWindow::open): Ditto.
3037         (WebCore::JSDOMWindow::showModalDialog): Ditto.
3038         (WebCore::JSDOMWindow::postMessage): Ditto.
3039
3040         * bindings/js/JSLocationCustom.cpp:
3041         (WebCore::JSLocation::setHref): Changed to pass the active and first windows through
3042         to the Location::setHref function, with it doing the rest of the work. This moves
3043         work out of the DOM binding that belongs in the DOM itself. Eventually such functions
3044         could even be automatically generated by the bindings script.
3045         (WebCore::JSLocation::setProtocol): Ditto.
3046         (WebCore::JSLocation::setHost): Ditto.
3047         (WebCore::JSLocation::setHostname): Ditto.
3048         (WebCore::JSLocation::setPort): Ditto.
3049         (WebCore::JSLocation::setPathname): Ditto.
3050         (WebCore::JSLocation::setSearch): Ditto.
3051         (WebCore::JSLocation::setHash): Ditto.
3052         (WebCore::JSLocation::replace): Ditto.
3053         (WebCore::JSLocation::reload): Ditto.
3054         (WebCore::JSLocation::assign): Ditto.
3055
3056         * bindings/js/specialization/JSBindingState.cpp: Emptied out, marked for later deletion.
3057         * bindings/js/specialization/JSBindingState.h: Emptied out, marked for later deletion.
3058
3059         * page/DOMWindow.cpp:
3060         (WebCore::DOMWindow::setLocation): Added a SetLocationLocking argument that allows us
3061         to use this function for Location::replace, which is the same as setLocation except that
3062         it locks both history and the back/forward list.
3063         * page/DOMWindow.h: Ditto.
3064
3065         * page/Location.cpp:
3066         (WebCore::Location::setHref): Added. Uses DOMWindow::setLocation so that the security
3067         logic there does not have to be repeated or even refactored.
3068         (WebCore::Location::setProtocol): Ditto.
3069         (WebCore::Location::setHost): Ditto.
3070         (WebCore::Location::setHostname): Ditto.
3071         (WebCore::Location::setPort): Ditto.
3072         (WebCore::Location::setPathname): Ditto.
3073         (WebCore::Location::setSearch): Ditto.
3074         (WebCore::Location::setHash): Ditto.
3075         (WebCore::Location::assign): Ditto.
3076         (WebCore::Location::replace): Ditto.
3077         (WebCore::Location::reload): Added. Security logic was refactored from the code in
3078         JSLocationCustom.cpp. Added a FIXME about the fact that this security logic seems
3079         possibly unneeded.
3080
3081         * page/Location.h: Fixed indentation on the whole file. Added the new functions above.
3082         (WebCore::Location::create):
3083         (WebCore::Location::frame):
3084
3085 2010-12-30  Alexander Pavlov  <apavlov@chromium.org>
3086
3087         Reviewed by Pavel Feldman.
3088
3089         Web Inspector: Pasting a style property with value should automatically split it into prop/value
3090         https://bugs.webkit.org/show_bug.cgi?id=51581
3091
3092         The "paste" DOM event is handled for the CSS property name field to parse out the name and value parts
3093         of a CSS property being pasted (by the first ':' found). The property is committed (if not a new one),
3094         and the edit focus is transferred to the value field.
3095
3096         * inspector/front-end/StylesSidebarPane.js:
3097         (WebInspector.StylePropertyTreeElement.prototype.selectElement):
3098         (WebInspector.StylePropertyTreeElement.prototype):
3099         * inspector/front-end/inspector.js:
3100         (WebInspector.completeURL): Drive-by: return full URLs as-is.
3101         (WebInspector.startEditing.cleanUpAfterEditing):
3102         (WebInspector.startEditing):
3103         (WebInspector.startEditing.pasteEventListener):
3104         (WebInspector.startEditing.keyDownEventListener):
3105
3106 2010-12-30  Pavel Podivilov  <podivilov@chromium.org>
3107
3108         Reviewed by Pavel Feldman.
3109
3110         Web Inspector: breakpoint is not disabled when clicking on breakpoints sidebar pane checkbox.
3111         https://bugs.webkit.org/show_bug.cgi?id=51745
3112
3113         * inspector/front-end/Breakpoint.js:
3114         (WebInspector.Breakpoint.prototype.set enabled):
3115
3116 2010-12-30  Pavel Podivilov  <podivilov@chromium.org>
3117
3118         Reviewed by Pavel Feldman.
3119
3120         Web Inspector: call stack shows "Paused on a JavaScript breakpoint" when stepping.
3121         https://bugs.webkit.org/show_bug.cgi?id=51748
3122
3123         * inspector/front-end/CallStackSidebarPane.js:
3124         (WebInspector.CallStackSidebarPane.prototype.update):
3125         (WebInspector.CallStackSidebarPane.prototype.registerShortcuts):
3126         (WebInspector.CallStackSidebarPane.prototype._scriptBreakpointHit):
3127         (WebInspector.CallStackSidebarPane.prototype._nativeBreakpointHit):
3128
3129 2010-12-30  Mikhail Naganov  <mnaganov@chromium.org>
3130
3131         Reviewed by Pavel Feldman.
3132
3133         Fix leak of MemoryInfo wrappers introduced in r57004 (see issue 51712).
3134
3135         https://bugs.webkit.org/show_bug.cgi?id=51713
3136
3137         * WebCore.gypi:
3138         * WebCore.pro:
3139         * bindings/v8/custom/V8ConsoleCustom.cpp:
3140         (WebCore::V8Console::memoryAccessorGetter):
3141         * bindings/v8/custom/V8PerformanceCustom.cpp: Copied from V8ConsoleCustom.cpp.
3142         (WebCore::V8Performance::memoryAccessorGetter):
3143         * page/Console.idl:
3144         * page/Performance.idl:
3145
3146 2010-12-30  Steve Block  <steveblock@google.com>
3147
3148         Reviewed by Sam Weinig.
3149
3150         Visiting macnn.com often causes SQL spew via geolocation database
3151         https://bugs.webkit.org/show_bug.cgi?id=51557
3152
3153         If the Geolocation position cache database path has not been set, early-out
3154         rather than using an empty path and thus failing to open the database.
3155         This avoids SQL log spew.
3156
3157         Also, avoid starting the database thread until the path has been set, and
3158         shorten the thread name to avoid warnings due to exceeding 30 characters.
3159
3160         No new tests, implementation clean-up only.
3161
3162         * page/GeolocationPositionCache.cpp:
3163         (WebCore::GeolocationPositionCache::addUser):
3164         (WebCore::GeolocationPositionCache::removeUser):
3165         (WebCore::GeolocationPositionCache::setDatabasePath):
3166         (WebCore::GeolocationPositionCache::startBackgroundThread):
3167
3168 2010-12-29  Philippe Normand  <pnormand@igalia.com>
3169
3170         Reviewed by Martin Robinson.
3171
3172         [GTK] minimal build fails at link time due to missing sqlite3 symbols
3173         https://bugs.webkit.org/show_bug.cgi?id=51327
3174
3175         Guard the code calling sqlite3 with the ENABLE(DATABASE) check.
3176
3177         No new tests, build fix only.
3178
3179         * platform/sql/SQLiteAuthorizer.cpp:
3180         * platform/sql/SQLiteDatabase.cpp:
3181         * platform/sql/SQLiteFileSystem.cpp:
3182         * platform/sql/SQLiteStatement.cpp:
3183         * platform/sql/SQLiteTransaction.cpp:
3184
3185 2010-12-30  Justin Schuh  <jschuh@chromium.org>
3186
3187         Reviewed by Dirk Schulze.
3188
3189         Prevent stringToLengthType() from skipping past end-of-string on invalid length unit. 
3190         https://bugs.webkit.org/show_bug.cgi?id=51692
3191
3192         * svg/SVGLength.cpp:
3193         (WebCore::stringToLengthType):
3194         (WebCore::SVGLength::setValueAsString):
3195
3196 2010-12-30  Abhishek Arya  <inferno@chromium.org>
3197
3198         Reviewed by Eric Seidel.
3199
3200         Create a helper function for finding descendent video elements for a node.
3201         https://bugs.webkit.org/show_bug.cgi?id=51696
3202
3203         Test: media/video-element-other-namespace-crash.html
3204
3205         * html/MediaDocument.cpp:
3206         (WebCore::descendentVideoElement): helper function.
3207         (WebCore::MediaDocument::defaultEventHandler): use the new helper function. fix code repetitions.
3208         (WebCore::MediaDocument::replaceMediaElementTimerFired): use the new helper function.
3209
3210 2010-12-29  Pavel Feldman  <pfeldman@chromium.org>
3211
3212         Reviewed by Yury Semikhatsky.
3213
3214         Web Inspector: extract Database & DOM Storage agents; remove InspectorBackend.
3215         https://bugs.webkit.org/show_bug.cgi?id=51707
3216
3217         This change brushes up storage agents + removes redundant InspectorBackend class.
3218
3219         * CMakeLists.txt:
3220         * GNUmakefile.am:
3221         * WebCore.gypi:
3222         * WebCore.pro:
3223         * WebCore.vcproj/WebCore.vcproj:
3224         * WebCore.xcodeproj/project.pbxproj:
3225         * inspector/CodeGeneratorInspector.pm:
3226         * inspector/InjectedScriptHost.cpp:
3227         (WebCore::InjectedScriptHost::databaseForId):
3228         (WebCore::InjectedScriptHost::selectDatabase):
3229         (WebCore::InjectedScriptHost::selectDOMStorage):
3230         (WebCore::InjectedScriptHost::inspectorDOMAgent):
3231         * inspector/Inspector.idl:
3232         * inspector/InspectorBackend.cpp: Removed.
3233         * inspector/InspectorBackend.h: Removed.
3234         * inspector/InspectorController.cpp:
3235         (WebCore::InspectorController::InspectorController):
3236         (WebCore::InspectorController::~InspectorController):
3237         (WebCore::InspectorController::connectFrontend):
3238         (WebCore::InspectorController::releaseFrontendLifetimeAgents):
3239         (WebCore::InspectorController::didUseDOMStorage):
3240         (WebCore::InspectorController::setInjectedScriptSource):
3241         (WebCore::InspectorController::dispatchOnInjectedScript):
3242         (WebCore::InspectorController::releaseWrapperObjectGroup):
3243         * inspector/InspectorController.h:
3244         * inspector/InspectorDOMStorageAgent.cpp: Added.
3245         (WebCore::InspectorDOMStorageAgent::~InspectorDOMStorageAgent):
3246         (WebCore::InspectorDOMStorageAgent::getDOMStorageEntries):
3247         (WebCore::InspectorDOMStorageAgent::setDOMStorageItem):
3248         (WebCore::InspectorDOMStorageAgent::removeDOMStorageItem):
3249         (WebCore::InspectorDOMStorageAgent::selectDOMStorage):
3250         (WebCore::InspectorDOMStorageAgent::InspectorDOMStorageAgent):
3251         (WebCore::InspectorDOMStorageAgent::getDOMStorageResourceForId):
3252         * inspector/InspectorDOMStorageAgent.h: Copied from WebCore/inspector/InspectorStorageAgent.h.
3253         (WebCore::InspectorDOMStorageAgent::create):
3254         (WebCore::InspectorDOMStorageAgent::frontend):
3255         * inspector/InspectorDatabaseAgent.cpp: Renamed from WebCore/inspector/InspectorStorageAgent.cpp.
3256         (WebCore::InspectorDatabaseAgent::~InspectorDatabaseAgent):
3257         (WebCore::InspectorDatabaseAgent::getDatabaseTableNames):
3258         (WebCore::InspectorDatabaseAgent::executeSQL):
3259         (WebCore::InspectorDatabaseAgent::databaseForId):
3260         (WebCore::InspectorDatabaseAgent::selectDatabase):
3261         (WebCore::InspectorDatabaseAgent::clearFrontend):
3262         (WebCore::InspectorDatabaseAgent::InspectorDatabaseAgent):
3263         * inspector/InspectorDatabaseAgent.h: Renamed from WebCore/inspector/InspectorStorageAgent.h.
3264         (WebCore::InspectorDatabaseAgent::create):
3265         (WebCore::InspectorDatabaseAgent::frontend):
3266         * inspector/front-end/ScriptsPanel.js:
3267         (WebInspector.ScriptsPanel.prototype.show):
3268         (WebInspector.ScriptsPanel.prototype.attachDebuggerWhenShown):
3269         (WebInspector.ScriptsPanel.prototype._toggleDebugging):
3270
3271 2010-12-29  Dirk Schulze  <krit@webkit.org>
3272
3273         Reviewed by Darin Adler.
3274
3275         Cleanup SVG code according to the webkit style rules 3
3276         https://bugs.webkit.org/show_bug.cgi?id=51490
3277
3278         Last patch to fix indention and other style issues according to the WebKit style rules in the SVG code.
3279         Just one file can't be fixed for check-webkit-style.
3280         * SVGAllInOne.cpp: check-webkit-style wants a config.h at the beginning
3281
3282         No changes of functionality, so no new tests. 
3283
3284         * svg/SVGAllInOne.cpp:
3285         * svg/SVGImage.cpp:
3286         * svg/SVGLength.cpp:
3287         (WebCore::SVGLength::setValue):
3288         * svg/SVGPolygonElement.h:
3289         * svg/SVGPolylineElement.h:
3290         * svg/SVGPreserveAspectRatio.cpp:
3291         (WebCore::SVGPreserveAspectRatio::parsePreserveAspectRatio):
3292         (WebCore::SVGPreserveAspectRatio::transformRect):
3293         * svg/SVGSVGElement.cpp:
3294         (WebCore::SVGSVGElement::viewport):
3295         * svg/SVGSetElement.h:
3296         * svg/SVGStylable.h:
3297         (WebCore::SVGStylable::~SVGStylable):
3298         * svg/SVGStyledLocatableElement.h:
3299         (WebCore::SVGStyledLocatableElement::localCoordinateSpaceTransform):
3300         (WebCore::SVGStyledLocatableElement::isStyledLocatable):
3301         * svg/SVGStyledTransformableElement.cpp:
3302         (WebCore::SVGStyledTransformableElement::isKnownAttribute):
3303         * svg/SVGSwitchElement.cpp:
3304         (WebCore::SVGSwitchElement::childShouldCreateRenderer):
3305         * svg/SVGTests.cpp:
3306         (WebCore::SVGTests::parseMappedAttribute):
3307         * svg/SVGTextContentElement.cpp:
3308         (WebCore::SVGTextContentElement::isKnownAttribute):
3309         * svg/SVGTextPathElement.cpp:
3310         * svg/SVGTextPathElement.h:
3311         * svg/SVGTitleElement.h:
3312         (WebCore::SVGTitleElement::rendererIsNeeded):
3313         * svg/SVGTransformDistance.cpp:
3314         (WebCore::SVGTransformDistance::SVGTransformDistance):
3315         (WebCore::SVGTransformDistance::scaledDistance):
3316         (WebCore::SVGTransformDistance::addSVGTransforms):
3317         (WebCore::SVGTransformDistance::addSVGTransform):
3318         (WebCore::SVGTransformDistance::addToSVGTransform):
3319         (WebCore::SVGTransformDistance::isZero):
3320         * svg/SVGTransformList.cpp:
3321         * svg/SVGURIReference.cpp:
3322         (WebCore::SVGURIReference::getTarget):
3323         * svg/SVGVKernElement.h:
3324         * svg/SVGViewSpec.cpp:
3325         (WebCore::SVGViewSpec::parseViewSpec):
3326         * svg/SVGZoomAndPan.h:
3327         (WebCore::SVGZoomAndPan::SVGZoomAndPan):
3328         (WebCore::SVGZoomAndPan::~SVGZoomAndPan):
3329         (WebCore::SVGZoomAndPan::zoomAndPan):
3330         * svg/SVGZoomEvent.h:
3331         (WebCore::SVGZoomEvent::create):
3332         * svg/animation/SMILTime.cpp:
3333         (WebCore::operator*):
3334         * svg/animation/SMILTime.h:
3335         (WebCore::SMILTime::SMILTime):
3336         (WebCore::SMILTime::unresolved):
3337         (WebCore::SMILTime::indefinite):
3338         (WebCore::SMILTime::operator=):
3339         (WebCore::SMILTime::value):
3340         (WebCore::SMILTime::isFinite):
3341         (WebCore::SMILTime::isIndefinite):
3342         (WebCore::SMILTime::isUnresolved):
3343         (WebCore::operator==):
3344         (WebCore::operator!): new operator checks for 0 or infinite values.
3345         (WebCore::operator!=):
3346         (WebCore::operator>):
3347         (WebCore::operator<):
3348         (WebCore::operator>=):
3349         (WebCore::operator<=):
3350         * svg/animation/SMILTimeContainer.h:
3351         (WebCore::SMILTimeContainer::create):
3352         (WebCore::SMILTimeContainer::setDocumentOrderIndexesDirty):
3353         * svg/animation/SVGSMILElement.cpp:
3354         (WebCore::ConditionEventListener::operator==):
3355         (WebCore::SVGSMILElement::repeatingDuration):
3356         (WebCore::SVGSMILElement::resolveInterval):
3357         (WebCore::SVGSMILElement::calculateAnimationPercentAndRepeat):
3358         * svg/animation/SVGSMILElement.h:
3359         (WebCore::SVGSMILElement::timeContainer):
3360         (WebCore::SVGSMILElement::intervalBegin):
3361         (WebCore::SVGSMILElement::intervalEnd):
3362         (WebCore::SVGSMILElement::previousIntervalBegin):
3363         (WebCore::SVGSMILElement::documentOrderIndex):
3364         (WebCore::SVGSMILElement::setDocumentOrderIndex):
3365         * svg/graphics/SVGImage.h:
3366         (WebCore::SVGImage::create):
3367         (WebCore::SVGImage::destroyDecodedData):
3368         (WebCore::SVGImage::decodedSize):
3369         (WebCore::SVGImage::frameAtIndex):
3370         * svg/graphics/filters/SVGFilterBuilder.h:
3371         (WebCore::SVGFilterBuilder::create):
3372         (WebCore::SVGFilterBuilder::lastEffect):
3373         (WebCore::SVGFilterBuilder::getEffectReferences):
3374         (WebCore::SVGFilterBuilder::addBuiltinEffects):
3375
3376 2010-12-29  Abhishek Arya  <inferno@chromium.org>
3377
3378         Reviewed by Darin Adler.
3379
3380         ASSERT(oldchild->parent() == owner) fails.
3381         https://bugs.webkit.org/show_bug.cgi?id=50480
3382
3383         In RenderBlock removeChild function, when the inlineChildrenBlock(equal to prev or next)
3384         is reparented to blockChildrenBlock, it is no longer a child of "this". This causes the
3385         assertion failure when removeChildNode executes on the child(equal to prev or next).
3386         Fix a typo in canMergeContiguousAnonymousBlocks.
3387
3388         Test: fast/multicol/span/double-merge-anonymous-block-crash.html
3389
3390         * rendering/RenderBlock.cpp:
3391         (WebCore::canMergeContiguousAnonymousBlocks): fix typo, change prev to next.
3392         (WebCore::RenderBlock::removeChild): if prev or not is reparented, then set it to zero.
3393
3394 2010-12-29  Justin Schuh  <jschuh@chromium.org>
3395
3396         Reviewed by Darin Adler.
3397
3398         Check SVG element type in FrameView::scrollToAnchor
3399         https://bugs.webkit.org/show_bug.cgi?id=51718
3400
3401         Test: svg/custom/scroll-to-anchor-in-symbol.svg
3402
3403         * page/FrameView.cpp:
3404         (WebCore::FrameView::scrollToAnchor):
3405
3406 2010-12-29  Anton Muhin  <antonm@chromium.org>
3407
3408         Reviewed by Eric Seidel.
3409
3410         [v8] Minor cleanup: remove unused method (the only method which can mutate context of V8DOMWindowShell)
3411         https://bugs.webkit.org/show_bug.cgi?id=51704
3412
3413         * bindings/v8/V8DOMWindowShell.cpp:
3414         * bindings/v8/V8DOMWindowShell.h:
3415
3416 2010-12-29  Kenichi Ishibashi  <bashi@google.com>
3417
3418         Reviewed by Darin Adler.
3419
3420         Use a HashMap for m_continuation to save memory
3421         https://bugs.webkit.org/show_bug.cgi?id=43716
3422
3423         Saving memory consumption by applying a HashMap convention to
3424         continuation pointers of RenderInline and RenderBlock classes.
3425
3426         * rendering/RenderBlock.cpp: Removed m_continuation.
3427         (WebCore::RenderBlock::RenderBlock):
3428         (WebCore::RenderBlock::destroy):
3429         (WebCore::RenderBlock::inlineElementContinuation):
3430         (WebCore::RenderBlock::blockElementContinuation):
3431         * rendering/RenderBlock.h: Removed m_continuation.
3432         * rendering/RenderBoxModelObject.cpp: Added a hash map for continuations.
3433         (WebCore::RenderBoxModelObject::destroy): Added an assertion.
3434         (WebCore::RenderBoxModelObject::continuation): Added.
3435         (WebCore::RenderBoxModelObject::setContinuation): Added.
3436         * rendering/RenderBoxModelObject.h:
3437         * rendering/RenderInline.cpp: Removed m_continuation.
3438         (WebCore::RenderInline::RenderInline):
3439         (WebCore::RenderInline::destroy):
3440         (WebCore::RenderInline::inlineElementContinuation):
3441         * rendering/RenderInline.h: Removed m_continuation.
3442
3443 2010-12-27  Amruth Raj  <amruthraj@motorola.com> and Ravi Kasibhatla  <ravi.kasibhatla@motorola.com>
3444
3445         Reviewed by Martin Robinson.
3446
3447         [GTK] Enable building whatever already exists of WebKit2
3448         https://bugs.webkit.org/show_bug.cgi?id=37369
3449
3450         No new functionality added or deleted. Only makefile change. Hence, no tests added.
3451
3452         * GNUmakefile.am: Removed bindings/gobject from webcore_sources & webcore_cppflags and
3453         added them to WebKit/gtk/GNUmakefile.am
3454         * platform/network/soup/cache/webkit/soup-cache.h: Remove include <webkit/webkitdefines.h>
3455         and declare WEBKIT_API directly
3456
3457 2010-12-29  Eric Seidel  <eric@webkit.org>
3458
3459         Unreviewed.
3460
3461         Simplify make-hash-tools.pl
3462         https://bugs.webkit.org/show_bug.cgi?id=49922
3463
3464         Added HashTools.h to the project file now that its not autogenerated.
3465         I also sorted the project file using sort-xcode-project-file
3466
3467         * WebCore.xcodeproj/project.pbxproj:
3468
3469 2010-12-29  Pavel Feldman  <pfeldman@chromium.org>
3470
3471         Not reviewed: revert r74755 and 74757.
3472
3473 2010-12-29  Martin Robinson  <mrobinson@igalia.com>
3474
3475         Reviewed by Sam Weinig.
3476
3477         JSDataViewCustom.cpp gives the fastcall calling convention to functions called via C++
3478         https://bugs.webkit.org/show_bug.cgi?id=51722
3479
3480         Remove the JSC_HOST_CALL from methods that are called from C++. JSC_HOST_CALL gives
3481         methods the fastcall calling convention, which leads to runtime errors when they are
3482         called from C++. Also remove a bit of unnecessary code duplication.
3483
3484         No new tests. This is covered by fast/canvas/webgl/data-view-test.html.
3485
3486         * bindings/js/JSDataViewCustom.cpp:
3487         (WebCore::getDataViewMember): Remove duplicated code.
3488         (WebCore::JSDataView::getInt8): Remove JSC_HOST_CALL.
3489         (WebCore::JSDataView::getUint8): Ditto.
3490         (WebCore::JSDataView::getFloat32): Ditto.
3491         (WebCore::JSDataView::getFloat64): Ditto.
3492         (WebCore::setDataViewMember): Remove duplicated code.
3493         (WebCore::JSDataView::setInt8): Remove JSC_HOST_CALL.
3494         (WebCore::JSDataView::setUint8): Ditto.
3495
3496 2010-12-29  Dan Bernstein  <mitz@apple.com>
3497
3498         Reviewed by Kenneth Russel.
3499
3500         A more robust fix for https://bugs.webkit.org/show_bug.cgi?id=51681
3501
3502         * html/HTMLCanvasElement.cpp:
3503         (WebCore::HTMLCanvasElement::attach): Added. Like recalcStyle(), calls
3504         CanvasRenderingContext2D::updateFont() if necessary. This covers the case of a detach/
3505         attach-type style recalc.
3506         * html/HTMLCanvasElement.h:
3507         * html/canvas/CanvasRenderingContext2D.cpp:
3508         (WebCore::CanvasRenderingContext2D::drawTextInternal): Removed the early return added in
3509         r74716. A font that is loading custom fonts is okay to use, as long as it is valid.
3510         (WebCore::CanvasRenderingContext2D::accessFont): Added a call to
3511         Document::updateStyleIfNeeded(). This ensures that any pending style recalc will take place
3512         and update the font if it is invalid.
3513         * platform/graphics/Font.h:
3514         (WebCore::Font::loadingCustomFonts): Made this private.
3515
3516 2010-12-29  Pavel Feldman  <pfeldman@chromium.org>
3517
3518         Not reviewed: Qt build fix.
3519
3520         * inspector/InspectorController.cpp:
3521
3522 2010-12-29  Pavel Feldman  <pfeldman@chromium.org>
3523
3524         Reviewed by Yury Semikhatsky.
3525
3526         Web Inspector: extract Database & DOM Storage
3527         agents; remove InspectorBackend.
3528         https://bugs.webkit.org/show_bug.cgi?id=51707
3529
3530         This change brushes up storage agents + removes redundant
3531         InspectorBackend class.
3532
3533         * CMakeLists.txt:
3534         * GNUmakefile.am:
3535         * WebCore.gypi:
3536         * WebCore.pro:
3537         * WebCore.vcproj/WebCore.vcproj:
3538         * WebCore.xcodeproj/project.pbxproj:
3539         * inspector/CodeGeneratorInspector.pm:
3540         * inspector/InjectedScriptHost.cpp:
3541         (WebCore::InjectedScriptHost::databaseForId):
3542         (WebCore::InjectedScriptHost::selectDatabase):
3543         (WebCore::InjectedScriptHost::selectDOMStorage):
3544         (WebCore::InjectedScriptHost::inspectorDOMAgent):
3545         * inspector/Inspector.idl:
3546         * inspector/InspectorBackend.cpp: Removed.
3547         * inspector/InspectorBackend.h: Removed.
3548         * inspector/InspectorController.cpp:
3549         (WebCore::InspectorController::InspectorController):
3550         (WebCore::InspectorController::~InspectorController):
3551         (WebCore::InspectorController::connectFrontend):
3552         (WebCore::InspectorController::releaseFrontendLifetimeAgents):
3553         (WebCore::InspectorController::didUseDOMStorage):
3554         (WebCore::InspectorController::setInjectedScriptSource):
3555         (WebCore::InspectorController::dispatchOnInjectedScript):
3556         (WebCore::InspectorController::releaseWrapperObjectGroup):
3557         * inspector/InspectorController.h:
3558         * inspector/InspectorDOMStorageAgent.cpp: Added.
3559         (WebCore::InspectorDOMStorageAgent::~InspectorDOMStorageAgent):
3560         (WebCore::InspectorDOMStorageAgent::getDOMStorageEntries):
3561         (WebCore::InspectorDOMStorageAgent::setDOMStorageItem):
3562         (WebCore::InspectorDOMStorageAgent::removeDOMStorageItem):
3563         (WebCore::InspectorDOMStorageAgent::selectDOMStorage):
3564         (WebCore::InspectorDOMStorageAgent::InspectorDOMStorageAgent):
3565         (WebCore::InspectorDOMStorageAgent::getDOMStorageResourceForId):
3566         * inspector/InspectorDOMStorageAgent.h: Copied from WebCore/inspector/InspectorStorageAgent.h.
3567         (WebCore::InspectorDOMStorageAgent::create):
3568         (WebCore::InspectorDOMStorageAgent::frontend):
3569         * inspector/InspectorDatabaseAgent.cpp: Renamed from WebCore/inspector/InspectorStorageAgent.cpp.
3570         (WebCore::InspectorDatabaseAgent::~InspectorDatabaseAgent):
3571         (WebCore::InspectorDatabaseAgent::getDatabaseTableNames):
3572         (WebCore::InspectorDatabaseAgent::executeSQL):
3573         (WebCore::InspectorDatabaseAgent::databaseForId):
3574         (WebCore::InspectorDatabaseAgent::selectDatabase):
3575         (WebCore::InspectorDatabaseAgent::clearFrontend):
3576         (WebCore::InspectorDatabaseAgent::InspectorDatabaseAgent):
3577         * inspector/InspectorDatabaseAgent.h: Renamed from WebCore/inspector/InspectorStorageAgent.h.
3578         (WebCore::InspectorDatabaseAgent::create):
3579         (WebCore::InspectorDatabaseAgent::frontend):
3580         * inspector/InspectorFrontendClientLocal.cpp:
3581         * inspector/InspectorFrontendClientLocal.h:
3582         * inspector/front-end/ScriptsPanel.js:
3583         (WebInspector.ScriptsPanel.prototype.show):
3584
3585 2010-12-29  Tony Gentilcore  <tonyg@chromium.org>
3586
3587         Reviewed by Eric Seidel.
3588
3589         Assertion failure: element->inDocument() in AsyncScriptRunner::executeScriptSoon()
3590         https://bugs.webkit.org/show_bug.cgi?id=51067
3591
3592         Typically when a script element is removed from the document, the cached script
3593         client is removed. However, during the before load event, the cached script client
3594         hasn't been created yet so it can't be removed.
3595
3596         This patch handles that case by explicitly checking if the script element was
3597         removed during the beforeload event. Also, it avoids caching the Document references
3598         over the arbitrary script execution in the before load event.
3599
3600         Test: fast/dom/HTMLScriptElement/move-in-beforeload.html
3601               fast/dom/HTMLScriptElement/remove-in-beforeload.html
3602
3603         * dom/ScriptElement.cpp:
3604         (WebCore::ScriptElement::requestScript):
3605
3606 2010-12-29  Alexander Pavlov  <apavlov@chromium.org>
3607
3608         Reviewed by Yury Semikhatsky.
3609
3610         Web Inspector: Element highlight tooltip displays wrong element size when zoomed in
3611         https://bugs.webkit.org/show_bug.cgi?id=51703
3612
3613         * inspector/InspectorController.cpp:
3614         (WebCore::InspectorController::drawElementTitle):
3615
3616 2010-12-29  Yael Aharon  <yael.aharon@nokia.com>
3617
3618         Reviewed by Kent Tamura.
3619
3620         [HTML5][Forms] Support for :in-range and :out-of-range CSS selectors
3621         https://bugs.webkit.org/show_bug.cgi?id=29071
3622
3623         Use InputType::rangeUnderflow() and InputType::rangeOverflow()
3624         to determine if a control is in-range or out-of-range.
3625
3626         Tests: fast/css/pseudo-in-range-invalid-value.html
3627                fast/css/pseudo-in-range.html
3628                fast/css/pseudo-out-of-range.html
3629
3630         * css/CSSSelector.cpp:
3631         (WebCore::CSSSelector::pseudoId):
3632         (WebCore::nameToPseudoTypeMap):
3633         (WebCore::CSSSelector::extractPseudoType):
3634         * css/CSSSelector.h:
3635         * css/CSSStyleSelector.cpp:
3636         (WebCore::CSSStyleSelector::canShareStyleWithElement):
3637         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
3638         * dom/Element.h:
3639         (WebCore::Element::isInRange):
3640         (WebCore::Element::isOutOfRange):
3641         * html/BaseDateAndTimeInputType.cpp:
3642         (WebCore::BaseDateAndTimeInputType::supportsRangeLimitation):