2011-03-30 Ryuan Choi <ryuan.choi@samsung.com>
[WebKit-https.git] / Source / WebCore / ChangeLog
1 2011-03-30  Ryuan Choi  <ryuan.choi@samsung.com>
2
3         Reviewed by Martin Robinson.
4
5         [GTK] Fix leaked pointer in FontGtk.cpp
6         https://bugs.webkit.org/show_bug.cgi?id=57307
7
8         Fix a memory leak.
9
10         No new functionality, so no new tests.
11
12         * platform/graphics/gtk/FontGtk.cpp:
13         (WebCore::utf16ToUtf8): Rename utf16_to_utf8 and fix indentation.
14         (WebCore::convertUniCharToUTF8):
15
16 2011-03-30  Dominic Cooney  <dominicc@google.com>
17
18         Reviewed by Dimitri Glazkov.
19
20         Adds layoutTestController.shadowRoot accessor to Mac DRT.
21         https://bugs.webkit.org/show_bug.cgi?id=57415
22
23         * WebCore.exp.in: DRT needs to link WebCore::Element::shadowRoot
24
25 2011-03-30  Kent Tamura  <tkent@chromium.org>
26
27         Reviewed by Dimitri Glazkov.
28
29         Simplify HTMLFormElement::validateInteractively() for asynchronous scroll event
30         https://bugs.webkit.org/show_bug.cgi?id=57424
31
32         r75555 made 'scroll' event asynchronous. So we don't need to worry about
33         deleting or moving a target node in scrollIntoViewIfNeeded().
34
35         * html/HTMLFormElement.cpp:
36         (WebCore::HTMLFormElement::validateInteractively): Remove unnecessary code.
37
38 2011-03-30  Kent Tamura  <tkent@chromium.org>
39
40         Reviewed by Darin Adler.
41
42         REGRESSION (r74895): Crash if input.type = 'file' twice
43         https://bugs.webkit.org/show_bug.cgi?id=57343
44
45         * html/HTMLInputElement.cpp:
46         (WebCore::HTMLInputElement::updateType):
47           Don't call setAttribute() if the type is not changed.
48
49 2011-03-30  Jia Pu  <jpu@apple.com>
50
51         Reviewed by Darin Adler.
52
53         Autocorrection panel isn't positioned correctly in Safari (mac) when the zooming is not 1x.
54         https://bugs.webkit.org/show_bug.cgi?id=57353
55         <rdar://problem/9163983>
56
57         We use Range::textQuads() instead of Range::boundingRect() to compute the position of correction
58         panel. The latter function compensates for zooming, which we don't need in this case. We also
59         dismiss correction panel when zooming factor is changed. This is done in Frame::setPageAndTextZoomFactors().
60
61         * WebCore.exp.in:
62         * dom/Range.cpp:
63         (WebCore::Range::textQuads):
64         * dom/Range.h:
65         * editing/Editor.cpp:
66         (WebCore::Editor::windowRectForRange):
67         * editing/Editor.h:
68         * page/Frame.cpp:
69         (WebCore::Frame::setPageAndTextZoomFactors):
70
71 2011-03-30  Chris Guillory  <chris.guillory@google.com>
72
73         Reviewed by Dimitri Glazkov.
74
75         Render fonts using skia when requested by platform context.
76         https://bugs.webkit.org/show_bug.cgi?id=56441
77
78         * platform/graphics/skia/PlatformContextSkia.cpp:
79         (WebCore::PlatformContextSkia::isNativeFontRenderingAllowed):
80         * platform/graphics/skia/PlatformContextSkia.h:
81         * platform/graphics/skia/SkiaFontWin.cpp:
82         (WebCore::windowsCanHandleTextDrawing):
83         (WebCore::skiaDrawText):
84         (WebCore::setupPaintForFont):
85         (WebCore::paintSkiaText):
86
87 2011-03-30  Dan Bernstein  <mitz@apple.com>
88
89         Reviewed by Darin Adler.
90
91         <rdar://problem/9199518> Crash when focusing a styled editable element
92
93         Test: editing/deleting/delete-button-background-image-none.html
94
95         * editing/DeleteButtonController.cpp:
96         (WebCore::isDeletableElement): Check all background layers for background images.
97         * rendering/style/RenderStyle.h: Removed backgroundImage() as it was only used, incorrectly,
98         in the above function.
99
100 2011-03-30  Martin Robinson  <mrobinson@igalia.com>
101
102         Try once more to fix the EFL build.
103
104         * platform/efl/RenderThemeEfl.cpp:
105
106 2011-03-30  Chris Fleizach  <cfleizach@apple.com>
107
108         Reviewed by Darin Adler.
109
110         Regression: VO cursor doesn't follow KB focus back into HTML view
111         https://bugs.webkit.org/show_bug.cgi?id=57509
112
113         In WK2, because the web area never believes focus leave the area, sending the initial
114         focus change when moving back into the web area, does not trigger a notification.
115
116         That behavior needs to be overridden by explicitly posting a focused UI element change
117         at the appropriate time. This is only used in WK2, hence the absence of a layout test for now.
118
119         * page/FocusController.cpp:
120         (WebCore::FocusController::setInitialFocus):
121
122 2011-03-30  MORITA Hajime  <morrita@google.com>
123
124         Reviewed by Simon Fraser.
125
126         box-shadow radii stays the same regardless of any spread set
127         https://bugs.webkit.org/show_bug.cgi?id=49726
128
129         - Removed special shadowSpread handling path
130         - Fixed broken multple inset shadow border computation.
131
132         Test: fast/box-shadow/spread-multiple-inset.html
133
134         * rendering/RenderBoxModelObject.cpp:
135         (WebCore::RenderBoxModelObject::paintBoxShadow):
136
137 2011-03-29  Matthew Delaney  <mdelaney@apple.com>
138
139         Reviewed by Simon Fraser.
140
141         Use the Accelerate vImage vectorized (un)premultiplyImageData functions for ImageBufferCG
142
143         https://bugs.webkit.org/show_bug.cgi?id=53134
144
145         Test: fast/canvas/getPutImageDataPairTest.html
146
147         * platform/graphics/cg/ImageBufferCG.cpp:
148
149 2011-03-30  Martin Robinson  <mrobinson@igalia.com>
150
151         Try to fix the WinCairo build.
152
153         * platform/graphics/win/GraphicsContextCairoWin.cpp:
154         (WebCore::GraphicsContext::platformInit): Fix misspelling of GraphicsContextPlatformPrivateToplevel.
155
156 2011-03-30  Steve Falkenburg  <sfalken@apple.com>
157
158         Reviewed by Adam Roben.
159
160         Share most vsprops between Release and Production builds in releaseproduction.vsprops
161         https://bugs.webkit.org/show_bug.cgi?id=57508
162
163         * WebCore.vcproj/QTMovieWinProduction.vsprops:
164         * WebCore.vcproj/QTMovieWinRelease.vsprops:
165         * WebCore.vcproj/QTMovieWinReleaseCairoCFLite.vsprops:
166         * WebCore.vcproj/WebCoreProduction.vsprops:
167         * WebCore.vcproj/WebCoreRelease.vsprops:
168         * WebCore.vcproj/WebCoreReleaseCairoCFLite.vsprops:
169
170 2011-03-30  Timur Iskhodzhanov  <timurrrr@google.com>
171
172         Reviewed by Alexey Proskuryakov.
173
174         Add some dynamic annotations to JavaScriptCore/wtf
175         https://bugs.webkit.org/show_bug.cgi?id=53747
176
177         By using these annotations we can improve the precision of finding
178         WebKit errors using dynamic analysis tools like ThreadSanitizer and Valgrind.
179         These annotations don't affect the compiled binaries unless USE(DYNAMIC_ANNOTATIONS) is "1".
180
181         These files don't add new functionality, so don't need extra tests.
182
183         * ForwardingHeaders/wtf/DynamicAnnotations.h: Added.
184
185 2011-03-30  Martin Robinson  <mrobinson@igalia.com>
186
187         Try to fix the EFL build.
188
189         * platform/efl/RenderThemeEfl.cpp:
190         (WebCore::RenderThemeEfl::paintThemePart): Use the new cairo_t accessor on the platform context.
191
192 2011-03-30  Abhishek Arya  <inferno@chromium.org>
193
194         Reviewed by Simon Fraser.
195
196         Fix wrong type assumptions in editing code. Move code
197         from ASSERTs to hard checks.
198         https://bugs.webkit.org/show_bug.cgi?id=57348
199
200         Test: editing/execCommand/remove-format-non-html-element-crash.html
201
202         * css/CSSStyleSelector.cpp:
203         (WebCore::CSSStyleSelector::applyProperty):
204         * editing/ApplyStyleCommand.cpp:
205         (WebCore::getRGBAFontColor):
206         (WebCore::ApplyStyleCommand::pushDownInlineStyleAroundNode):
207         * editing/DeleteButtonController.cpp:
208         (WebCore::enclosingDeletableElement):
209         * editing/EditingStyle.cpp:
210         (WebCore::EditingStyle::textDirection):
211         (WebCore::EditingStyle::prepareToApplyAt):
212         * editing/Editor.cpp:
213         (WebCore::Editor::textDirectionForSelection):
214         * editing/FormatBlockCommand.cpp:
215         (WebCore::FormatBlockCommand::elementForFormatBlockCommand):
216
217 2011-03-30  Stephen White  <senorblanco@chromium.org>
218
219         Reviewed by Kenneth Russell.
220
221         Speed up clipping in accelerated 2D canvas.
222         https://bugs.webkit.org/show_bug.cgi?id=57464
223
224         Instead of clearing the entire stencil buffer when removing clipping paths, we erase the path with a DECR stencil operation.
225         Covered by canvas/philip/tests/2d.path.clip.intersect.html, and others.
226
227         * platform/graphics/chromium/GLES2Canvas.cpp:
228         (WebCore::PathAndTransform::PathAndTransform):
229         New structure to keep track of the CTM at the time the clipping path was added.
230         (WebCore::GLES2Canvas::State::State):
231         Replace m_clippingEnabled with a count of total clipping paths.
232         (WebCore::GLES2Canvas::clearRect):
233         Check the total clipping path count, instead of m_clippingEnabled.
234         (WebCore::GLES2Canvas::fillPath):
235         (WebCore::GLES2Canvas::fillRect):
236         Perform state application after doing shadows.  This is necessary
237         since restore() may now leave clipping enabled.
238         (WebCore::GLES2Canvas::clipPath):
239         Explicitly specify the stencil operation as INCR.  Store the current
240         transformation when saving clipping paths.
241         (WebCore::GLES2Canvas::restore):
242         Don't clear the stencil buffer and re-draw active paths on each restore.
243         Erase the old paths with DECR.
244         (WebCore::GLES2Canvas::drawTexturedRect):
245         Check m_numClippingPaths instead of m_clippingEnabled.
246         (WebCore::GLES2Canvas::beginShadowDraw):
247         Perform state application when drawing hard shadows.
248         (WebCore::GLES2Canvas::endShadowDraw):
249         Check m_numClippingPaths instead of m_clippingEnabled.
250         (WebCore::GLES2Canvas::beginStencilDraw):
251         Make the stencil op a parameter to beginShadowDraw().
252         (WebCore::GLES2Canvas::applyClipping):
253         Compare against the total number of stencil paths, not just the ones in
254         the current state.
255         * platform/graphics/chromium/GLES2Canvas.h:
256         Make the stencil op a parameter to beginShadowDraw().
257
258 2011-03-29  Dimitri Glazkov  <dglazkov@chromium.org>
259
260         Reviewed by Darin Adler.
261
262         Move factory-like things in EventDispatcher::dispatchMouseEvent to a factory, clean up names and ordering.
263         https://bugs.webkit.org/show_bug.cgi?id=57419
264
265         Refactoring, covered by existing tests.
266
267         * dom/EventDispatcher.cpp:
268         (WebCore::EventDispatcher::dispatchMouseEvent): Reordered and clarified names.
269         * dom/MouseEvent.cpp:
270         (WebCore::MouseEvent::create): Added a new factory method that takes PlatformMouseEvent.
271         * dom/MouseEvent.h: Added decl.
272
273 2011-03-30  Erik Arvidsson  <arv@chromium.org>
274
275         Reviewed by Alexey Proskuryakov.
276
277         Missing DOM bindings for a ping
278         https://bugs.webkit.org/show_bug.cgi?id=51955
279
280         Test: fast/dom/ping-attribute-dom-binding.html
281
282         * html/HTMLAnchorElement.idl:
283         * html/HTMLAreaElement.idl:
284
285 2011-03-30  Martin Robinson  <mrobinson@igalia.com>
286
287         Reviewed by Dirk Schulze.
288
289         [Cairo] Better separate the concerns of GraphicsContextCairo
290         https://bugs.webkit.org/show_bug.cgi?id=55150
291
292         Add a PlatformContextCairo which right now stores the cairo_t* for a
293         GraphicsContextCairo. Later patches will move logic for tracking ContextShadow
294         and image masking layers into this PlatformContextCairo class.
295
296         No new tests. This patch is only a code cleanup.
297
298         * GNUmakefile.am:
299         * platform/graphics/GraphicsContext.h: The platform context is no longer a
300         cairo_t, but our new class the PlatformContextCairo.
301         * platform/graphics/cairo/ContextShadowCairo.cpp: Updated to reflect new class.j
302         * platform/graphics/cairo/FontCairo.cpp: Ditto.
303         * platform/graphics/cairo/GradientCairo.cpp: Ditto.
304         * platform/graphics/cairo/GraphicsContextCairo.cpp: Mostly mechanical
305         changes which now reference platformContext()->cr() to get the cairo_t.
306         * platform/graphics/cairo/GraphicsContextPlatformPrivateCairo.h: Now hold the
307         PlatformContextCairo instead of the cairo_t.
308         * platform/graphics/cairo/ImageBufferCairo.cpp: Update to reflect new class.
309         * platform/graphics/cairo/ImageCairo.cpp: Ditto.
310         * platform/graphics/cairo/PathCairo.cpp: Ditto.
311         * platform/graphics/cairo/PlatformContextCairo.cpp: Added.
312         * platform/graphics/cairo/PlatformContextCairo.h: Added.
313         * platform/graphics/gtk/FontGtk.cpp: Update to reflect new class.
314         * platform/graphics/gtk/IconGtk.cpp: Ditto.
315         * platform/graphics/win/GraphicsContextCairoWin.cpp: Now fill out
316         m_data with a private section containing the platform context instead of
317         just a cairo_t.
318         * platform/gtk/RenderThemeGtk.cpp: Update to reflect new class.
319         * platform/gtk/WidgetRenderingContext.cpp: Ditto.
320         (WebCore::WidgetRenderingContext::~WidgetRenderingContext): Ditto.
321         * plugins/gtk/PluginViewGtk.cpp: Ditto.
322
323 2011-03-30  Patrick Gansterer  <paroga@webkit.org>
324
325         Unreviewed WinCE build fix for r82465.
326
327         * CMakeListsWinCE.txt:
328
329 2011-03-30  Steve Falkenburg  <sfalken@apple.com>
330
331         Reviewed by Adam Roben.
332
333         Update Windows production build logic for new production configurations
334         https://bugs.webkit.org/show_bug.cgi?id=57494
335
336         * WebCore.vcproj/QTMovieWinProduction.vsprops:
337         * WebCore.vcproj/WebCore.make:
338         * WebCore.vcproj/WebCoreProduction.vsprops:
339
340 2011-03-30  Sam Weinig  <sam@webkit.org>
341
342         Reviewed by Brady Eidson.
343
344         WebKit2: Attempting to view css file from url causes it to download
345         <rdar://problem/9102611>
346         https://bugs.webkit.org/show_bug.cgi?id=57501
347
348         * WebCore.exp.in:
349         * platform/MIMETypeRegistry.cpp:
350         (WebCore::initializeUnsupportedTextMIMETypes):
351         (WebCore::initializeMIMETypeRegistry):
352         (WebCore::MIMETypeRegistry::isUnsupportedTextMIMEType):
353         (WebCore::MIMETypeRegistry::getUnsupportedTextMIMETypes):
354         * platform/MIMETypeRegistry.h:
355         Add set of unsupported text MIME types, taken from WebKit/mac.
356
357 2011-03-30  Brian Weinstein  <bweinstein@apple.com>
358
359         Reviewed by Darin Adler.
360         
361         Crash when closing "Add Bookmark" dialog using the Enter Key
362         https://bugs.webkit.org/show_bug.cgi?id=57294
363         <rdar://problem/9044756>
364
365         Protect the FrameView in EventHandler::keyEvent, like we do in other EventHandler
366         functions that could destroy the frame.
367
368         * page/EventHandler.cpp:
369         (WebCore::EventHandler::keyEvent):
370
371 2011-03-30  Sheriff Bot  <webkit.review.bot@gmail.com>
372
373         Unreviewed, rolling out r82463.
374         http://trac.webkit.org/changeset/82463
375         https://bugs.webkit.org/show_bug.cgi?id=57482
376
377         Assertion failure in Node::rendererIsEditable on multiple
378         editing tests (Requested by aroben|meeting on #webkit).
379
380         * css/CSSParser.cpp:
381         (WebCore::CSSParser::parseValue):
382         * css/CSSPrimitiveValueMappings.h:
383         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
384         (WebCore::CSSPrimitiveValue::operator EUnicodeBidi):
385         * css/CSSValueKeywords.in:
386         * rendering/style/RenderStyle.h:
387         * rendering/style/RenderStyleConstants.h:
388
389 2011-03-24  Luiz Agostini  <luiz.agostini@openbossa.org>
390
391         Reviewed by Kenneth Rohde Christiansen.
392
393         [Qt] QNetworkReplyHandler refactoring: signal sequence.
394         https://bugs.webkit.org/show_bug.cgi?id=57049
395
396         This is the first step in QNetworkReplyHandler. The main objective here is to create simple invariants:
397
398             1 - that the signals metadatachanged, readyRead and finished will come in this order.
399             2 - that signals metadatachanged and finished will be called exactly once.
400
401         Having these invariants further simplifications will be possible and will come in future patches.
402
403         Class QNetworkReplyWrapper was created to handle QNetworkReply object. To connect to the signals of it
404         instead of connecting to the signals of QNetworkReply is what guarantees the sequence of the signals.
405         QNetworkReplyWrapper will be used in future to perform mime type sniffing before sending
406         metadatachanged signal.
407
408         * platform/network/qt/QNetworkReplyHandler.cpp:
409         (WebCore::QNetworkReplyWrapper::QNetworkReplyWrapper):
410         (WebCore::QNetworkReplyWrapper::~QNetworkReplyWrapper):
411         (WebCore::QNetworkReplyWrapper::release):
412         (WebCore::QNetworkReplyWrapper::resetConnections):
413         (WebCore::QNetworkReplyWrapper::receiveMetaData):
414         (WebCore::QNetworkReplyWrapper::didReceiveFinished):
415         (WebCore::QNetworkReplyHandler::QNetworkReplyHandler):
416         (WebCore::QNetworkReplyHandler::resetState):
417         (WebCore::QNetworkReplyHandler::release):
418         (WebCore::QNetworkReplyHandler::finish):
419         (WebCore::QNetworkReplyHandler::sendResponseIfNeeded):
420         (WebCore::QNetworkReplyHandler::redirect):
421         (WebCore::QNetworkReplyHandler::forwardData):
422         (WebCore::QNetworkReplyHandler::sendNetworkRequest):
423         (WebCore::QNetworkReplyHandler::start):
424         * platform/network/qt/QNetworkReplyHandler.h:
425         (WebCore::QNetworkReplyWrapper::reply):
426         (WebCore::QNetworkReplyWrapper::redirectionTargetUrl):
427         (WebCore::QNetworkReplyWrapper::encoding):
428         (WebCore::QNetworkReplyWrapper::advertisedMimeType):
429         (WebCore::QNetworkReplyHandler::reply):
430
431 2011-03-30  Steve Falkenburg  <sfalken@apple.com>
432
433         Reviewed by Adam Roben.
434
435         Rename Windows configuration Release_LTCG to Production for clarity
436         https://bugs.webkit.org/show_bug.cgi?id=57465
437
438         * WebCore.vcproj/QTMovieWin.vcproj:
439         * WebCore.vcproj/QTMovieWinProduction.vsprops: Copied from Source/WebCore/WebCore.vcproj/QTMovieWinReleaseLTCG.vsprops.
440         * WebCore.vcproj/QTMovieWinReleaseLTCG.vsprops: Removed.
441         * WebCore.vcproj/WebCore.sln:
442         * WebCore.vcproj/WebCore.submit.sln:
443         * WebCore.vcproj/WebCore.vcproj:
444         * WebCore.vcproj/WebCoreGenerated.vcproj:
445         * WebCore.vcproj/WebCoreProduction.vsprops: Copied from Source/WebCore/WebCore.vcproj/WebCoreReleaseLTCG.vsprops.
446         * WebCore.vcproj/WebCoreReleaseLTCG.vsprops: Removed.
447
448 2011-03-30  Brian Weinstein  <bweinstein@apple.com>
449
450         Reviewed by Anders Carlsson.
451         
452         ASSERT(cookieStorageAdapter) when calling stopObservingCookieChanges after WebProcess has crashed
453         https://bugs.webkit.org/show_bug.cgi?id=57477
454         <rdar://problem/9178751>
455         
456         If someone has called startObservingCookieChanges, and the WebProcess crashes and restarts, the UIProcess
457         will call stopObservingCookieChanges when cookieStorageAdapter is nil.
458         
459         The assert is wrong when the web process crashes, and there is no harm in dispatching a message to nil,
460         so remove the assert.
461         
462         * platform/network/mac/CookieStorageMac.mm:
463         (WebCore::stopObservingCookieChanges):
464
465 2011-03-30  Sam Weinig  <sam@webkit.org>
466
467         Fix Leopard build.
468
469         * platform/DefaultLocalizationStrategy.cpp:
470         (WebCore::DefaultLocalizationStrategy::contextMenuItemTagLookUpInDictionary):
471
472 2011-03-30  Sam Weinig  <sam@webkit.org>
473
474         Reviewed by Anders Carlsson.
475
476         Add default localization strategy that can be shared by WebKit1 and WebKit2
477         https://bugs.webkit.org/show_bug.cgi?id=57406
478
479         Currently, only WebKit2 uses this default strategy, but WebKit1 should be able
480         to adopt it soon.
481
482         * platform/DefaultLocalizationStrategy.cpp: Copied from Source/WebKit2/WebProcess/WebCoreSupport/WebPlatformStrategies.cpp.
483         (WebCore::DefaultLocalizationStrategy::DefaultLocalizationStrategy):
484         * platform/DefaultLocalizationStrategy.h: Copied from Source/WebKit2/WebProcess/WebCoreSupport/WebPlatformStrategies.h.
485         Copy the implementation of the Localization strategy from WebKit2 into a shared default strategy.
486
487         * platform/LocalizedStrings.cpp:
488         (WebCore::localizedString):
489         Add default implementation of localization bottleneck function.
490
491         * platform/LocalizedStrings.h:
492         Add localization macros here, instead of defining them in the above layer.
493
494         * platform/PlatformStrategies.cpp:
495         (WebCore::PlatformStrategies::createLocalizationStrategy):
496         * platform/PlatformStrategies.h:
497         Add default implementation of strategy creation function which creates the default strategy.
498
499         * platform/win/LocalizedStringsWin.cpp: Copied from Source/WebCore/platform/mac/LocalizedStringsMac.mm.
500         (WebCore::localizedString):
501         Add stub for windows, this will be update to pull from the bundle in a follow up patch.
502
503         * Android.mk:
504         * CMakeLists.txt:
505         * GNUmakefile.am:
506         * WebCore.exp.in:
507         * WebCore.gypi:
508         * WebCore.pro:
509         * WebCore.vcproj/WebCore.vcproj:
510         * WebCore.xcodeproj/project.pbxproj:
511         Add new files.
512
513 2011-03-30  Andras Becsi  <abecsi@webkit.org>
514
515         Reviewed by Darin Adler.
516
517         CSS: Slow parsing of rgb() with percent values
518         https://bugs.webkit.org/show_bug.cgi?id=16708
519
520         Implement fast-path parsing for percentage color values.
521
522         Gain ~30% speedup on  http://canvex.lazyilluminati.com/misc/3d.html
523
524         Relanding with rounding fix after it was rolled out in r82315.
525
526         * css/CSSParser.cpp:
527         (WebCore::checkForValidDouble): Extend to return the number of characters forming a valid double.
528         (WebCore::parseDouble): Function for parsing double values if they are valid.
529         (WebCore::parseColorIntOrPercentage): Extend parseColorInt to deal with percentage values.
530         (WebCore::parseAlphaValue): Use the new functions.
531         (WebCore::CSSParser::parseColor): Ditto.
532
533 2011-03-30  Ofri Wolfus  <ofri@dhcp-172-28-40-178.tlv.corp.google.com>
534
535         Reviewed by Eric Seidel.
536
537         Add support for parsing unicode-bidi: -webkit-plaintext.
538         https://bugs.webkit.org/show_bug.cgi?id=57457
539
540         Test: css3/unicode-bidi-plaintext-parse.html
541
542         * css/CSSParser.cpp:
543         (WebCore::CSSParser::parseValue):
544         * css/CSSPrimitiveValueMappings.h:
545         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
546         (WebCore::CSSPrimitiveValue::operator EUnicodeBidi):
547         * css/CSSValueKeywords.in:
548         * rendering/style/RenderStyle.h:
549         * rendering/style/RenderStyleConstants.h:
550
551 2011-03-30  Andreas Kling  <kling@webkit.org>
552
553         Reviewed by Benjamin Poulain.
554
555         [Qt] Remove unused variables in GraphicsContext::fillRect()
556
557         * platform/graphics/qt/GraphicsContextQt.cpp:
558         (WebCore::GraphicsContext::fillRect):
559
560 2011-03-30  Yael Aharon  <yael.aharon@nokia.com>
561
562         Reviewed by Eric Seidel.
563
564         REGRESSION(r82419): New pixel test failure fast/box-shadow/basic-shadows.html
565         https://bugs.webkit.org/show_bug.cgi?id=57442
566
567         When checking the position of the inline iterator in the logicallyLastRun, we should not consider BR as text.
568
569         No new tests as existing test covers this case.
570
571         * rendering/RenderBlockLineLayout.cpp:
572         (WebCore::reachedEndOfTextRenderer):
573
574 2011-03-30  Mario Sanchez Prada  <msanchez@igalia.com>
575
576         Reviewed by Chris Fleizach.
577
578         AX: GTK: ARIA role is not respected on <p> <label> <div> and <form>
579         https://bugs.webkit.org/show_bug.cgi?id=47636
580
581         Define new roles in WebCore and map them to ATK accordingly.
582
583         Test: platform/gtk/accessibility/aria-roles-unignored.html
584
585         * accessibility/AccessibilityObject.h: Added new roles to
586         represent paragraphs, labels, forms and div sections.
587         * accessibility/AccessibilityRenderObject.cpp:
588         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
589         Return ParagraphRole, LabelRole, FormRole and DivRole when needed
590         for the GTK platform only.
591         * accessibility/gtk/AccessibilityObjectAtk.cpp:
592         (WebCore::AccessibilityObject::allowsTextRanges): Consider the new
593         roles now that those kind of nodes won't return true to isGroup().
594         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
595         (atkRole): Map new WebCore roles to ATK Roles.
596         (webkit_accessible_get_role): Remove code to define roles for
597         paragraphs, labels, forms and divs based on node's tag name.
598
599         Update mappings for the Mac platform.
600
601         * accessibility/mac/AccessibilityObjectWrapper.mm:
602         (createAccessibilityRoleMap): Add explicit mappings from the new
603         roles introduced to NSAccessibilityGroupRole.
604
605 2011-03-30  Yury Semikhatsky  <yurys@chromium.org>
606
607         Unreviewed. Build fix for Efl and Qt Win.
608
609         * inspector/PageDebuggerAgent.cpp: removed ENABLE(WORKERS) guard from code that has nothing to do with workers.
610
611 2011-03-30  Andrey Kosyakov  <caseq@chromium.org>
612
613         Reviewed by Pavel Feldman.
614
615         Web Inspector: audit run never completes, fails in DOMAgent.js
616         https://bugs.webkit.org/show_bug.cgi?id=57349
617
618         - assure document is present before calling DOMAgent.querySelectAll()
619
620         * inspector/front-end/AuditRules.js:
621         (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun):
622
623 2011-03-30  Yury Semikhatsky  <yurys@chromium.org>
624
625         Unreviewed. Build fix.
626
627         * UseJSC.cmake: fix typo PageDebugServer -> PageScriptDebugServer
628
629 2011-03-30  Yury Semikhatsky  <yurys@chromium.org>
630
631         Reviewed by Pavel Feldman.
632
633         Web Inspector: split debugger agent into Page and Worker-specific ones
634         https://bugs.webkit.org/show_bug.cgi?id=57345
635
636         ScriptDebugServer and InspectorDebuggerAgent contain only functionality common
637         for Worker and Page debugger. All specifics is moved into Page/WorkerScriptDebugServer
638         and Page/WorkerDebuggerAgent.
639
640         * CMakeLists.txt:
641         * GNUmakefile.am:
642         * UseJSC.cmake:
643         * WebCore.gypi:
644         * WebCore.pro:
645         * WebCore.vcproj/WebCore.vcproj:
646         * WebCore.xcodeproj/project.pbxproj:
647         * bindings/js/JSBindingsAllInOne.cpp:
648         * bindings/js/JSInjectedScriptHostCustom.cpp:
649         (WebCore::JSInjectedScriptHost::currentCallFrame):
650         * bindings/js/PageScriptDebugServer.cpp: Added.
651         (WebCore::toPage):
652         (WebCore::PageScriptDebugServer::shared):
653         (WebCore::PageScriptDebugServer::PageScriptDebugServer):
654         (WebCore::PageScriptDebugServer::~PageScriptDebugServer):
655         (WebCore::PageScriptDebugServer::addListener):
656         (WebCore::PageScriptDebugServer::removeListener):
657         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
658         (WebCore::PageScriptDebugServer::getListenersForGlobalObject):
659         (WebCore::PageScriptDebugServer::didPause):
660         (WebCore::PageScriptDebugServer::didContinue):
661         (WebCore::PageScriptDebugServer::didRemoveLastListener):
662         (WebCore::PageScriptDebugServer::setJavaScriptPaused):
663         * bindings/js/PageScriptDebugServer.h: Added.
664         * bindings/js/ScriptDebugServer.cpp:
665         (WebCore::ScriptDebugServer::ScriptDebugServer):
666         (WebCore::ScriptDebugServer::sourceParsed):
667         (WebCore::ScriptDebugServer::dispatchFunctionToListeners):
668         (WebCore::ScriptDebugServer::createCallFrameAndPauseIfNeeded):
669         (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
670         (WebCore::ScriptDebugServer::pauseIfNeeded):
671         * bindings/js/ScriptDebugServer.h:
672         * bindings/js/WorkerScriptDebugServer.cpp: Added.
673         (WebCore::WorkerScriptDebugServer::WorkerScriptDebugServer):
674         (WebCore::WorkerScriptDebugServer::addListener):
675         (WebCore::WorkerScriptDebugServer::removeListener):
676         * bindings/js/WorkerScriptDebugServer.h: Added.
677         (WebCore::WorkerScriptDebugServer::~WorkerScriptDebugServer):
678         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
679         (WebCore::WorkerScriptDebugServer::getListenersForGlobalObject):
680         (WebCore::WorkerScriptDebugServer::didPause):
681         (WebCore::WorkerScriptDebugServer::didContinue):
682         * bindings/v8/PageScriptDebugServer.cpp: Added.
683         (WebCore::retrieveFrame):
684         (WebCore::PageScriptDebugServer::shared):
685         (WebCore::PageScriptDebugServer::PageScriptDebugServer):
686         (WebCore::PageScriptDebugServer::addListener):
687         (WebCore::PageScriptDebugServer::removeListener):
688         (WebCore::PageScriptDebugServer::setClientMessageLoop):
689         (WebCore::PageScriptDebugServer::getDebugListenerForContext):
690         (WebCore::PageScriptDebugServer::runMessageLoopOnPause):
691         (WebCore::PageScriptDebugServer::quitMessageLoopOnPause):
692         * bindings/v8/PageScriptDebugServer.h: Added.
693         (WebCore::PageScriptDebugServer::setEnabled):
694         (WebCore::PageScriptDebugServer::ClientMessageLoop::~ClientMessageLoop):
695         (WebCore::PageScriptDebugServer::~PageScriptDebugServer):
696         * bindings/v8/ScriptDebugServer.cpp:
697         (WebCore::ScriptDebugServer::ScriptDebugServer):
698         (WebCore::ScriptDebugServer::setPauseOnNextStatement):
699         (WebCore::ScriptDebugServer::breakProgram):
700         (WebCore::ScriptDebugServer::continueProgram):
701         (WebCore::ScriptDebugServer::stepIntoStatement):
702         (WebCore::ScriptDebugServer::stepOverStatement):
703         (WebCore::ScriptDebugServer::stepOutOfFunction):
704         (WebCore::ScriptDebugServer::editScriptSource):
705         (WebCore::toScriptDebugServer):
706         (WebCore::ScriptDebugServer::breakProgramCallback):
707         (WebCore::ScriptDebugServer::v8DebugEventCallback):
708         (WebCore::ScriptDebugServer::handleV8DebugEvent):
709         (WebCore::ScriptDebugServer::isPaused):
710         * bindings/v8/ScriptDebugServer.h:
711         * bindings/v8/WorkerScriptDebugServer.cpp: Added.
712         (WebCore::WorkerScriptDebugServer::WorkerScriptDebugServer):
713         (WebCore::WorkerScriptDebugServer::addListener):
714         (WebCore::WorkerScriptDebugServer::removeListener):
715         * bindings/v8/WorkerScriptDebugServer.h: Added.
716         (WebCore::WorkerScriptDebugServer::~WorkerScriptDebugServer):
717         (WebCore::WorkerScriptDebugServer::getDebugListenerForContext):
718         (WebCore::WorkerScriptDebugServer::runMessageLoopOnPause):
719         (WebCore::WorkerScriptDebugServer::quitMessageLoopOnPause):
720         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
721         (WebCore::V8InjectedScriptHost::currentCallFrameCallback):
722         * inspector/InjectedScriptHost.h:
723         (WebCore::InjectedScriptHost::init):
724         (WebCore::InjectedScriptHost::debuggerAgent):
725         * inspector/InspectorAgent.cpp:
726         (WebCore::InspectorAgent::InspectorAgent):
727         * inspector/InspectorDebuggerAgent.cpp:
728         (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent):
729         (WebCore::InspectorDebuggerAgent::enable):
730         (WebCore::InspectorDebuggerAgent::disable):
731         (WebCore::InspectorDebuggerAgent::setBreakpointsActive):
732         (WebCore::InspectorDebuggerAgent::removeBreakpoint):
733         (WebCore::InspectorDebuggerAgent::continueToLocation):
734         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
735         (WebCore::InspectorDebuggerAgent::editScriptSource):
736         (WebCore::InspectorDebuggerAgent::schedulePauseOnNextStatement):
737         (WebCore::InspectorDebuggerAgent::cancelPauseOnNextStatement):
738         (WebCore::InspectorDebuggerAgent::resume):
739         (WebCore::InspectorDebuggerAgent::stepOver):
740         (WebCore::InspectorDebuggerAgent::stepInto):
741         (WebCore::InspectorDebuggerAgent::stepOut):
742         (WebCore::InspectorDebuggerAgent::setPauseOnExceptionsState):
743         (WebCore::InspectorDebuggerAgent::didPause):
744         (WebCore::InspectorDebuggerAgent::breakProgram):
745         * inspector/InspectorDebuggerAgent.h:
746         * inspector/InspectorProfilerAgent.cpp:
747         (WebCore::InspectorProfilerAgent::disable):
748         (WebCore::InspectorProfilerAgent::enable):
749         (WebCore::InspectorProfilerAgent::startUserInitiatedProfiling):
750         * inspector/PageDebuggerAgent.cpp: Added.
751         (WebCore::PageDebuggerAgent::create):
752         (WebCore::PageDebuggerAgent::PageDebuggerAgent):
753         (WebCore::PageDebuggerAgent::~PageDebuggerAgent):
754         (WebCore::PageDebuggerAgent::startListeningScriptDebugServer):
755         (WebCore::PageDebuggerAgent::stopListeningScriptDebugServer):
756         (WebCore::PageDebuggerAgent::scriptDebugServer):
757         * inspector/PageDebuggerAgent.h: Added.
758         * inspector/WorkerDebuggerAgent.cpp: Added.
759         (WebCore::WorkerDebuggerAgent::create):
760         (WebCore::WorkerDebuggerAgent::WorkerDebuggerAgent):
761         (WebCore::WorkerDebuggerAgent::~WorkerDebuggerAgent):
762         (WebCore::WorkerDebuggerAgent::startListeningScriptDebugServer):
763         (WebCore::WorkerDebuggerAgent::stopListeningScriptDebugServer):
764         (WebCore::WorkerDebuggerAgent::scriptDebugServer):
765         * inspector/WorkerDebuggerAgent.h: Added.
766
767 2011-03-30  Levi Weintraub  <leviw@chromium.org>
768
769         Reviewed by Ryosuke Niwa.
770
771         Clicking below last line of right-to-left editable text that puts caret in the wrong place
772         https://bugs.webkit.org/show_bug.cgi?id=38087
773
774         Moving getLogical[Start/End]BoxWithNode to RootInlineBox and using it in positionForPointWithInlineChildren
775         instead of lastLeafChild, which wasn't correct in the RTL case.
776
777         Test: editing/selection/click-below-rtl-text.html
778
779         * editing/visible_units.cpp:
780         (WebCore::logicalStartPositionForLine): Moved to RootInlineBox.
781         (WebCore::logicalEndPositionForLine): Ditto.
782         * editing/visible_units.h:
783         * rendering/RenderBlock.cpp:
784         (WebCore::RenderBlock::positionForPointWithInlineChildren): Useing getLogicalEndBoxWithNode instead
785         of lastLeafChild.
786         * rendering/RootInlineBox.cpp:
787         (WebCore::RootInlineBox::getLogicalStartBoxWithNode): Moved and refactored.
788         (WebCore::RootInlineBox::getLogicalEndBoxWithNode): Ditto.
789         * rendering/RootInlineBox.h:
790
791 2011-03-30  Yury Semikhatsky  <yurys@chromium.org>
792
793         Unreviewed. Rollout r82438 and r82436.
794
795         * CMakeLists.txt:
796         * GNUmakefile.am:
797         * UseJSC.cmake:
798         * WebCore.gypi:
799         * WebCore.pro:
800         * WebCore.vcproj/WebCore.vcproj:
801         * WebCore.xcodeproj/project.pbxproj:
802         * bindings/js/JSBindingsAllInOne.cpp:
803         * bindings/js/JSInjectedScriptHostCustom.cpp:
804         (WebCore::JSInjectedScriptHost::currentCallFrame):
805         * bindings/js/PageScriptDebugServer.cpp: Removed.
806         * bindings/js/PageScriptDebugServer.h: Removed.
807         * bindings/js/ScriptDebugServer.cpp:
808         (WebCore::ScriptDebugServer::shared):
809         (WebCore::ScriptDebugServer::ScriptDebugServer):
810         (WebCore::ScriptDebugServer::addListener):
811         (WebCore::ScriptDebugServer::removeListener):
812         (WebCore::ScriptDebugServer::hasListenersInterestedInPage):
813         (WebCore::toPage):
814         (WebCore::ScriptDebugServer::sourceParsed):
815         (WebCore::ScriptDebugServer::dispatchFunctionToListeners):
816         (WebCore::ScriptDebugServer::setJavaScriptPaused):
817         (WebCore::ScriptDebugServer::createCallFrameAndPauseIfNeeded):
818         (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
819         (WebCore::ScriptDebugServer::pauseIfNeeded):
820         (WebCore::ScriptDebugServer::recompileAllJSFunctions):
821         (WebCore::ScriptDebugServer::didAddListener):
822         (WebCore::ScriptDebugServer::didRemoveListener):
823         * bindings/js/ScriptDebugServer.h:
824         * bindings/js/WorkerScriptDebugServer.cpp: Removed.
825         * bindings/js/WorkerScriptDebugServer.h: Removed.
826         * bindings/v8/PageScriptDebugServer.cpp: Removed.
827         * bindings/v8/PageScriptDebugServer.h: Removed.
828         * bindings/v8/ScriptDebugServer.cpp:
829         (WebCore::retrieveFrame):
830         (WebCore::ScriptDebugServer::shared):
831         (WebCore::ScriptDebugServer::ScriptDebugServer):
832         (WebCore::ScriptDebugServer::addListener):
833         (WebCore::ScriptDebugServer::removeListener):
834         (WebCore::ScriptDebugServer::setPauseOnNextStatement):
835         (WebCore::ScriptDebugServer::breakProgram):
836         (WebCore::ScriptDebugServer::continueProgram):
837         (WebCore::ScriptDebugServer::stepIntoStatement):
838         (WebCore::ScriptDebugServer::stepOverStatement):
839         (WebCore::ScriptDebugServer::stepOutOfFunction):
840         (WebCore::ScriptDebugServer::editScriptSource):
841         (WebCore::ScriptDebugServer::setEnabled):
842         (WebCore::ScriptDebugServer::breakProgramCallback):
843         (WebCore::ScriptDebugServer::v8DebugEventCallback):
844         (WebCore::ScriptDebugServer::handleV8DebugEvent):
845         (WebCore::ScriptDebugServer::didResume):
846         * bindings/v8/ScriptDebugServer.h:
847         (WebCore::ScriptDebugServer::pageCreated):
848         (WebCore::ScriptDebugServer::ClientMessageLoop::~ClientMessageLoop):
849         (WebCore::ScriptDebugServer::setClientMessageLoop):
850         * bindings/v8/WorkerScriptDebugServer.cpp: Removed.
851         * bindings/v8/WorkerScriptDebugServer.h: Removed.
852         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
853         (WebCore::V8InjectedScriptHost::currentCallFrameCallback):
854         * inspector/InjectedScriptHost.h:
855         (WebCore::InjectedScriptHost::init):
856         * inspector/InspectorAgent.cpp:
857         (WebCore::InspectorAgent::InspectorAgent):
858         * inspector/InspectorDebuggerAgent.cpp:
859         (WebCore::InspectorDebuggerAgent::create):
860         (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent):
861         (WebCore::InspectorDebuggerAgent::enable):
862         (WebCore::InspectorDebuggerAgent::disable):
863         (WebCore::InspectorDebuggerAgent::setBreakpointsActive):
864         (WebCore::InspectorDebuggerAgent::removeBreakpoint):
865         (WebCore::InspectorDebuggerAgent::continueToLocation):
866         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
867         (WebCore::InspectorDebuggerAgent::editScriptSource):
868         (WebCore::InspectorDebuggerAgent::schedulePauseOnNextStatement):
869         (WebCore::InspectorDebuggerAgent::cancelPauseOnNextStatement):
870         (WebCore::InspectorDebuggerAgent::resume):
871         (WebCore::InspectorDebuggerAgent::stepOver):
872         (WebCore::InspectorDebuggerAgent::stepInto):
873         (WebCore::InspectorDebuggerAgent::stepOut):
874         (WebCore::InspectorDebuggerAgent::setPauseOnExceptionsState):
875         (WebCore::InspectorDebuggerAgent::didPause):
876         (WebCore::InspectorDebuggerAgent::breakProgram):
877         * inspector/InspectorDebuggerAgent.h:
878         * inspector/InspectorProfilerAgent.cpp:
879         (WebCore::InspectorProfilerAgent::disable):
880         (WebCore::InspectorProfilerAgent::enable):
881         (WebCore::InspectorProfilerAgent::startUserInitiatedProfiling):
882         * inspector/PageDebuggerAgent.cpp: Removed.
883         * inspector/PageDebuggerAgent.h: Removed.
884         * inspector/WorkerDebuggerAgent.cpp: Removed.
885         * inspector/WorkerDebuggerAgent.h: Removed.
886
887 2011-03-30  Yury Semikhatsky  <yurys@chromium.org>
888
889         Unreviewed. Fix compilation on Windows and EFL.
890
891         * CMakeLists.txt:
892         * bindings/js/JSBindingsAllInOne.cpp:
893
894 2011-03-30  Yury Semikhatsky  <yurys@chromium.org>
895
896         Reviewed by Pavel Feldman.
897
898         Web Inspector: split debugger agent into Page and Worker-specific ones
899         https://bugs.webkit.org/show_bug.cgi?id=57345
900
901         ScriptDebugServer and InspectorDebuggerAgent contain only functionality common
902         for Worker and Page debugger. All specifics is moved into Page/WorkerScriptDebugServer
903         and Page/WorkerDebuggerAgent.
904
905         * GNUmakefile.am:
906         * UseJSC.cmake:
907         * WebCore.gypi:
908         * WebCore.pro:
909         * WebCore.vcproj/WebCore.vcproj:
910         * WebCore.xcodeproj/project.pbxproj:
911         * bindings/js/JSInjectedScriptHostCustom.cpp:
912         (WebCore::JSInjectedScriptHost::currentCallFrame):
913         * bindings/js/PageScriptDebugServer.cpp: Added.
914         (WebCore::toPage):
915         (WebCore::PageScriptDebugServer::shared):
916         (WebCore::PageScriptDebugServer::PageScriptDebugServer):
917         (WebCore::PageScriptDebugServer::~PageScriptDebugServer):
918         (WebCore::PageScriptDebugServer::addListener):
919         (WebCore::PageScriptDebugServer::removeListener):
920         (WebCore::PageScriptDebugServer::recompileAllJSFunctions):
921         (WebCore::PageScriptDebugServer::getListenersForGlobalObject):
922         (WebCore::PageScriptDebugServer::didPause):
923         (WebCore::PageScriptDebugServer::didContinue):
924         (WebCore::PageScriptDebugServer::didRemoveLastListener):
925         (WebCore::PageScriptDebugServer::setJavaScriptPaused):
926         * bindings/js/PageScriptDebugServer.h: Added.
927         * bindings/js/ScriptDebugServer.cpp:
928         (WebCore::ScriptDebugServer::ScriptDebugServer):
929         (WebCore::ScriptDebugServer::sourceParsed):
930         (WebCore::ScriptDebugServer::dispatchFunctionToListeners):
931         (WebCore::ScriptDebugServer::createCallFrameAndPauseIfNeeded):
932         (WebCore::ScriptDebugServer::updateCallFrameAndPauseIfNeeded):
933         (WebCore::ScriptDebugServer::pauseIfNeeded):
934         * bindings/js/ScriptDebugServer.h:
935         * bindings/js/WorkerScriptDebugServer.cpp: Added.
936         (WebCore::WorkerScriptDebugServer::WorkerScriptDebugServer):
937         (WebCore::WorkerScriptDebugServer::addListener):
938         (WebCore::WorkerScriptDebugServer::removeListener):
939         * bindings/js/WorkerScriptDebugServer.h: Added.
940         (WebCore::WorkerScriptDebugServer::~WorkerScriptDebugServer):
941         (WebCore::WorkerScriptDebugServer::recompileAllJSFunctions):
942         (WebCore::WorkerScriptDebugServer::getListenersForGlobalObject):
943         (WebCore::WorkerScriptDebugServer::didPause):
944         (WebCore::WorkerScriptDebugServer::didContinue):
945         * bindings/v8/PageScriptDebugServer.cpp: Added.
946         (WebCore::retrieveFrame):
947         (WebCore::PageScriptDebugServer::shared):
948         (WebCore::PageScriptDebugServer::PageScriptDebugServer):
949         (WebCore::PageScriptDebugServer::addListener):
950         (WebCore::PageScriptDebugServer::removeListener):
951         (WebCore::PageScriptDebugServer::setClientMessageLoop):
952         (WebCore::PageScriptDebugServer::getDebugListenerForContext):
953         (WebCore::PageScriptDebugServer::runMessageLoopOnPause):
954         (WebCore::PageScriptDebugServer::quitMessageLoopOnPause):
955         * bindings/v8/PageScriptDebugServer.h: Added.
956         (WebCore::PageScriptDebugServer::setEnabled):
957         (WebCore::PageScriptDebugServer::ClientMessageLoop::~ClientMessageLoop):
958         (WebCore::PageScriptDebugServer::~PageScriptDebugServer):
959         * bindings/v8/ScriptDebugServer.cpp:
960         (WebCore::ScriptDebugServer::ScriptDebugServer):
961         (WebCore::ScriptDebugServer::setPauseOnNextStatement):
962         (WebCore::ScriptDebugServer::breakProgram):
963         (WebCore::ScriptDebugServer::continueProgram):
964         (WebCore::ScriptDebugServer::stepIntoStatement):
965         (WebCore::ScriptDebugServer::stepOverStatement):
966         (WebCore::ScriptDebugServer::stepOutOfFunction):
967         (WebCore::ScriptDebugServer::editScriptSource):
968         (WebCore::toScriptDebugServer):
969         (WebCore::ScriptDebugServer::breakProgramCallback):
970         (WebCore::ScriptDebugServer::v8DebugEventCallback):
971         (WebCore::ScriptDebugServer::handleV8DebugEvent):
972         (WebCore::ScriptDebugServer::isPaused):
973         * bindings/v8/ScriptDebugServer.h:
974         * bindings/v8/WorkerScriptDebugServer.cpp: Added.
975         (WebCore::WorkerScriptDebugServer::WorkerScriptDebugServer):
976         (WebCore::WorkerScriptDebugServer::addListener):
977         (WebCore::WorkerScriptDebugServer::removeListener):
978         * bindings/v8/WorkerScriptDebugServer.h: Added.
979         (WebCore::WorkerScriptDebugServer::~WorkerScriptDebugServer):
980         (WebCore::WorkerScriptDebugServer::getDebugListenerForContext):
981         (WebCore::WorkerScriptDebugServer::runMessageLoopOnPause):
982         (WebCore::WorkerScriptDebugServer::quitMessageLoopOnPause):
983         * bindings/v8/custom/V8InjectedScriptHostCustom.cpp:
984         (WebCore::V8InjectedScriptHost::currentCallFrameCallback):
985         * inspector/InjectedScriptHost.h:
986         (WebCore::InjectedScriptHost::init):
987         (WebCore::InjectedScriptHost::debuggerAgent):
988         * inspector/InspectorAgent.cpp:
989         (WebCore::InspectorAgent::InspectorAgent):
990         * inspector/InspectorDebuggerAgent.cpp:
991         (WebCore::InspectorDebuggerAgent::InspectorDebuggerAgent):
992         (WebCore::InspectorDebuggerAgent::enable):
993         (WebCore::InspectorDebuggerAgent::disable):
994         (WebCore::InspectorDebuggerAgent::setBreakpointsActive):
995         (WebCore::InspectorDebuggerAgent::removeBreakpoint):
996         (WebCore::InspectorDebuggerAgent::continueToLocation):
997         (WebCore::InspectorDebuggerAgent::resolveBreakpoint):
998         (WebCore::InspectorDebuggerAgent::editScriptSource):
999         (WebCore::InspectorDebuggerAgent::schedulePauseOnNextStatement):
1000         (WebCore::InspectorDebuggerAgent::cancelPauseOnNextStatement):
1001         (WebCore::InspectorDebuggerAgent::resume):
1002         (WebCore::InspectorDebuggerAgent::stepOver):
1003         (WebCore::InspectorDebuggerAgent::stepInto):
1004         (WebCore::InspectorDebuggerAgent::stepOut):
1005         (WebCore::InspectorDebuggerAgent::setPauseOnExceptionsState):
1006         (WebCore::InspectorDebuggerAgent::didPause):
1007         (WebCore::InspectorDebuggerAgent::breakProgram):
1008         * inspector/InspectorDebuggerAgent.h:
1009         * inspector/InspectorProfilerAgent.cpp:
1010         (WebCore::InspectorProfilerAgent::disable):
1011         (WebCore::InspectorProfilerAgent::enable):
1012         (WebCore::InspectorProfilerAgent::startUserInitiatedProfiling):
1013         * inspector/PageDebuggerAgent.cpp: Added.
1014         (WebCore::PageDebuggerAgent::create):
1015         (WebCore::PageDebuggerAgent::PageDebuggerAgent):
1016         (WebCore::PageDebuggerAgent::~PageDebuggerAgent):
1017         (WebCore::PageDebuggerAgent::startListeningScriptDebugServer):
1018         (WebCore::PageDebuggerAgent::stopListeningScriptDebugServer):
1019         (WebCore::PageDebuggerAgent::scriptDebugServer):
1020         * inspector/PageDebuggerAgent.h: Added.
1021         * inspector/WorkerDebuggerAgent.cpp: Added.
1022         (WebCore::WorkerDebuggerAgent::create):
1023         (WebCore::WorkerDebuggerAgent::WorkerDebuggerAgent):
1024         (WebCore::WorkerDebuggerAgent::~WorkerDebuggerAgent):
1025         (WebCore::WorkerDebuggerAgent::startListeningScriptDebugServer):
1026         (WebCore::WorkerDebuggerAgent::stopListeningScriptDebugServer):
1027         (WebCore::WorkerDebuggerAgent::scriptDebugServer):
1028         * inspector/WorkerDebuggerAgent.h: Added.
1029
1030 2011-03-30  Alexander Pavlov  <apavlov@chromium.org>
1031
1032         Reviewed by Pavel Feldman.
1033
1034         Web Inspector: Make the getStylesForNode result "styleAttributes" value an array rather than a map
1035         https://bugs.webkit.org/show_bug.cgi?id=57440
1036
1037         * inspector/InspectorCSSAgent.cpp:
1038         (WebCore::InspectorCSSAgent::getStylesForNode):
1039         (WebCore::InspectorCSSAgent::buildArrayForAttributeStyles):
1040         * inspector/InspectorCSSAgent.h:
1041         * inspector/front-end/CSSStyleModel.js:
1042         (WebInspector.CSSStyleModel.prototype.getStylesAsync):
1043
1044 2011-03-30  Evan Martin  <evan@chromium.org>
1045
1046         Reviewed by Ryosuke Niwa.
1047
1048         Fix a last-second ASSERT in previous change that was wrong.
1049
1050         * dom/Document.cpp:
1051         (WebCore::Document::setTitle):
1052
1053 2011-03-30  Levi Weintraub  <leviw@chromium.org>
1054
1055         Reviewed by Eric Seidel.
1056
1057         RTL:  Directionality always reset on hard line break
1058         https://bugs.webkit.org/show_bug.cgi?id=23124
1059
1060         No longer clearing all BidiContexts when we hit a hard line break.
1061         Instead, directionality applied by DOM elements is preserved by
1062         reconstructing the context stack ignoring those that didn't come
1063         from the DOM.
1064
1065         Test: fast/text/international/bidi-br-as-paragraph-separator.html
1066
1067         * platform/text/BidiContext.cpp:
1068         (WebCore::BidiContext::createUncached):
1069         (WebCore::BidiContext::create):
1070         (WebCore::copyContextAndRebaselineLevel): Helper to make a copy of a context
1071         and recalculate its bidi level.
1072         (WebCore::BidiContext::copyStackRemovingUnicodeEmbeddingContexts): Returns the top of
1073         a BidiContext stack that's equivalent but without contexts from Unicode directional
1074         characters.
1075         (WebCore::operator==): Now takes into account embedding source.
1076         * platform/text/BidiContext.h:
1077         (WebCore::BidiContext::source): Enum to specify whether an embedded
1078         bidirectional control came from the DOM/Style or Unicode characters
1079         (WebCore::BidiContext::BidiContext):
1080         * platform/text/BidiResolver.h:
1081         (WebCore::BidiEmbedding::BidiEmbedding): An embedding is now a direction
1082         and a hint about where it came from so we can differentiate DOM directions
1083         from unicode direction control characters.
1084         (WebCore::BidiEmbedding::direction):
1085         (WebCore::BidiEmbedding::source):
1086         (WebCore::::embed): Now takes a source as well as a direction.
1087         (WebCore::::commitExplicitEmbedding):
1088         (WebCore::::createBidiRunsForLine):
1089         * rendering/InlineIterator.h:
1090         (WebCore::bidiNext):
1091         (WebCore::bidiFirst):
1092         * rendering/RenderBlockLineLayout.cpp:
1093         (WebCore::RenderBlock::determineStartPosition):
1094
1095 2011-03-30  Steve Block  <steveblock@google.com>
1096
1097         Reviewed by Jeremy Orlow.
1098
1099         JavaMethod should not expose JavaString in its API
1100         https://bugs.webkit.org/show_bug.cgi?id=55765
1101
1102         - Factors out a JavaMethod interface which does not use JNI types.
1103           This will allow the Java bridge to be used with objects that
1104           don't use JNI directly. The existing jobject-backed
1105           implementation is moved to a new JavaMethodJobject class which
1106           implements the interface.
1107         - Use WTF::String in place of JavaString in the API, as JavaString
1108           exposes JNI types in its interface.
1109         - Remove the method ID as it uses JNI types.
1110
1111         No new tests, refactoring only.
1112
1113         * Android.jscbindings.mk:
1114         * Android.v8bindings.mk:
1115         * GNUmakefile.am:
1116         * WebCore.gypi:
1117         * WebCore.xcodeproj/project.pbxproj:
1118         * bridge/jni/JavaMethod.h:
1119         * bridge/jni/JavaMethodJobject.cpp:
1120         (JavaMethodJobject::JavaMethodJobject):
1121         (JavaMethodJobject::~JavaMethodJobject):
1122         (appendClassName):
1123         (JavaMethodJobject::signature):
1124         * bridge/jni/JavaMethodJobject.h: Copied from Source/WebCore/bridge/jni/JavaMethod.h.
1125         (JSC::Bindings::JavaMethodJobject::name):
1126         (JSC::Bindings::JavaMethodJobject::returnTypeClassName):
1127         (JSC::Bindings::JavaMethodJobject::parameterAt):
1128         (JSC::Bindings::JavaMethodJobject::returnType):
1129         (JSC::Bindings::JavaMethodJobject::isStatic):
1130         (JSC::Bindings::JavaMethodJobject::numParameters):
1131         * bridge/jni/jsc/JavaClassJSC.cpp:
1132         (JavaClass::JavaClass):
1133         * bridge/jni/jsc/JavaInstanceJSC.cpp:
1134         (JavaInstance::invokeMethod):
1135         * bridge/jni/v8/JavaClassV8.cpp:
1136         (JavaClass::JavaClass):
1137         * bridge/jni/v8/JavaInstanceV8.cpp:
1138         (JavaInstance::invokeMethod):
1139
1140 2011-03-30  Evan Martin  <evan@chromium.org>
1141
1142         Reviewed by Ryosuke Niwa.
1143
1144         clean up Document's handling of title changes
1145         https://bugs.webkit.org/show_bug.cgi?id=57433
1146
1147         Document::setTitle has two entry points:
1148         1) from DOM bindings, like document.title="foo"
1149         2) from title tags, like <title>foo</title> in HTML
1150
1151         Split these two code paths to make the code easier to follow.
1152         Also, replace the repeated pattern of
1153             m_rawTitle = "foo"; updateTitle();
1154         with
1155             updateTitle("foo");
1156
1157         * dom/Document.cpp:
1158         (WebCore::Document::updateTitle):
1159         (WebCore::Document::setTitle):
1160         (WebCore::Document::setTitleElement):
1161         (WebCore::Document::removeTitle):
1162         * dom/Document.h:
1163         * html/HTMLTitleElement.cpp:
1164         (WebCore::HTMLTitleElement::insertedIntoDocument):
1165         (WebCore::HTMLTitleElement::childrenChanged):
1166         * svg/SVGTitleElement.cpp:
1167         (WebCore::SVGTitleElement::insertedIntoDocument):
1168         (WebCore::SVGTitleElement::childrenChanged):
1169
1170 2011-03-30  Levi Weintraub  <leviw@chromium.org>
1171
1172         Reviewed by Ryosuke Niwa.
1173
1174         BreakBlockQuoteCommand assumes all li tags have list item renderers
1175         https://bugs.webkit.org/show_bug.cgi?id=57253
1176
1177         Checking that the renderers of li nodes are actually RenderListItems
1178         before treating them as such.
1179
1180         Test: editing/execCommand/crash-breaking-blockquote-with-list.html
1181
1182         * editing/BreakBlockquoteCommand.cpp:
1183         (WebCore::BreakBlockQuoteCommand::doApply):
1184
1185 2011-03-30  Pavel Feldman  <pfeldman@chromium.org>
1186
1187         Not reviewed: fixing typo in the inspector front-end.
1188
1189         Web Inspector: REGRESSION: Broken live edit errors handling
1190         https://bugs.webkit.org/show_bug.cgi?id=57436
1191
1192         * inspector/front-end/DebuggerModel.js:
1193         (WebInspector.DebuggerModel.prototype._didEditScriptSource):
1194
1195 2011-03-30  Yael Aharon  <yael.aharon@nokia.com>
1196
1197         Reviewed by Eric Seidel.
1198
1199         Left/Right borders/padding/margins are not always added correctly when rendering multiline inline boxes with bidi elements
1200         https://bugs.webkit.org/show_bug.cgi?id=9272
1201
1202
1203         Also fixes https://bugs.webkit.org/show_bug.cgi?id=47210 and https://bugs.webkit.org/show_bug.cgi?id=8392.
1204
1205         Change how we decide if an InlineFlowBox is the last one for its renderer. Use the position of resolver's logicallyLastRun
1206         to decide if there is more text in the next line.
1207
1208         Tests: fast/borders/rtl-border-01.html
1209                fast/borders/rtl-border-02.html
1210                fast/borders/rtl-border-03.html
1211                fast/borders/rtl-border-04.html
1212                fast/borders/rtl-border-05.html
1213
1214         * rendering/InlineFlowBox.cpp:
1215         (WebCore::isAnsectorAndWithinBlock):
1216         (WebCore::InlineFlowBox::determineSpacingForFlowBoxes):
1217         * rendering/InlineFlowBox.h:
1218         * rendering/RenderBlock.h:
1219         * rendering/RenderBlockLineLayout.cpp:
1220         (WebCore::RenderBlock::constructLine):
1221         (WebCore::reachedEndOfTextRenderer):
1222         (WebCore::RenderBlock::layoutInlineChildren):
1223
1224 2011-03-29  Nikolas Zimmermann  <nzimmermann@rim.com>
1225
1226         Reviewed by Eric Seidel.
1227
1228         REGRESSION (r68976): Incorrect bidi rendering in SVG text
1229         https://bugs.webkit.org/show_bug.cgi?id=53980
1230
1231         Deconvolute SVGTextLayoutEngine code, which was confusing due to the simultaneous processing of the rendered text
1232         in visual and logical order. Added several helper methods to make the code more readable.
1233
1234         Fix Unicode directional formatting characters support, now works as expected.
1235
1236         Test: svg/text/bidi-embedded-direction.svg
1237
1238         * editing/visible_units.cpp: Refactor getLeafBoxesInLogicalOrder(), move to InlineFlowBox.
1239         (WebCore::getLogicalStartBoxAndNode): Use new collectLeafBoxesInLogicalOrder() method in InlineFlowBox.
1240         (WebCore::getLogicalEndBoxAndNode): Ditto.
1241         * rendering/InlineFlowBox.cpp: Add new helper function, that returns a list of all leaf boxes in logical order.
1242         (WebCore::InlineFlowBox::collectLeafBoxesInLogicalOrder):
1243         * rendering/InlineFlowBox.h:
1244         * rendering/svg/RenderSVGText.cpp: Actually trigger reordering the x/y/dx/dy/rotate value lists, if needed.
1245         (WebCore::RenderSVGText::RenderSVGText):
1246         (WebCore::RenderSVGText::layout):
1247         * rendering/svg/RenderSVGText.h: Ditto.
1248         (WebCore::RenderSVGText::layoutAttributes):
1249         (WebCore::RenderSVGText::needsReordering):
1250         * rendering/svg/SVGRootInlineBox.cpp: Use new InlineFlowBox::collectLeafBoxesINLogicalOrder(), with a custom "inline box reverse" implementation,
1251                                               which not only reverses the order of InlineBoxes, but also the order of the x/y/dx/dy/rotate value lists, if needed.
1252         (WebCore::SVGRootInlineBox::computePerCharacterLayoutInformation):
1253         (WebCore::SVGRootInlineBox::layoutCharactersInTextBoxes):
1254         (WebCore::swapItems):
1255         (WebCore::reverseInlineBoxRangeAndValueListsIfNeeded):
1256         (WebCore::SVGRootInlineBox::reorderValueLists):
1257         * rendering/svg/SVGRootInlineBox.h:
1258         * rendering/svg/SVGTextLayoutAttributes.cpp: Store RenderSVGInlineText* pointer, where we belong to.
1259         (WebCore::SVGTextLayoutAttributes::SVGTextLayoutAttributes):
1260         (WebCore::SVGTextLayoutAttributes::dump):
1261         * rendering/svg/SVGTextLayoutAttributes.h:
1262         (WebCore::SVGTextLayoutAttributes::context):
1263         * rendering/svg/SVGTextLayoutAttributesBuilder.cpp: Pass RenderSVGInlineText* object when creating SVGTextLayoutAttributes.
1264         (WebCore::SVGTextLayoutAttributesBuilder::buildLayoutAttributesForTextSubtree):
1265         (WebCore::SVGTextLayoutAttributesBuilder::propagateLayoutAttributes):
1266         * rendering/svg/SVGTextLayoutAttributesBuilder.h:
1267         * rendering/svg/SVGTextLayoutEngine.cpp: Rewrite & cleanup the main layout algorithm, to be less confusing.
1268         (WebCore::SVGTextLayoutEngine::SVGTextLayoutEngine):
1269         (WebCore::SVGTextLayoutEngine::updateRelativePositionAdjustmentsIfNeeded):
1270         (WebCore::SVGTextLayoutEngine::recordTextFragment):
1271         (WebCore::SVGTextLayoutEngine::currentLogicalCharacterAttributes):
1272         (WebCore::SVGTextLayoutEngine::currentLogicalCharacterMetrics):
1273         (WebCore::SVGTextLayoutEngine::currentVisualCharacterMetrics):
1274         (WebCore::SVGTextLayoutEngine::advanceToNextLogicalCharacter):
1275         (WebCore::SVGTextLayoutEngine::advanceToNextVisualCharacter):
1276         (WebCore::SVGTextLayoutEngine::layoutTextOnLineOrPath):
1277         * rendering/svg/SVGTextLayoutEngine.h:
1278
1279 2011-03-30  Ilya Tikhonovsky  <loislo@chromium.org>
1280
1281         Not reviewed trivial change.
1282
1283         Web Inspector: Remove unnecessary function arguments after r82281.
1284         https://bugs.webkit.org/show_bug.cgi?id=57327
1285
1286         * inspector/InspectorAgent.cpp:
1287         (WebCore::InspectorAgent::didCommitLoad):
1288         (WebCore::InspectorAgent::domContentLoadedEventFired):
1289         * inspector/InspectorAgent.h:
1290         * inspector/InspectorInstrumentation.cpp:
1291         (WebCore::InspectorInstrumentation::domContentLoadedEventFiredImpl):
1292         (WebCore::InspectorInstrumentation::didCommitLoadImpl):
1293
1294 2011-03-30  Kent Tamura  <tkent@chromium.org>
1295
1296         Reviewed by Ojan Vafai.
1297
1298         H1 element should have different default style if it is in HTML5 sectioning elements.
1299         https://bugs.webkit.org/show_bug.cgi?id=52693
1300
1301         Test: fast/css/h1-in-section-elements.html
1302
1303         * css/html.css: Add font-size and margin declarations to follow HTML5 specification.
1304         (:-webkit-any(article,aside,nav,section) h1):
1305         (:-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) h1):
1306         (:-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) h1):
1307         (:-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) h1):
1308         (:-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) :-webkit-any(article,aside,nav,section) h1):
1309
1310 2011-03-29  Beth Dakin  <bdakin@apple.com>
1311
1312         Reviewed by Maciej Stachowiak.
1313
1314         Fix for https://bugs.webkit.org/show_bug.cgi?id=57408
1315         webkit-min-device-pixel-ratio media query doesn't work post-SnowLeopard 
1316         -and corresponding-
1317         <rdar://problem/8665411>
1318
1319         * platform/mac/PlatformScreenMac.mm:
1320         (WebCore::windowScaleFactor):
1321         (WebCore::toUserSpace):
1322         (WebCore::toDeviceSpace):
1323
1324 2011-03-29  Eric Seidel  <eric@webkit.org>
1325
1326         Reviewed by Dimitri Glazkov.
1327
1328         Rename BidiResolver::eor and sor to m_eor and m_sor to match modern style
1329         https://bugs.webkit.org/show_bug.cgi?id=57369
1330
1331         I considered renaming these to m_endOfRun and m_startOfRun but decided
1332         that was too verbose for now (given how often they're used).  I suspect
1333         with a bit more refactoring we'll find they're not used very often and can be renamed
1334         if so desired.
1335
1336         * platform/text/BidiResolver.h:
1337         (WebCore::::appendRun):
1338         (WebCore::::checkDirectionInLowerRaiseEmbeddingLevel):
1339         (WebCore::::lowerExplicitEmbeddingLevel):
1340         (WebCore::::raiseExplicitEmbeddingLevel):
1341         (WebCore::::createBidiRunsForLine):
1342         * rendering/InlineIterator.h:
1343         (WebCore::InlineBidiResolver::appendRun):
1344
1345 2011-03-29  Mikhail Naganov  <mnaganov@chromium.org>
1346
1347         Reviewed by Pavel Feldman.
1348
1349         Web Inspector: [Chromium] Remove exact retained size request in detailed heap snapshots.
1350         https://bugs.webkit.org/show_bug.cgi?id=57351
1351
1352         * bindings/js/ScriptHeapSnapshot.h:
1353         * bindings/v8/ScriptHeapSnapshot.cpp:
1354         * bindings/v8/ScriptHeapSnapshot.h:
1355         * inspector/Inspector.json:
1356         * inspector/InspectorProfilerAgent.cpp:
1357         * inspector/InspectorProfilerAgent.h:
1358         * inspector/front-end/DetailedHeapshotGridNodes.js:
1359         (WebInspector.HeapSnapshotGenericObjectNode):
1360         (WebInspector.HeapSnapshotGenericObjectNode.prototype.get data):
1361         * inspector/front-end/DetailedHeapshotView.js:
1362         (WebInspector.DetailedHeapshotView.prototype._mouseClickInContainmentGrid):
1363
1364 2011-03-29  Eric Seidel  <eric@webkit.org>
1365
1366         Reviewed by Ryosuke Niwa.
1367
1368         Split more logic out from createBidiRunsForLine for readability
1369         https://bugs.webkit.org/show_bug.cgi?id=57341
1370
1371         I marked reorderRunsFromLevels inline, but it probably doesn't actually need to (or want to) be.
1372         This lops another large hunk off of reorderRunsFromLevels further reducing the size and complexity.
1373
1374         * platform/text/BidiResolver.h:
1375         (WebCore::::reorderRunsFromLevels):
1376         (WebCore::::createBidiRunsForLine):
1377
1378 2011-03-29  Kent Tamura  <tkent@chromium.org>
1379
1380         Reviewed by Dimitri Glazkov.
1381
1382         Make validation message bubble testable
1383         https://bugs.webkit.org/show_bug.cgi?id=57290
1384
1385         Introduce a setting for validation message timer so that we can configure
1386         how long we show a validation message bubble.
1387
1388         Test: fast/forms/validation-message-appearance.html
1389
1390         * html/ValidationMessage.cpp:
1391         (WebCore::ValidationMessage::setMessageDOMAndStartTimer):
1392           Don't set a timer if the timer magnification value is 0 or negative.
1393           Otherwise, hides the bubble length * magnification / 1000 seconds.
1394         * page/Settings.cpp:
1395         (WebCore::Settings::Settings): Initialize the timer magnification value.
1396         * page/Settings.h:
1397         (WebCore::Settings::setValidationMessageTimerMagnification): Added.
1398         (WebCore::Settings::validationMessageTimerMaginification): Added.
1399
1400 2011-03-29  Dimitri Glazkov  <dglazkov@chromium.org>
1401
1402         Remove the extraneous declaration I accidentally added in r82376.
1403
1404         * dom/MouseEvent.h: Removed createSimulated decl.
1405
1406 2011-03-29  James Robinson  <jamesr@chromium.org>
1407
1408         Reviewed by Kenneth Russell.
1409
1410         [chromium] Compositor crash with show-layer-borders flag
1411         https://bugs.webkit.org/show_bug.cgi?id=57292
1412
1413         Synchronize the debug border color/width with other properties to ensure the appropriate
1414         CCLayerImpl exists.  Code is only exercised with a debugging command line flag so no layout
1415         test.
1416
1417         * platform/graphics/chromium/LayerChromium.cpp:
1418         (WebCore::LayerChromium::pushPropertiesTo):
1419         (WebCore::LayerChromium::setBorderColor):
1420         (WebCore::LayerChromium::setBorderWidth):
1421         * platform/graphics/chromium/LayerChromium.h:
1422
1423 2011-03-29  Tony Gentilcore  <tonyg@chromium.org>
1424
1425         Reviewed by Adam Barth.
1426
1427         Teach the preload scanner about &lt;input type=image&gt;
1428         https://bugs.webkit.org/show_bug.cgi?id=57404
1429
1430         I did a very rough sample of the top 50 web pages to see how many of each
1431         HTML resource type they include:
1432         img src: 1,359
1433         script src: 276
1434         link href: 256
1435         iframe src: 104
1436         input src: 50
1437         embed src: 37
1438         @import: 13
1439         object data: 11
1440
1441         Based on this, it seems worthwhile to preload inputs and iframes (possibly embed).
1442         This patch only does inputs.
1443
1444         Test: fast/preloader/input.html
1445
1446         * html/parser/HTMLPreloadScanner.cpp:
1447         (WebCore::HTMLNames::PreloadTask::PreloadTask):
1448         (WebCore::HTMLNames::PreloadTask::processAttributes):
1449         (WebCore::HTMLNames::PreloadTask::inputTypeAttributeIsImage):
1450         (WebCore::HTMLNames::PreloadTask::preload):
1451
1452 2011-03-29  Luke Macpherson   <macpherson@chromium.org>
1453
1454         Reviewed by David Levin.
1455
1456         Improve the massive switch statement in CSSStyleSelector::applyProperty.
1457         https://bugs.webkit.org/show_bug.cgi?id=56288
1458
1459         No new tests are needed because no new functionality exposed.
1460
1461         * css/CSSStyleSelector.cpp:
1462         (WebCore::CSSStyleSelector::applyProperty):
1463         Asserted that cases implemented in the CSSStyleApplyProperty lookup table are unreachable.
1464         Updated comment.
1465
1466 2011-03-29  Dimitri Glazkov  <dglazkov@chromium.org>
1467
1468         Reviewed by Darin Adler.
1469
1470         Introduce SimulatedMouseEvent and teach EventDispatcher how to use it.
1471         https://bugs.webkit.org/show_bug.cgi?id=57402
1472
1473         No functional changes, covered by existing tests.
1474
1475         * dom/EventDispatcher.cpp:
1476         (WebCore::EventDispatcher::dispatchSimulatedClick): Changed to use SimulatedMouseEvent.
1477         (WebCore::EventDispatcher::dispatchMouseEvent): Combined two dispatchMouseEvent methods
1478             into one, now that simulated-click events don't need one.
1479         * dom/EventDispatcher.h: Updated decls.
1480         * dom/MouseEvent.cpp:
1481         (WebCore::SimulatedMouseEvent::create): Added.
1482         (WebCore::SimulatedMouseEvent::~SimulatedMouseEvent): Added.
1483         (WebCore::SimulatedMouseEvent::SimulatedMouseEvent): Added.
1484         * dom/MouseEvent.h: Made constructor protected.
1485
1486 2011-03-29  Anders Carlsson  <andersca@apple.com>
1487
1488         Fix build.
1489
1490         * WebCore.exp.in:
1491
1492 2011-03-29  Steve Block  <steveblock@google.com>
1493
1494         Reviewed by Jeremy Orlow.
1495
1496         JavaInstance should not use jvalue in its API
1497         https://bugs.webkit.org/show_bug.cgi?id=57019
1498
1499         This change updates JavaInstance for V8 to use JavaValue, rather than
1500         jvalue, in its API. This will allow us to create an API for
1501         JavaInstance that is independent of JNI, to allow it to be
1502         implemented on platforms that do not use JNI directly.
1503
1504         Refactoring only, no new tests.
1505
1506         * bridge/jni/v8/JavaInstanceV8.cpp:
1507         (JavaInstance::invokeMethod):
1508         (JavaInstance::getField):
1509         * bridge/jni/v8/JavaInstanceV8.h:
1510         * bridge/jni/v8/JavaNPObjectV8.cpp:
1511         (JSC::Bindings::JavaNPObjectInvoke):
1512         (JSC::Bindings::JavaNPObjectGetProperty):
1513         * bridge/jni/v8/JavaValueV8.h:
1514
1515 2011-03-29  Eric Seidel  <eric@webkit.org>
1516
1517         Reviewed by Dimitri Glazkov.
1518
1519         Rename BidiResolver::last to m_last to match modern style
1520         https://bugs.webkit.org/show_bug.cgi?id=57367
1521
1522         * platform/text/BidiResolver.h:
1523         (WebCore::::lowerExplicitEmbeddingLevel):
1524         (WebCore::::raiseExplicitEmbeddingLevel):
1525         (WebCore::::createBidiRunsForLine):
1526
1527 2011-03-29  Justin Schuh  <jschuh@chromium.org>
1528
1529         Reviewed by Maciej Stachowiak.
1530
1531         SVGComponentTransferFunctionElement should validate type
1532         https://bugs.webkit.org/show_bug.cgi?id=56960
1533
1534         Test: svg/filters/feComponentTransfer-style-crash.xhtml
1535
1536         * svg/SVGComponentTransferFunctionElement.cpp:
1537         (WebCore::SVGComponentTransferFunctionElement::svgAttributeChanged):
1538         * svg/SVGComponentTransferFunctionElement.h:
1539
1540 2011-03-29  Thomas Klausner  <tk@giga.or.at>
1541
1542         Reviewed by David Levin.
1543
1544         png-1.5 fixes
1545         https://bugs.webkit.org/show_bug.cgi?id=54406
1546
1547         Fix compilation with png-1.5: struct members were hidden, and
1548         a new API to terminate data processing was added (especially for
1549         WebKit).
1550
1551         Compilation fixes, so no new tests.
1552
1553         * platform/image-decoders/png/PNGImageDecoder.cpp:
1554         (WebCore::PNGImageDecoder::headerAvailable):
1555         (WebCore::PNGImageDecoder::rowAvailable):
1556
1557 2011-03-29  Gavin Peters  <gavinp@chromium.org>
1558
1559         Reviewed by Tony Gentilcore.
1560
1561         Add beforeload to icon and prefetch link rel types
1562         https://bugs.webkit.org/show_bug.cgi?id=56424
1563
1564         Over in https://lists.webkit.org/pipermail/webkit-dev/2011-February/016034.html , a webkit-dev
1565         thread, I've discussed my hopes for the link element, and adding the link header.  This
1566         change helps improve the link header by making it participate in the beforeload event in
1567         two more important cases.
1568
1569         Tests: fast/dom/HTMLLinkElement/prefetch-beforeload.html
1570                http/tests/misc/link-rel-icon-beforeload.html
1571                webarchive/test-link-rel-icon-beforeload.html
1572
1573         * html/HTMLLinkElement.cpp:
1574         (WebCore::HTMLLinkElement::checkBeforeLoadEvent):
1575         (WebCore::HTMLLinkElement::process):
1576         * html/HTMLLinkElement.h:
1577
1578 2011-03-29  Eric Seidel  <eric@webkit.org>
1579
1580         Reviewed by Dimitri Glazkov.
1581
1582         Rename BidiResolver::current to BidiResolver::m_current to match modern style
1583         https://bugs.webkit.org/show_bug.cgi?id=57363
1584
1585         I was very confused by current until I realized it was a member variable.
1586         I also did m_reachedEndOfLine since that was small.
1587
1588         * platform/text/BidiResolver.h:
1589         (WebCore::BidiResolver::position):
1590         (WebCore::BidiResolver::setPosition):
1591         (WebCore::BidiResolver::increment):
1592         (WebCore::::createBidiRunsForLine):
1593
1594 2011-03-29  Geoff Pike  <gpike@chromium.org>
1595
1596         Reviewed by Dimitri Glazkov.
1597
1598         In HitTestResult objects, initialize the ListHashSet<RefPtr<Node> >
1599         lazily.  In my informal testing it seems to be used hardly at all, so
1600         it's wasteful to create it eagerly.  Initializing a ListHashSet
1601         is expensive because a ListHashSet initially has space for 256
1602         elements, and that space is memset to 0.
1603
1604         This change should improve performance but have no impact on
1605         correctness.  On x86-64, for example, the change cuts the
1606         cost of HitTestResult(IntPoint()) in EventHandler::mouseMoved()
1607         from ~1700 cycles to ~300 cycles.
1608
1609         * rendering/HitTestResult.cpp:
1610         (WebCore::HitTestResult::HitTestResult): copy *m_rectBasedTestResult if m_rectBasedTestResult isn't 0
1611         (WebCore::HitTestResult::operator=): copy *m_rectBasedTestResult if m_rectBasedTestResult isn't 0
1612         (WebCore::HitTestResult::addNodeToRectBasedTestResult): use mutableRectBasedTestResult() rather than m_rectBasedTestResult
1613         (WebCore::HitTestResult::append): append *(other.m_rectBasedTestResult) if other.m_rectBasedTestResult isn't 0
1614         * rendering/HitTestResult.h:
1615         (WebCore::HitTestResult::rectBasedTestResult): Add a typedef for ListHashSet<RefPtr<Node> > to ease readability.  Change m_rectBasedTestResult from ListHashSet<RefPtr<Node> > to an OwnPtr of same.  Modify rectBasedTestResult() and add mutableRectBasedTestResult().
1616
1617 2011-03-29  Timothy Hatcher  <timothy@apple.com>
1618
1619         Update the order of the context menu to better match AppKit on Mac.
1620
1621         <rdar://problem/9054893>
1622
1623         Reviewed by John Sullivan.
1624
1625         * English.lproj/Localizable.strings: Updated.
1626         * page/ContextMenuController.cpp:
1627         (WebCore::ContextMenuController::populate): Update the order of items on Mac.
1628         * platform/LocalizationStrategy.h:
1629         * platform/LocalizedStrings.cpp:
1630         (WebCore::contextMenuItemTagLookUpInDictionary): Added argument for selected string.
1631         * platform/LocalizedStrings.h:
1632         * platform/android/LocalizedStringsAndroid.cpp:
1633         (WebCore::contextMenuItemTagLookUpInDictionary): Ditto.
1634         * platform/brew/LocalizedStringsBrew.cpp:
1635         (WebCore::contextMenuItemTagLookUpInDictionary): Ditto.
1636         * platform/efl/LocalizedStringsEfl.cpp:
1637         (WebCore::contextMenuItemTagLookUpInDictionary): Ditto.
1638         * platform/gtk/LocalizedStringsGtk.cpp:
1639         (WebCore::contextMenuItemTagLookUpInDictionary): Ditto.
1640         * platform/haiku/LocalizedStringsHaiku.cpp:
1641         (WebCore::contextMenuItemTagLookUpInDictionary): Ditto.
1642         * platform/wx/LocalizedStringsWx.cpp:
1643         (WebCore::contextMenuItemTagLookUpInDictionary): Ditto.
1644
1645 2011-03-29  Dean Jackson  <dino@apple.com>
1646
1647         Reviewed by Chris Marrin and Ken Russell.
1648
1649         https://bugs.webkit.org/show_bug.cgi?id=57248
1650         Occlusion issues with WebGL in Safari
1651
1652         The depth buffer on Safari ports was being set up with a
1653         maximum of 16 bits. Now we use a combined 24/8 depth/stencil
1654         buffer on Mac ports.
1655
1656         No new tests as this is the setting for a particular port. Other
1657         ports may use different defaults.
1658
1659         * platform/graphics/opengl/GraphicsContext3DOpenGL.cpp:
1660         (WebCore::GraphicsContext3D::validateAttributes):
1661         - use Extensions3D to test for depth and multisample extensions
1662           rather than querying OpenGL directly.
1663         (WebCore::GraphicsContext3D::reshape):
1664         - use a 24bit depth buffer when the extension is enabled.
1665
1666 2011-03-29  Dimitri Glazkov  <dglazkov@chromium.org>
1667
1668         Sorted XCode project. It's gotten quite out of sorts.
1669
1670         * WebCore.xcodeproj/project.pbxproj: Ran sort-XCode-project-file.
1671
1672 2011-03-29  Emil A Eklund  <eae@chromium.org>
1673
1674         Reviewed by Dimitri Glazkov.
1675
1676         DatasetDOMStringMap::item and ::contains copies attribute name string
1677         https://bugs.webkit.org/show_bug.cgi?id=55645
1678
1679         Change propertyNameMatchesAttributeName to match without creating a copy
1680         of the string.
1681
1682         * dom/DatasetDOMStringMap.cpp:
1683         (WebCore::propertyNameMatchesAttributeName):
1684
1685 2011-03-29  Csaba Osztrogon√°c  <ossy@webkit.org>
1686
1687         Unreviewed rollout r82282, part of r82288, r82298.
1688
1689         * css/CSSParser.cpp:
1690         (WebCore::parseColorInt):
1691         (WebCore::isValidDouble):
1692         (WebCore::parseAlphaValue):
1693         (WebCore::CSSParser::parseColor):
1694
1695 2011-03-25  Brent Fulgham  <bfulgham@webkit.org>
1696
1697         Reviewed by Dave Hyatt.
1698
1699         https://bugs.webkit.org/show_bug.cgi?id=55981
1700         Second round of clean-ups, aimed at supporting GTK with the
1701         same unified FontPlatformData header.  This version removes
1702         some unneeded WinCairo code, and aligns the WinCairo and
1703         GTK ports to reduce code duplication.
1704
1705         * WebCore.vcproj/WebCore.vcproj: Get rid of a dangling reference
1706           to an old WinCairo file.
1707         * platform/graphics/FontPlatformData.h: Remove unneeded member
1708           for m_fontFace, which is a member of m_scaledFont.  Switch to
1709           standard Cairo hashing.
1710         (WebCore::FontPlatformData::FontPlatformData):
1711         (WebCore::FontPlatformData::font):
1712         (WebCore::FontPlatformData::scaledFont):
1713         (WebCore::FontPlatformData::hash):
1714         (WebCore::FontPlatformData::isHashTableDeletedValue):
1715         (WebCore::FontPlatformData::hashTableDeletedFontValue):
1716         * platform/graphics/win/FontCacheWin.cpp: Update to no longer use
1717           the unnecessary fontFace() accessor.
1718         (WebCore::FontCache::createFontPlatformData):
1719         * platform/graphics/win/FontCustomPlatformDataCairo.cpp:
1720         * platform/graphics/win/FontPlatformDataCairoWin.cpp:
1721         (WebCore::FontPlatformData::platformDataInit):
1722         (WebCore::FontPlatformData::FontPlatformData):
1723         (WebCore::FontPlatformData::~FontPlatformData):
1724         (WebCore::FontPlatformData::platformDataAssign):
1725         (WebCore::FontPlatformData::platformIsEqual):
1726         * platform/graphics/win/FontPlatformDataWin.cpp:
1727         (WebCore::FontPlatformData::FontPlatformData):
1728
1729 2011-03-29  Jian Li  <jianli@chromium.org>
1730
1731         Reviewed by Adam Barth.
1732
1733         Inline worker powered by blob URL does not work with files URL even if
1734         allowFileAccessFromFileURLs is enabled
1735         https://bugs.webkit.org/show_bug.cgi?id=56063
1736
1737         Test: fast/files/workers/inline-worker-via-blob-url.html
1738
1739         * fileapi/BlobURL.cpp: Removed unneeded getOrigin() method.
1740         * fileapi/BlobURL.h: Removed unneeded getOrigin() method.
1741         * page/SecurityOrigin.cpp:
1742         (WebCore::SecurityOrigin::SecurityOrigin): Extended the logic to handle
1743         filesystem URL also to blob URL. Also fixed the problem that m_isUnique
1744         is incorrectly set for blob and filesystem URLs.
1745         (WebCore::SecurityOrigin::create): Removed the special logic for blob URL
1746         since we use the same logic in SecurityOrigin constructor as filesystem
1747         URL.
1748         (WebCore::SecurityOrigin::canRequest): Removed the special logic for blob
1749         URL since it is not needed with the fix in SecurityOrigin constructor.
1750
1751 2011-03-29  Timothy Hatcher  <timothy@apple.com>
1752
1753         Update WebCore Localizable.strings to contain WebCore, WebKit/mac and WebKit2 strings.
1754
1755         https://webkit.org/b/57354
1756
1757         Reviewed by Sam Weinig.
1758
1759         * English.lproj/Localizable.strings: Updated.
1760         * StringsNotToBeLocalized.txt: Removed. To hard to maintain in WebCore.
1761         * platform/network/cf/LoaderRunLoopCF.h: Remove a single quote in an #error so
1762         extract-localizable-strings does not complain about unbalanced single quotes.
1763
1764 2011-03-29  Sheriff Bot  <webkit.review.bot@gmail.com>
1765
1766         Unreviewed, rolling out r82295 and r82300.
1767         http://trac.webkit.org/changeset/82295
1768         http://trac.webkit.org/changeset/82300
1769         https://bugs.webkit.org/show_bug.cgi?id=57380
1770
1771         This patch breaks compile on Chromium (Requested by
1772         abarth|gardener on #webkit).
1773
1774         * accessibility/AccessibilityObject.h:
1775         * accessibility/AccessibilityRenderObject.cpp:
1776         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
1777         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
1778         (atkRole):
1779         (webkit_accessible_get_role):
1780         * accessibility/mac/AccessibilityObjectWrapper.mm:
1781
1782 2011-03-29  Anders Carlsson  <andersca@apple.com>
1783
1784         Fix clang build.
1785
1786         * platform/text/BidiResolver.h:
1787         (WebCore::::createBidiRunsForLine):
1788
1789 2011-03-29  Steve Falkenburg  <sfalken@apple.com>
1790
1791         Reviewed by Adam Roben.
1792
1793         Use per-configuration vsprops in WebCore to avoid WebKitVSPropsRedirectionDir removal by MSVC IDE
1794         https://bugs.webkit.org/show_bug.cgi?id=57378
1795
1796         Visual Studio's IDE was removing instances of $(WebKitVSPropsRedirectionDir) from
1797         InheritedPropertySheet rules in our vcproj files when the vcproj was edited from within
1798         the IDE. To avoid this, add a separate vsprops file for each project configuration that
1799         contains the required inherited property sheets.
1800
1801         * WebCore.vcproj/QTMovieWin.vcproj:
1802         * WebCore.vcproj/QTMovieWinDebug.vsprops: Added.
1803         * WebCore.vcproj/QTMovieWinDebugAll.vsprops: Added.
1804         * WebCore.vcproj/QTMovieWinDebugCairoCFLite.vsprops: Added.
1805         * WebCore.vcproj/QTMovieWinRelease.vsprops: Added.
1806         * WebCore.vcproj/QTMovieWinReleaseCairoCFLite.vsprops: Added.
1807         * WebCore.vcproj/QTMovieWinReleaseLTCG.vsprops: Added.
1808         * WebCore.vcproj/WebCore.vcproj:
1809         * WebCore.vcproj/WebCoreDebug.vsprops: Added.
1810         * WebCore.vcproj/WebCoreDebugAll.vsprops: Added.
1811         * WebCore.vcproj/WebCoreDebugCairoCFLite.vsprops: Added.
1812         * WebCore.vcproj/WebCoreRelease.vsprops: Added.
1813         * WebCore.vcproj/WebCoreReleaseCairoCFLite.vsprops: Added.
1814         * WebCore.vcproj/WebCoreReleaseLTCG.vsprops: Added.
1815
1816 2011-03-29  David Hyatt  <hyatt@apple.com>
1817
1818         Reviewed by Simon Fraser.
1819
1820         <rdar://problem/9194927> REGRESSION (r81691): Page at www.mondaynote.com lays out incorrectly
1821         
1822         Back out the optimization that stopped when it hit the first float. This was an incorrect optimization
1823         and can't be done without more work.
1824
1825         Added fast/block/float/float-forced-below-other-floats.html
1826
1827         * rendering/RenderBlock.cpp:
1828         (WebCore::RenderBlock::logicalLeftOffsetForLine):
1829         (WebCore::RenderBlock::logicalRightOffsetForLine):
1830
1831 2011-03-29  Eric Seidel  <eric@webkit.org>
1832
1833         Reviewed by Ryosuke Niwa.
1834
1835         Start to clean up BidiResolver::createBidiRunsForLine so that mere mortals can understand it
1836         https://bugs.webkit.org/show_bug.cgi?id=57338
1837
1838         I'm attempting to break createBidiRunsForLine into understandable pieces
1839         so that we can tell what it's actually doing.  Our implementation of the
1840         unicode bidi algorithm is slightly different from the spec in that we
1841         run it per-line (instead of over the entire paragraph at once).  This is
1842         great for performance (our implementation is resumable), but it makes
1843         things a bit tricky to understand.  Splitting createBidiRunsForLine into
1844         pieces should help make our UBA implementation more readable.
1845
1846         * platform/text/BidiResolver.h:
1847         (WebCore::::updateStatusLastFromCurrentDirection):
1848         (WebCore::::createBidiRunsForLine):
1849
1850 2011-03-29  Mario Sanchez Prada  <msanchez@igalia.com>
1851
1852         Reviewed by Martin Robinson.
1853
1854         [Gtk] Consistent crash from Google/ARIA combobox click
1855         https://bugs.webkit.org/show_bug.cgi?id=55883
1856
1857         Do not call to firstChild() to avoid entering into infinite loops.
1858
1859         This would happen when current item is a WebCore Group and some of
1860         its children have either role 'option' or 'menuitem'. Other than
1861         that the logic behind that call to firstChild() seems to be no
1862         longer needed so it's safe to remove it.
1863
1864         Test: platform/gtk/accessibility/aria-options-and-menuitems-crash.html
1865
1866         * accessibility/gtk/AccessibilityObjectAtk.cpp:
1867         (WebCore::AccessibilityObject::accessibilityPlatformIncludesObject):
1868         Remove call to firsChild, which was leading to crashes sometimes.
1869
1870 2011-03-29  Mario Sanchez Prada  <msanchez@igalia.com>
1871
1872         Reviewed by Chris Fleizach.
1873
1874         AX: GTK: ARIA role is not respected on <p> <label> <div> and <form>
1875         https://bugs.webkit.org/show_bug.cgi?id=47636
1876
1877         Define new roles in WebCore and map them to ATK accordingly.
1878
1879         Test: platform/gtk/accessibility/aria-roles-unignored.html
1880
1881         * accessibility/AccessibilityObject.h: Added new roles to
1882         represent paragraphs, labels, forms and div sections.
1883         * accessibility/AccessibilityRenderObject.cpp:
1884         (WebCore::AccessibilityRenderObject::determineAccessibilityRole):
1885         Return ParagraphRole, LabelRole, FormRole and DivRole when needed.
1886         * accessibility/gtk/AccessibilityObjectWrapperAtk.cpp:
1887         (atkRole): Map new WebCore roles to ATK Roles.
1888         (webkit_accessible_get_role): Remove code to define roles for
1889         paragraphs, labels, forms and divs based on node's tag name.
1890
1891         Update mappings for the Mac platform.
1892
1893         * accessibility/mac/AccessibilityObjectWrapper.mm:
1894         (createAccessibilityRoleMap): Add explicit mappings from the new
1895         roles introduced to NSAccessibilityGroupRole.
1896
1897 2011-03-29  Philippe Normand  <pnormand@igalia.com>
1898
1899         Unreviewed build fix. Remove ASSERT hitting consitently on GTK.
1900
1901         * rendering/InlineIterator.h:
1902         (WebCore::InlineIterator::moveToStartOf):
1903
1904 2011-03-29  Darin Adler  <darin@apple.com>
1905
1906         Fix some just-introduced build failures.
1907
1908         * WebCore.pro: Correct spelling of filename.
1909
1910         * css/CSSParser.cpp:
1911         (WebCore::parseColorIntOrPercentage): Fix double/int conversion that fails to compile
1912         on Leopard. Also renamed one local variabel.
1913
1914         * inspector/InspectorAgent.cpp:
1915         (WebCore::InspectorAgent::didCommitLoad): Removed unused argument names to avoid warning.
1916         (WebCore::InspectorAgent::domContentLoadedEventFired): Ditto.
1917
1918 2011-03-29  Andras Becsi  <abecsi@webkit.org>
1919
1920         Reviewed by Darin Adler.
1921
1922         CSS: Slow parsing of rgb() with percent values
1923         https://bugs.webkit.org/show_bug.cgi?id=16708
1924
1925         Implement fast-path parsing for percentage color values.
1926
1927         Gain ~30% speedup on http://canvex.lazyilluminati.com/misc/3d.html.
1928
1929         * css/CSSParser.cpp:
1930         (WebCore::checkForValidDouble): Extend to return the number of characters forming a valid double.
1931         (WebCore::parseDouble): Function for parsing double values if they are valid.
1932         (WebCore::parseColorIntOrPercentage): Extend parseColorInt to deal with percentage values.
1933         (WebCore::parseAlphaValue): Use the new functions.
1934         (WebCore::CSSParser::parseColor): Ditto.
1935
1936 2011-03-29  Ilya Tikhonovsky  <loislo@chromium.org>
1937
1938         Reviewed by Pavel Feldman.
1939
1940         Web Inspector: extract InspectorPageAgent from InspectorAgent.
1941         https://bugs.webkit.org/show_bug.cgi?id=57327
1942
1943         There are page related methods and inspector related methods in InspectorAgent.
1944         It would be nice to extract page specific methods for future usage the rest of methods in workers debugger.
1945
1946         * GNUmakefile.am:
1947         * WebCore.gypi:
1948         * inspector/CodeGeneratorInspector.pm:
1949         * inspector/Inspector.json:
1950         * inspector/InspectorAgent.cpp:
1951         (WebCore::InspectorAgent::InspectorAgent):
1952         (WebCore::InspectorAgent::restoreInspectorStateFromCookie):
1953         (WebCore::InspectorAgent::didClearWindowObjectInWorld):
1954         (WebCore::InspectorAgent::setFrontend):
1955         (WebCore::InspectorAgent::disconnectFrontend):
1956         (WebCore::InspectorAgent::didCommitLoad):
1957         (WebCore::InspectorAgent::domContentLoadedEventFired):
1958         * inspector/InspectorAgent.h:
1959         (WebCore::InspectorAgent::pageAgent):
1960         * inspector/InspectorPageAgent.cpp: Added.
1961         (WebCore::InspectorPageAgent::create):
1962         (WebCore::InspectorPageAgent::InspectorPageAgent):
1963         (WebCore::InspectorPageAgent::setFrontend):
1964         (WebCore::InspectorPageAgent::clearFrontend):
1965         (WebCore::InspectorPageAgent::addScriptToEvaluateOnLoad):
1966         (WebCore::InspectorPageAgent::removeAllScriptsToEvaluateOnLoad):
1967         (WebCore::InspectorPageAgent::reloadPage):
1968         (WebCore::InspectorPageAgent::openInInspectedWindow):
1969         (WebCore::InspectorPageAgent::setUserAgentOverride):
1970         (WebCore::buildObjectForCookie):
1971         (WebCore::buildArrayForCookies):
1972         (WebCore::InspectorPageAgent::getCookies):
1973         (WebCore::InspectorPageAgent::deleteCookie):
1974         (WebCore::InspectorPageAgent::inspectedURLChanged):
1975         (WebCore::InspectorPageAgent::restore):
1976         (WebCore::InspectorPageAgent::didCommitLoad):
1977         (WebCore::InspectorPageAgent::domContentEventFired):
1978         (WebCore::InspectorPageAgent::loadEventFired):
1979         (WebCore::InspectorPageAgent::didClearWindowObjectInWorld):
1980         (WebCore::InspectorPageAgent::applyUserAgentOverride):
1981         * inspector/InspectorPageAgent.h: Added.
1982         * inspector/InspectorController.cpp:
1983         (WebCore::InspectorController::connectFrontend):
1984         * inspector/InspectorInstrumentation.cpp:
1985         (WebCore::InspectorInstrumentation::didClearWindowObjectInWorldImpl):
1986         (WebCore::InspectorInstrumentation::applyUserAgentOverrideImpl):
1987         (WebCore::InspectorInstrumentation::domContentLoadedEventFiredImpl):
1988         (WebCore::InspectorInstrumentation::loadEventFiredImpl):
1989         (WebCore::InspectorInstrumentation::didCommitLoadImpl):
1990         (WebCore::InspectorInstrumentation::retrievePageAgent):
1991         * inspector/InspectorInstrumentation.h:
1992         * inspector/InstrumentingAgents.h:
1993         (WebCore::InstrumentingAgents::InstrumentingAgents):
1994         (WebCore::InstrumentingAgents::inspectorPageAgent):
1995         (WebCore::InstrumentingAgents::setInspectorPageAgent):
1996         * inspector/front-end/AuditsPanel.js:
1997         (WebInspector.AuditsPanel.prototype._reloadResources):
1998         * inspector/front-end/CookieItemsView.js:
1999         (WebInspector.CookieItemsView.prototype._deleteCookie):
2000         (WebInspector.Cookies.getCookiesAsync):
2001         * inspector/front-end/ExtensionServer.js:
2002         (WebInspector.ExtensionServer.prototype._onReload):
2003         * inspector/front-end/NetworkPanel.js:
2004         (WebInspector.NetworkDataGridNode.prototype._openInNewTab):
2005         * inspector/front-end/ResourcesPanel.js:
2006         (WebInspector.FrameResourceTreeElement.prototype.ondblclick):
2007         * inspector/front-end/WorkersSidebarPane.js:
2008         (WebInspector.WorkersSidebarPane.prototype.setInstrumentation):
2009         * inspector/front-end/inspector.js:
2010         (WebInspector.openResource):
2011         (WebInspector.documentKeyDown):
2012
2013 2011-03-29  David Hyatt  <hyatt@apple.com>
2014
2015         Reviewed by Darin Adler.
2016
2017         https://bugs.webkit.org/show_bug.cgi?id=57276
2018         
2019         Add optimizations to make the vertical placement of boxes much faster. Whenever a box is added
2020         to a line, compare it with the parent box. If we can determine that the child box has the exact
2021         same height and baseline position as the parent box, then we keep a boolean flag set called
2022         descendantsHaveSameLineHeightAndBaseline(). If the box is different for any reason then we clear the
2023         flag up the line box parent chain.
2024
2025         When it comes time to do computeLogicalboxHeights, we can avoid recurring into the children of
2026         a box whose descendants all have the same position. When we do placeBoxesInBlockDirection, we
2027         can do a simplified recursion that just calls adjustBlockDirectionPosition to offset the boxes
2028         without doing anything else.
2029         
2030         Because of the quirks mode rule of only shrinking boxes with no immediate text children, we need
2031         to track whether a box has text descendants now as well.  When we avoid doing the recursion
2032         this flag tells us whether the collection of boxes should have an effect on the ascent and descent
2033         of the line in quirks mode.
2034  
2035         * rendering/InlineFlowBox.cpp:
2036         (WebCore::InlineFlowBox::addToLine):
2037         (WebCore::InlineFlowBox::computeLogicalBoxHeights):
2038         (WebCore::InlineFlowBox::placeBoxesInBlockDirection):
2039         (WebCore::InlineFlowBox::nodeAtPoint):
2040         (WebCore::InlineFlowBox::paintBoxDecorations):
2041         (WebCore::InlineFlowBox::paintMask):
2042         * rendering/InlineFlowBox.h:
2043         (WebCore::InlineFlowBox::InlineFlowBox):
2044         (WebCore::InlineFlowBox::hasTextDescendants):
2045         (WebCore::InlineFlowBox::descendantsHaveSameLineHeightAndBaseline):
2046         (WebCore::InlineFlowBox::clearDescendantsHaveSameLineHeightAndBaseline):
2047         * rendering/RenderBlock.h:
2048         * rendering/RenderBlockLineLayout.cpp:
2049         (WebCore::RenderBlock::createLineBoxes):
2050         (WebCore::RenderBlock::constructLine):
2051         (WebCore::RenderBlock::computeInlineDirectionPositionsForLine):
2052
2053 2011-03-29  Eric Seidel  <eric@webkit.org>
2054
2055         Reviewed by Ryosuke Niwa.
2056
2057         Remove a bunch of duplicate code by adding some InlineIterator helper methods
2058         https://bugs.webkit.org/show_bug.cgi?id=57326
2059
2060         Once I started adding these it became clear how much crazy duplicated code
2061         we had due to treating InlineIterator as a struct and accessing its
2062         members directly.  We can't quite make the members private yet since
2063         findNextLineBreak still splits out the members.  But this change
2064         makes the code much cleaner.
2065
2066         * rendering/InlineIterator.h:
2067         (WebCore::InlineIterator::clear):
2068         (WebCore::InlineIterator::moveToStartOf):i
2069         (WebCore::InlineIterator::moveTo):
2070         (WebCore::InlineIterator::increment):
2071         * rendering/RenderBlockLineLayout.cpp:
2072         (WebCore::tryHyphenating):
2073         (WebCore::RenderBlock::findNextLineBreak):
2074
2075 2011-03-29  Eric Seidel  <eric@webkit.org>
2076
2077         Reviewed by Ryosuke Niwa.
2078
2079         Clean up bidiNext by abstracting repeated code
2080         https://bugs.webkit.org/show_bug.cgi?id=57335
2081
2082         I also added a comment to explain what bidiNext is actually doing.
2083         This whole area of code is confusing but need not be.
2084
2085         * rendering/InlineIterator.h:
2086         (WebCore::embedCharFromDirection):
2087         (WebCore::notifyResolverEnteredObject):
2088         (WebCore::notifyResolverWillExitObject):
2089         (WebCore::bidiNext):
2090         (WebCore::bidiFirst):
2091
2092 2011-03-29  Alexander Pavlov  <apavlov@chromium.org>
2093
2094         Reviewed by Yury Semikhatsky.
2095
2096         Web Inspector: Support external CSS stylesheet freeflow text editing
2097         https://bugs.webkit.org/show_bug.cgi?id=54397
2098
2099         In this implementation, Ctrl/Cmd-S commits the current changes into the model.
2100
2101         * inspector/front-end/ResourceView.js:
2102         (WebInspector.ResourceView.createResourceView):
2103         (WebInspector.CSSSourceFrameDelegateForResourcesPanel):
2104         (WebInspector.CSSSourceFrameDelegateForResourcesPanel.prototype.canEditScriptSource):
2105         (WebInspector.CSSSourceFrameDelegateForResourcesPanel.prototype.editScriptSource):
2106         (WebInspector.CSSSourceFrameDelegateForResourcesPanel.prototype.editScriptSource.handleInfos):
2107         (WebInspector.CSSSourceFrameDelegateForResourcesPanel.prototype._saveStyleSheet):
2108         * inspector/front-end/ResourcesPanel.js:
2109         (WebInspector.ResourcesPanel.prototype._applyDiffMarkup):
2110         (WebInspector.FrameResourceTreeElement.prototype._contentChanged):
2111         * inspector/front-end/SourceFrame.js:
2112         (WebInspector.SourceFrame.prototype._createTextViewer):
2113
2114 2011-03-29  Eric Carlson  <eric.carlson@apple.com>
2115
2116         Reviewed by Dan Bernstein.
2117
2118         playbackRate should not be set to defaultPlaybackRate in play()
2119         https://bugs.webkit.org/show_bug.cgi?id=55943
2120
2121         Test: media/video-playbackrate.html
2122
2123         * html/HTMLMediaElement.cpp:
2124         (WebCore::HTMLMediaElement::playbackRate): No need to ask the media engine for the current
2125             rate, we already have the current value cached.
2126         (WebCore::HTMLMediaElement::playInternal): Don't reset the engine's playback rate to 
2127             the default rate.
2128         (WebCore::HTMLMediaElement::togglePlayState): Do reset the engine's playback rate to 
2129             the default rate before triggering playback.
2130         * manual-tests/media-default-playback-rate.html: Added.
2131
2132 2011-03-28  Dimitri Glazkov  <dglazkov@chromium.org>
2133
2134         Reviewed by Eric Seidel.
2135
2136         Remove specialization of EventDispatcher with inversion of control.
2137         https://bugs.webkit.org/show_bug.cgi?id=57285
2138
2139         Since some events have extra logic around their dispatch, allow them
2140         to dispatch themselves and specialize the logic. This change only
2141         converts KeyboardEvent to this model.
2142
2143         No functional change, covered by existing tests.
2144
2145         * dom/Event.cpp:
2146         (WebCore::Event::dispatch): Added.
2147         * dom/Event.h: Updated decls.
2148         * dom/EventDispatcher.cpp:
2149         (WebCore::EventDispatcher::dispatchEvent): Changed to ask event to dispatch
2150             itself.
2151         * dom/EventDispatcher.h: Updated decls.
2152         * dom/KeyboardEvent.cpp:
2153         (WebCore::KeyboardEvent::dispatch): Added, moving code from EventDispatcher.
2154         * dom/KeyboardEvent.h: Updated decls.
2155         * dom/Node.cpp:
2156         (WebCore::Node::dispatchKeyEvent): Changed to use the new ways.
2157
2158 2011-03-29  Ilya Tikhonovsky  <loislo@chromium.org>
2159
2160         Reviewed by Yury Semikhatsky.
2161
2162         Web Inspector: InspectorDOMAgent has unnecessary dependency from InspectorAgent.
2163         https://bugs.webkit.org/show_bug.cgi?id=57329
2164
2165         * inspector/InspectorAgent.cpp:
2166         (WebCore::InspectorAgent::InspectorAgent):
2167         (WebCore::InspectorAgent::setFrontend):
2168         * inspector/InspectorAgent.h:
2169         * inspector/InspectorController.cpp:
2170         (WebCore::InspectorController::inspect):
2171         * inspector/InspectorDOMAgent.cpp:
2172         (WebCore::InspectorDOMAgent::InspectorDOMAgent):
2173         (WebCore::InspectorDOMAgent::setFrontend):
2174         (WebCore::InspectorDOMAgent::handleMousePress):
2175         (WebCore::InspectorDOMAgent::inspect):
2176         (WebCore::InspectorDOMAgent::focusNode):
2177         (WebCore::InspectorDOMAgent::highlight):
2178         (WebCore::InspectorDOMAgent::hideHighlight):
2179         * inspector/InspectorDOMAgent.h:
2180         (WebCore::InspectorDOMAgent::create):
2181
2182 2011-03-29  Eric Seidel  <eric@webkit.org>
2183
2184         Reviewed by Nikolas Zimmermann.
2185
2186         Rename InlineIterator::pos to m_pos to match modern style
2187         https://bugs.webkit.org/show_bug.cgi?id=57342
2188
2189         Somehow I failed to upload this one earlier, no wonder later patches didn't apply.
2190
2191         * rendering/InlineIterator.h:
2192         (WebCore::InlineIterator::InlineIterator):
2193         (WebCore::operator==):
2194         (WebCore::operator!=):
2195         (WebCore::InlineIterator::increment):
2196         (WebCore::InlineIterator::current):
2197         (WebCore::InlineBidiResolver::appendRun):
2198         * rendering/RenderBlockLineLayout.cpp:
2199         (WebCore::checkMidpoints):
2200         (WebCore::RenderBlock::appendRunsForObject):
2201         (WebCore::RenderBlock::layoutInlineChildren):
2202         (WebCore::RenderBlock::matchedEndLine):
2203         (WebCore::tryHyphenating):
2204         (WebCore::RenderBlock::findNextLineBreak):
2205
2206 2011-03-29  Pavel Feldman  <pfeldman@chromium.org>
2207
2208         Reviewed by Yury Semikhatsky.
2209
2210         Web Inspector: document BrowserDebugger agent.
2211         https://bugs.webkit.org/show_bug.cgi?id=57331
2212
2213         * inspector/Inspector.json:
2214
2215 2011-03-29  Alexander Pavlov  <apavlov@chromium.org>
2216
2217         Reviewed by Pavel Feldman.
2218
2219         Web Inspector: Fix handling of the CSSAgent.setStyleSheetText() results in CSSStyleModel.js
2220         https://bugs.webkit.org/show_bug.cgi?id=56310
2221
2222         Instead of stylesheet ids, CSSAgent.getAllStyleSheets() now returns metainfo objects containing
2223         "styleSheetId", "sourceURL", "disabled", and "title" fields. The latter three are not returned
2224         by CSSAgent.getStyleSheet() anymore.
2225
2226         Test: inspector/styles/get-set-stylesheet-text.html
2227
2228         * inspector/Inspector.json:
2229         * inspector/InspectorCSSAgent.cpp:
2230         (WebCore::InspectorCSSAgent::getAllStyleSheets):
2231         * inspector/InspectorCSSAgent.h:
2232         * inspector/InspectorStyleSheet.cpp:
2233         (WebCore::InspectorStyleSheet::buildObjectForStyleSheet):
2234         (WebCore::InspectorStyleSheet::buildObjectForStyleSheetInfo):
2235         * inspector/InspectorStyleSheet.h:
2236         * inspector/front-end/AuditRules.js:
2237         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.styleSheetCallback):
2238         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun.allStylesCallback):
2239         (WebInspector.AuditRules.UnusedCssRule.prototype.doRun):
2240         * inspector/front-end/CSSStyleModel.js:
2241         (WebInspector.CSSStyleModel.prototype._styleSheetChanged.callback):
2242         (WebInspector.CSSStyleModel.prototype._styleSheetChanged):
2243         (WebInspector.CSSStyleModel.prototype._onRevert):
2244         (WebInspector.CSSStyleSheet):
2245         (WebInspector.CSSStyleSheet.prototype.setText):
2246
2247 2011-03-29  Jeremy Moskovich  <jeremy@chromium.org>
2248
2249         Reviewed by Eric Seidel.
2250
2251         Implement text-align:match-parent as -webkit-match-parent.
2252         https://bugs.webkit.org/show_bug.cgi?id=50951
2253
2254         Add support to the CSS parser.
2255
2256         Tests: fast/css/text-align-webkit-match-parent-parse.html
2257                fast/css/text-align-webkit-match-parent.html
2258
2259         * css/CSSParser.cpp:
2260         (WebCore::CSSParser::parseValue):
2261         * css/CSSStyleSelector.cpp:
2262         (WebCore::CSSStyleSelector::applyProperty):
2263         * css/CSSValueKeywords.in:
2264
2265 2011-03-29  Eric Seidel  <eric@webkit.org>
2266
2267         Reviewed by Ryosuke Niwa.
2268
2269         Rename InlineIterator::nextBreakablePosition to m_nextBreakablePosition to match modern style
2270         https://bugs.webkit.org/show_bug.cgi?id=57323
2271
2272         All of these m_nextBreakablePosition = -1 could probably be replaced with
2273         some new methods.  But I'll do that in a separate change.  Clearly
2274         m_nextBreakablePosition is just a cached value which should be cleared
2275         at the right times.  I suspect we may even fail to clear it sometimes when
2276         we should due to the current used of direct access instead of smarter functions.
2277
2278         * rendering/InlineIterator.h:
2279         (WebCore::InlineIterator::InlineIterator):
2280         (WebCore::InlineIterator::increment):
2281         * rendering/RenderBlockLineLayout.cpp:
2282         (WebCore::tryHyphenating):
2283         (WebCore::RenderBlock::findNextLineBreak):
2284
2285 2011-03-29  Jeff Miller  <jeffm@apple.com>
2286
2287         Reviewed by Jon Honeycutt.
2288
2289         Add WebCore::copyCertificateToData() on Windows
2290         https://bugs.webkit.org/show_bug.cgi?id=57296
2291
2292         Create a new win directory in platform/cf and add CertificateCFWin.cpp and CertificateCFWin.h to it.
2293
2294         * WebCore.vcproj/WebCore.vcproj: Added CertificateCFWin.cpp and CertificateCFWin.h.
2295         * WebCore.vcproj/copyForwardingHeaders.cmd: Copy all header files in \platform\cf\win\.
2296         * platform/cf/win: Added.
2297         * platform/cf/win/CertificateCFWin.cpp: Added.
2298         (WebCore::deallocCertContext): Added.
2299         (WebCore::createCertContextDeallocator): Added.
2300         (WebCore::copyCertificateToData): Added.
2301         * platform/cf/win/CertificateCFWin.h: Added.
2302
2303 2011-03-29  Eric Seidel  <eric@webkit.org>
2304
2305         Reviewed by Ryosuke Niwa.
2306
2307         Rename InlineIterator::block to m_block to match modern style
2308         https://bugs.webkit.org/show_bug.cgi?id=57321
2309
2310         I could have made m_block private, since it's only accessed in
2311         one place outside of InlineIterator (for an ASSERT).  But I chose
2312         not to do so in this change.
2313
2314         * rendering/InlineIterator.h:
2315         (WebCore::InlineIterator::InlineIterator):
2316         (WebCore::InlineIterator::increment):
2317         (WebCore::InlineBidiResolver::appendRun):
2318         * rendering/RenderBlockLineLayout.cpp:
2319         (WebCore::RenderBlock::findNextLineBreak):
2320
2321 2011-03-29  Leo Yang  <leo.yang@torchmobile.com.cn>
2322
2323         Reviewed by Nikolas Zimmermann.
2324
2325         Incorrect offset of svg <use> element which is in <symbol> element
2326         https://bugs.webkit.org/show_bug.cgi?id=57318
2327
2328         When webkit expanded a svg <symbol> element in the shadow tree it
2329         would clone the children of the <symbol>. The children may contain
2330         SVGShadowTreeContainerElement which was expanded from svg <use>
2331         element. But the clone operation would clone a
2332         SVGShadowTreeContainerElement as a svg <g> element. This resulted
2333         that updateContainerOffset wouldn't update offset for those elements
2334         which were expand from <use> elements.
2335
2336         This patch implements cloneElementWithoutAttributesAndChildren for
2337         SVGShadowTreeContainerElement to make the container clone itself
2338         correctly.
2339
2340         Test: svg/custom/use-in-symbol-with-offset.svg
2341
2342         * rendering/svg/SVGShadowTreeElements.cpp:
2343         (WebCore::SVGShadowTreeContainerElement::cloneElementWithoutAttributesAndChildren):
2344         * rendering/svg/SVGShadowTreeElements.h:
2345
2346 2011-03-29  Eric Seidel  <eric@webkit.org>
2347
2348         Reviewed by Ryosuke Niwa.
2349
2350         Rename InlineIterator::obj to m_obj to match modern style
2351         https://bugs.webkit.org/show_bug.cgi?id=57319
2352
2353         I started this rename after confusion in InlineBidiResolver::appendRun.
2354         (Which uses an "obj" local in InlineIterator.h.  It's not actually
2355         masking m_obj because it's a separate class, but I didn't realize
2356         that at the time because it's in InlineIterator.h which is itself confusing!)
2357
2358         * rendering/InlineIterator.h:
2359         (WebCore::InlineIterator::InlineIterator):
2360         (WebCore::operator==):
2361         (WebCore::operator!=):
2362         (WebCore::InlineIterator::increment):
2363         (WebCore::InlineIterator::atEnd):
2364         (WebCore::InlineIterator::current):
2365         (WebCore::InlineIterator::direction):
2366         (WebCore::InlineBidiResolver::appendRun):
2367         * rendering/RenderBlockLineLayout.cpp:
2368         (WebCore::checkMidpoints):
2369         (WebCore::RenderBlock::appendRunsForObject):
2370         (WebCore::RenderBlock::layoutInlineChildren):
2371         (WebCore::RenderBlock::matchedEndLine):
2372         (WebCore::skipNonBreakingSpace):
2373         (WebCore::RenderBlock::requiresLineBox):
2374         (WebCore::RenderBlock::skipTrailingWhitespace):
2375         (WebCore::RenderBlock::skipLeadingWhitespace):
2376         (WebCore::tryHyphenating):
2377         (WebCore::RenderBlock::findNextLineBreak):
2378
2379 2011-03-29  Pavel Feldman  <pfeldman@chromium.org>
2380
2381         Reviewed by Yury Semikhatsky.
2382
2383         Web Inspector: document Timeline domain, make timeline event types of type string.
2384         https://bugs.webkit.org/show_bug.cgi?id=57299
2385
2386         * inspector/Inspector.json:
2387         * inspector/InspectorTimelineAgent.cpp:
2388         (WebCore::InspectorTimelineAgent::pushGCEventRecords):
2389         (WebCore::InspectorTimelineAgent::start):
2390         (WebCore::InspectorTimelineAgent::stop):
2391         (WebCore::InspectorTimelineAgent::willCallFunction):
2392         (WebCore::InspectorTimelineAgent::didCallFunction):
2393         (WebCore::InspectorTimelineAgent::willDispatchEvent):
2394         (WebCore::InspectorTimelineAgent::didDispatchEvent):
2395         (WebCore::InspectorTimelineAgent::willLayout):
2396         (WebCore::InspectorTimelineAgent::didLayout):
2397         (WebCore::InspectorTimelineAgent::willRecalculateStyle):
2398         (WebCore::InspectorTimelineAgent::didRecalculateStyle):
2399         (WebCore::InspectorTimelineAgent::willPaint):
2400         (WebCore::InspectorTimelineAgent::didPaint):
2401         (WebCore::InspectorTimelineAgent::willWriteHTML):
2402         (WebCore::InspectorTimelineAgent::didWriteHTML):
2403         (WebCore::InspectorTimelineAgent::didInstallTimer):
2404         (WebCore::InspectorTimelineAgent::didRemoveTimer):
2405         (WebCore::InspectorTimelineAgent::willFireTimer):
2406         (WebCore::InspectorTimelineAgent::didFireTimer):
2407         (WebCore::InspectorTimelineAgent::willChangeXHRReadyState):
2408         (WebCore::InspectorTimelineAgent::didChangeXHRReadyState):
2409         (WebCore::InspectorTimelineAgent::willLoadXHR):
2410         (WebCore::InspectorTimelineAgent::didLoadXHR):
2411         (WebCore::InspectorTimelineAgent::willEvaluateScript):
2412         (WebCore::InspectorTimelineAgent::didEvaluateScript):
2413         (WebCore::InspectorTimelineAgent::didScheduleResourceRequest):
2414         (WebCore::InspectorTimelineAgent::willSendResourceRequest):
2415         (WebCore::InspectorTimelineAgent::willReceiveResourceData):
2416         (WebCore::InspectorTimelineAgent::didReceiveResourceData):
2417         (WebCore::InspectorTimelineAgent::willReceiveResourceResponse):
2418         (WebCore::InspectorTimelineAgent::didReceiveResourceResponse):
2419         (WebCore::InspectorTimelineAgent::didFinishLoadingResource):
2420         (WebCore::InspectorTimelineAgent::didMarkTimeline):
2421         (WebCore::InspectorTimelineAgent::didMarkDOMContentEvent):
2422         (WebCore::InspectorTimelineAgent::didMarkLoadEvent):
2423         (WebCore::InspectorTimelineAgent::addRecordToTimeline):
2424         (WebCore::InspectorTimelineAgent::didCompleteCurrentRecord):
2425         (WebCore::InspectorTimelineAgent::pushCurrentRecord):
2426         * inspector/InspectorTimelineAgent.h:
2427         (WebCore::InspectorTimelineAgent::TimelineRecordEntry::TimelineRecordEntry):
2428         * inspector/front-end/TimelineAgent.js:
2429         * inspector/front-end/TimelinePanel.js:
2430         (WebInspector.TimelinePanel.prototype.get _recordStyles):
2431         (WebInspector.TimelinePanel.prototype._createEventDivider):
2432         (WebInspector.TimelinePanel.prototype._findParentRecord):
2433         (WebInspector.TimelinePanel.prototype._innerAddRecordToTimeline):
2434         (WebInspector.TimelineDispatcher.prototype.started):
2435         (WebInspector.TimelineDispatcher.prototype.stopped):
2436         (WebInspector.TimelineDispatcher.prototype.eventRecorded):
2437         (WebInspector.TimelinePanel.FormattedRecord):
2438         (WebInspector.TimelinePanel.FormattedRecord.prototype._generatePopupContent):
2439         (WebInspector.TimelinePanel.FormattedRecord.prototype._getRecordDetails):
2440
2441 2011-03-29  Andrey Adaikin  <aandrey@google.com>
2442
2443         Reviewed by Pavel Feldman.
2444
2445         Web Inspector: Fixing live edits tests on chromium.
2446         https://bugs.webkit.org/show_bug.cgi?id=57316
2447
2448         * inspector/front-end/ScriptsPanel.js:
2449         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.editScriptSource):
2450         * inspector/front-end/SourceFrame.js:
2451         (WebInspector.SourceFrame.prototype._handleSave.didEditScriptSource):
2452         (WebInspector.SourceFrame.prototype._handleSave):
2453         (WebInspector.SourceFrameDelegate.prototype.editScriptSource):
2454
2455 2011-03-29  Pavel Podivilov  <podivilov@chromium.org>
2456
2457         Reviewed by Yury Semikhatsky.
2458
2459         Web Inspector: fix call frames positions in formatted scripts.
2460         https://bugs.webkit.org/show_bug.cgi?id=57036
2461
2462         Introduce PresentationCallFrame class that encapsulates source mapping details from UI components.
2463
2464         * inspector/front-end/CallStackSidebarPane.js:
2465         (WebInspector.CallStackSidebarPane.prototype.update.didGetSourceLocation):
2466         (WebInspector.CallStackSidebarPane.prototype.update):
2467         (WebInspector.CallStackSidebarPane.prototype.set selectedCallFrame):
2468         (WebInspector.CallStackSidebarPane.prototype._placardSelected):
2469         (WebInspector.CallStackSidebarPane.prototype._contextMenu):
2470         (WebInspector.CallStackSidebarPane.prototype._copyStackTrace):
2471         * inspector/front-end/DebuggerModel.js:
2472         (WebInspector.DebuggerModel.prototype._didEditScriptSource):
2473         (WebInspector.DebuggerModel.prototype.get debuggerPausedDetails):
2474         (WebInspector.DebuggerModel.prototype._pausedScript):
2475         * inspector/front-end/DebuggerPresentationModel.js:
2476         (WebInspector.DebuggerPresentationModel):
2477         (WebInspector.DebuggerPresentationModel.prototype.editScriptSource.didEditScriptSource):
2478         (WebInspector.DebuggerPresentationModel.prototype.editScriptSource):
2479         (WebInspector.DebuggerPresentationModel.prototype.toggleFormatSourceFiles):
2480         (WebInspector.DebuggerPresentationModel.prototype._debuggerPaused):
2481         (WebInspector.DebuggerPresentationModel.prototype._debuggerResumed):
2482         (WebInspector.DebuggerPresentationModel.prototype.set selectedCallFrame):
2483         (WebInspector.DebuggerPresentationModel.prototype.get selectedCallFrame):
2484         (WebInspector.DebuggerPresentationModel.prototype._reset):
2485         (WebInspector.PresenationCallFrame): Call frame wrapper for UI.
2486         * inspector/front-end/ScriptsPanel.js:
2487         (WebInspector.ScriptsPanel):
2488         (WebInspector.ScriptsPanel.prototype.evaluateInSelectedCallFrame):
2489         (WebInspector.ScriptsPanel.prototype._debuggerPaused.else.didGetSourceLocation):
2490         (WebInspector.ScriptsPanel.prototype._debuggerPaused):
2491         (WebInspector.ScriptsPanel.prototype._debuggerResumed):
2492         (WebInspector.ScriptsPanel.prototype._sourceFrameLoaded):
2493         (WebInspector.ScriptsPanel.prototype._callFrameSelected.didGetSourceLocation):
2494         (WebInspector.ScriptsPanel.prototype._callFrameSelected):
2495         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.evaluateInSelectedCallFrame):
2496         * inspector/front-end/SourceFile.js:
2497         (WebInspector.SourceFile.prototype.get content):
2498         * inspector/front-end/SourceFrame.js:
2499         (WebInspector.SourceFrame.prototype._createTextViewer):
2500         (WebInspector.SourceFrame.prototype.setExecutionLine):
2501         (WebInspector.SourceFrame.prototype.clearExecutionLine):
2502         (WebInspector.SourceFrame.prototype._showPopup.showObjectPopup):
2503         (WebInspector.SourceFrame.prototype._showPopup):
2504
2505 2011-03-29  Emil A Eklund  <eae@chromium.org>
2506
2507         Reviewed by Darin Adler.
2508
2509         Fix for execCommand("Delete") with an empty selection.
2510         https://bugs.webkit.org/show_bug.cgi?id=56652
2511
2512         Test: editing/execCommand/delete-empty-container.html
2513
2514         * editing/TypingCommand.cpp:
2515         (WebCore::TypingCommand::makeEditableRootEmpty): Add check for root element.
2516
2517 2011-03-29  Mikhail Naganov  <mnaganov@chromium.org>
2518
2519         Reviewed by Pavel Feldman.
2520
2521         Web Inspector: [Chromium] Refactor HeapSnapshot-related code to
2522         make sure we don't return big amounts of data to forms.
2523         https://bugs.webkit.org/show_bug.cgi?id=57227
2524
2525         * inspector/front-end/DetailedHeapshotGridNodes.js:
2526         (WebInspector.HeapSnapshotGridNode.prototype.populateChildren):
2527         (WebInspector.HeapSnapshotGenericObjectNode.prototype.get _countPercent):
2528         (WebInspector.HeapSnapshotObjectNode):
2529         (WebInspector.HeapSnapshotObjectNode.prototype._createProvider):
2530         (WebInspector.HeapSnapshotInstanceNode):
2531         (WebInspector.HeapSnapshotInstanceNode.prototype._createProvider):
2532         (WebInspector.HeapSnapshotConstructorNode.prototype._createNodesProvider):
2533         (WebInspector.HeapSnapshotConstructorNode.prototype.get _countPercent):
2534         (WebInspector.HeapSnapshotDiffNode.prototype._createNodesProvider.createProvider):
2535         (WebInspector.HeapSnapshotDiffNode.prototype._createNodesProvider):
2536         (WebInspector.HeapSnapshotDominatorObjectNode.prototype._createProvider):
2537         * inspector/front-end/DetailedHeapshotView.js:
2538         (WebInspector.HeapSnapshotContainmentDataGrid.prototype.setDataSource):
2539         (WebInspector.HeapSnapshotDominatorsDataGrid.prototype.setDataSource):
2540         * inspector/front-end/HeapSnapshot.js:
2541         (WebInspector.HeapSnapshotNode.prototype.get dominatorIndex):
2542         (WebInspector.HeapSnapshotNode.prototype.get retainers):
2543         (WebInspector.HeapSnapshot):
2544         (WebInspector.HeapSnapshot.prototype.get _allNodes):
2545         (WebInspector.HeapSnapshot.prototype.get nodeCount):
2546         (WebInspector.HeapSnapshot.prototype.get rootNodeIndex):
2547         (WebInspector.HeapSnapshot.prototype.hasId):
2548         (WebInspector.HeapSnapshot.prototype.get nodeIds):
2549         (WebInspector.HeapSnapshot.prototype._retainersForNode):
2550         (WebInspector.HeapSnapshot.prototype._buildRetainers):
2551         (WebInspector.HeapSnapshot.prototype._buildAggregates):
2552         (WebInspector.HeapSnapshot.prototype._buildAggregatesIndexes):
2553         (WebInspector.HeapSnapshot.prototype._buildIdsList):
2554         (WebInspector.HeapSnapshot.prototype._buildNodeIndex):
2555         (WebInspector.HeapSnapshotFilteredOrderedIterator):
2556         (WebInspector.HeapSnapshotFilteredOrderedIterator.prototype.next):
2557         (WebInspector.HeapSnapshotEdgesProvider):
2558         (WebInspector.HeapSnapshotNodesProvider):
2559
2560 2011-03-29  Mikhail Naganov  <mnaganov@chromium.org>
2561
2562         Reviewed by Pavel Feldman.
2563
2564         Web Inspector: [Chromium] Fix detailed heap snapshots UI.
2565         https://bugs.webkit.org/show_bug.cgi?id=57235
2566
2567         Fix two problems:
2568           1. Text color of grid cells under selection needs to be white, otherwise it's unreadable for some colors;
2569           2. Long strings need to be truncated in grid, their contents can be shown on hover.
2570
2571         * inspector/front-end/DetailedHeapshotView.js:
2572         (WebInspector.DetailedHeapshotView.prototype._getHoverAnchor):
2573         (WebInspector.DetailedHeapshotView.prototype._showStringContentPopup):
2574         * inspector/front-end/heapProfiler.css:
2575         (.detailed-heapshot-view .console-formatted-string):
2576         (.detailed-heapshot-view .data-grid tr.selected *):
2577         (.detailed-heapshot-view .data-grid:focus tr.selected *):
2578
2579 2011-03-29  Andrey Adaikin  <aandrey@google.com>
2580
2581         Reviewed by Yury Semikhatsky.
2582
2583         Web Inspector: Highlight visible lines first
2584         https://bugs.webkit.org/show_bug.cgi?id=57013
2585
2586         * inspector/front-end/TextViewer.js:
2587         (WebInspector.TextEditorChunkedPanel.prototype._findFirstVisibleChunkNumber):
2588         (WebInspector.TextEditorChunkedPanel.prototype._findVisibleChunks):
2589         (WebInspector.TextEditorChunkedPanel.prototype._findFirstVisibleLineNumber.compareLineRowOffsetTops):
2590         (WebInspector.TextEditorChunkedPanel.prototype._findFirstVisibleLineNumber):
2591         (WebInspector.TextEditorMainPanel.prototype._paintScheduledLines):
2592         (WebInspector.TextEditorMainPanel.prototype._paintLines):
2593         (WebInspector.TextEditorMainPanel.prototype._paintLineChunks):
2594         (WebInspector.TextEditorMainPanel.prototype._paintLine):
2595         (WebInspector.TextEditorMainChunk.prototype.set expanded):
2596
2597 2011-03-29  Emil A Eklund  <eae@chromium.org>
2598
2599         Reviewed by Dimitri Glazkov.
2600
2601         Relative mouse coordinates recalculated for each target
2602         https://bugs.webkit.org/show_bug.cgi?id=57130
2603
2604         Calculate relative coordinates lazily for mouse events instead of doing
2605         it for each target. Speeds up dispatching of mouse events in deep dom
2606         structures significantly, O(n^2) to O(n).
2607
2608         Also fixes https://bugs.webkit.org/show_bug.cgi?id=34973
2609
2610         Tests: fast/events/mouse-relative-position.html
2611                perf/mouse-event.html
2612
2613         * dom/Event.cpp:
2614         (WebCore::Event::setTarget):
2615         * dom/MouseRelatedEvent.cpp:
2616         (WebCore::MouseRelatedEvent::MouseRelatedEvent):
2617         (WebCore::MouseRelatedEvent::initCoordinates):
2618         (WebCore::pageZoomFactor):
2619         (WebCore::MouseRelatedEvent::receivedTarget):
2620         (WebCore::MouseRelatedEvent::computeRelativePosition):
2621         (WebCore::MouseRelatedEvent::layerX):
2622         (WebCore::MouseRelatedEvent::layerY):
2623         (WebCore::MouseRelatedEvent::offsetX):
2624         (WebCore::MouseRelatedEvent::offsetY):
2625         * dom/MouseRelatedEvent.h:
2626         * dom/UIEvent.cpp:
2627         (WebCore::UIEvent::layerX):
2628         (WebCore::UIEvent::layerY):
2629         * dom/UIEvent.h:
2630
2631 2011-03-29  Emil A Eklund  <eae@chromium.org>
2632
2633         Reviewed by Darin Adler.
2634
2635         getComputedStyle counterIncrement crash @ WebCore::counterToCSSValue
2636         https://bugs.webkit.org/show_bug.cgi?id=57266
2637
2638         Add null check to counterToCSSValue.
2639
2640         Test: fast/css/getComputedStyle/counterIncrement-without-counter.html
2641
2642         * css/CSSComputedStyleDeclaration.cpp:
2643         (WebCore::counterToCSSValue):
2644
2645 2011-03-29  Gavin Peters  <gavinp@chromium.org>
2646
2647         Reviewed by Tony Gentilcore.
2648
2649         Implement onerror events for <link rel=prefetch>
2650         https://bugs.webkit.org/show_bug.cgi?id=57182
2651
2652         These events are equired on link elements, see
2653         http://dev.w3.org/html5/spec/Overview.html#the-link-element
2654
2655         After a discussion in WebKit-dev about the direction of prefetch in the loader, and about a path
2656         to adding the Link header, we decided to look at making onerror, onload and onbeforeload events
2657         more uniformly supported.  See the thread at
2658         https://lists.webkit.org/pipermail/webkit-dev/2011-February/016034.html .
2659
2660         It turned out that part of adding onerror for link prefetch was to make the top CachedResource less
2661         abstract.  It was pure virtual until prefetch became the first consumer to use an unspecialised
2662         implementation, and this CL continues that by adding a default checkNotify method to it.  As it
2663         happens there were already two subclasses using what amounted to the generic checkNotify, so I
2664         also removed those, buying us some code cleanup with the change.
2665
2666         Test: fast/dom/HTMLLinkElement/prefetch-onerror.html
2667
2668         * html/HTMLLinkElement.cpp:
2669         (WebCore::HTMLLinkElement::parseMappedAttribute):
2670         (WebCore::HTMLLinkElement::onloadTimerFired):
2671         (WebCore::HTMLLinkElement::notifyFinished):
2672         * loader/cache/CachedImage.cpp:
2673         * loader/cache/CachedImage.h:
2674         * loader/cache/CachedResource.cpp:
2675         (WebCore::CachedResource::checkNotify):
2676         (WebCore::CachedResource::data):
2677         (WebCore::CachedResource::error):
2678         * loader/cache/CachedResource.h:
2679         * loader/cache/CachedScript.cpp:
2680         * loader/cache/CachedScript.h:
2681
2682 2011-03-29  Eric Seidel  <eric@webkit.org>
2683
2684         Reviewed by Ryosuke Niwa.
2685
2686         Add support for parsing unicode-bidi: -webkit-isolate
2687         https://bugs.webkit.org/show_bug.cgi?id=57181
2688
2689         Test: css3/unicode-bidi-insolate-parse.html
2690
2691         * WebCore.xcodeproj/project.pbxproj:
2692         * css/CSSParser.cpp:
2693         (WebCore::CSSParser::parseValue):
2694         * css/CSSPrimitiveValueMappings.h:
2695         (WebCore::CSSPrimitiveValue::CSSPrimitiveValue):
2696         (WebCore::CSSPrimitiveValue::operator EUnicodeBidi):
2697         * css/CSSValueKeywords.in:
2698         * rendering/style/RenderStyleConstants.h:
2699
2700 2011-03-29  Patrick Gansterer  <paroga@webkit.org>
2701
2702         Unreviewed WinCE build fix for r82193.
2703
2704         * platform/wince/FileSystemWinCE.cpp:
2705         (WebCore::openTemporaryFile):
2706
2707 2011-03-28  Sheriff Bot  <webkit.review.bot@gmail.com>
2708
2709         Unreviewed, rolling out r82198.
2710         http://trac.webkit.org/changeset/82198
2711         https://bugs.webkit.org/show_bug.cgi?id=57304
2712
2713         Broke Chromium Win build. (Requested by dave_levin on
2714         #webkit).
2715
2716         * platform/image-decoders/png/PNGImageDecoder.cpp:
2717         (WebCore::PNGImageDecoder::headerAvailable):
2718         (WebCore::PNGImageDecoder::rowAvailable):
2719
2720 2011-03-28  Ofri Wolfus  <ofri@google.com>
2721
2722         Reviewed by Eric Seidel.
2723
2724         RTL: Select elements with a size attribute are always left aligned.
2725         https://bugs.webkit.org/show_bug.cgi?id=50928
2726
2727         Added support for alignment in RenderListBox.
2728
2729         Test: fast/forms/listbox-bidi-align.html
2730
2731         * rendering/RenderListBox.cpp:
2732         (WebCore::itemOffsetForAlignment):
2733         (WebCore::RenderListBox::paintItemForeground): Add support for alignment and directionality.
2734
2735 2011-03-28  Kwang Yul Seo  <skyul@company100.net>
2736
2737         Reviewed by Benjamin Poulain.
2738
2739         [Qt] Change TextureMapperVideoLayer to TextureMapperMediaLayer
2740         https://bugs.webkit.org/show_bug.cgi?id=57142
2741
2742         TextureMapperMediaLayer is a better name here because both video and plugins use this layer.
2743         Remove ENABLE(VIDEO) guard.
2744
2745         * platform/graphics/qt/MediaPlayerPrivateQt.cpp:
2746         * platform/graphics/qt/MediaPlayerPrivateQt.h:
2747         * platform/graphics/texmap/GraphicsLayerTextureMapper.cpp:
2748         (WebCore::GraphicsLayerTextureMapper::setContentsToMedia):
2749         * platform/graphics/texmap/TextureMapperNode.h:
2750         * platform/graphics/texmap/TextureMapperPlatformLayer.h:
2751         (WebCore::TextureMapperMediaLayer::layerType):
2752
2753 2011-03-28  Thomas Klausner  <tk@giga.or.at>
2754
2755         Reviewed by David Levin.
2756
2757         png-1.5 fixes
2758         https://bugs.webkit.org/show_bug.cgi?id=54406
2759
2760         Fix compilation with png-1.5: struct members were hidden, and
2761         a new API to terminate data processing was added (especially for
2762         WebKit).
2763
2764         Compilation fixes, so no new tests.
2765
2766         * platform/image-decoders/png/PNGImageDecoder.cpp:
2767         (WebCore::PNGImageDecoder::headerAvailable):
2768         (WebCore::PNGImageDecoder::rowAvailable):
2769
2770 2011-03-28  Kwang Yul Seo  <skyul@company100.net>
2771
2772         Reviewed by Adam Barth.
2773
2774         Replace fprintf(stderr, ...) with LOG_ERROR
2775         https://bugs.webkit.org/show_bug.cgi?id=57216
2776
2777         LOG_ERROR is a better choice here.
2778
2779         * bridge/jni/v8/JavaClassV8.cpp:
2780         (JavaClass::JavaClass):
2781
2782 2011-03-28  Steve Block  <steveblock@google.com>
2783
2784         Reviewed by Jeremy Orlow.
2785
2786         Add a new JavaValue to type to represent a Java value in the Java bridge
2787         https://bugs.webkit.org/show_bug.cgi?id=57022
2788
2789         This change introduces a new JavaValue type and uses it in place of jvalue
2790         in the conversions to and from JavaNPObject used in the V8 Java bridge.
2791
2792         Refactoring only, no new tests.
2793
2794         * WebCore.gypi:
2795         * bridge/jni/JNIUtility.cpp:
2796         (JSC::Bindings::javaTypeFromClassName):
2797         (JSC::Bindings::signatureFromJavaType):
2798         (JSC::Bindings::getJNIField):
2799         (JSC::Bindings::callJNIMethod):
2800         * bridge/jni/JavaType.h:
2801         * bridge/jni/v8/JNIUtilityPrivate.cpp:
2802         (JSC::Bindings::convertNPVariantToJavaValue):
2803         (JSC::Bindings::convertJavaValueToNPVariant):
2804         (JSC::Bindings::jvalueToJavaValue):
2805         (JSC::Bindings::javaValueToJvalue):
2806         * bridge/jni/v8/JNIUtilityPrivate.h:
2807         * bridge/jni/v8/JavaNPObjectV8.cpp:
2808         (JSC::Bindings::JavaNPObjectInvoke):
2809         (JSC::Bindings::JavaNPObjectGetProperty):
2810         * bridge/jni/v8/JavaValueV8.h: Added.
2811         (JSC::Bindings::JavaValue::JavaValue):
2812
2813 2011-03-28  Patrick Gansterer  <paroga@webkit.org>
2814
2815         Reviewed by Darin Adler.
2816
2817         Use String instead of CString as return value of openTemporaryFile
2818         https://bugs.webkit.org/show_bug.cgi?id=55332
2819
2820         We usually store all paths as UTF-16. Do this for temporary files too.
2821
2822         * WebCore.exp.in
2823         * platform/FileSystem.h:
2824         * platform/android/FileSystemAndroid.cpp:
2825         * platform/brew/FileSystemBrew.cpp:
2826         * platform/efl/FileSystemEfl.cpp:
2827         * platform/gtk/FileSystemGtk.cpp:
2828         * platform/haiku/FileSystemHaiku.cpp:
2829         * platform/mac/FileSystemMac.mm:
2830         * platform/qt/FileSystemQt.cpp:
2831         * platform/win/FileSystemWin.cpp:
2832         * platform/wince/FileSystemWinCE.cpp:
2833         * platform/wx/FileSystemWx.cpp:
2834         * plugins/PluginStream.cpp:
2835         (WebCore::PluginStream::destroyStream):
2836         * plugins/PluginStream.h:
2837
2838 2011-03-28  Jeff Johnson  <opendarwin@lapcatsoftware.com>
2839
2840         Reviewed by Pavel Feldman.
2841
2842         Web Inspector: empty, non-functional window
2843         https://bugs.webkit.org/show_bug.cgi?id=56354
2844
2845         Check whether DOM local storage is enabled
2846         before attempting to access window.localStorage.
2847
2848         No new tests.
2849
2850         * inspector/front-end/Settings.js:
2851         (WebInspector.Settings.prototype.findSettingForAllProjects):
2852         (WebInspector.Settings.prototype._get):
2853         (WebInspector.Settings.prototype._set):
2854
2855 2011-03-28  Beth Dakin  <bdakin@apple.com>
2856
2857         Reviewed by Darin Adler.
2858
2859         Fix for https://bugs.webkit.org/show_bug.cgi?id=57286 Alternative fix for: 
2860         Horizontal scroller stops appearing after going Forward
2861         -and corresponding-
2862         <rdar://problem/9026946>
2863
2864         This patch rolls out revision 79053 and fixes the same bug in a  better way.
2865
2866         New function resetScrollbarsAndClearContentsSize() calls resetScrollbars() and then 
2867         sets the contents size to 0. This is called when a document is going into the page 
2868         cache.
2869         * dom/Document.cpp:
2870         (WebCore::Document::setInPageCache):
2871         (WebCore::FrameView::resetScrollbarsAndClearContentsSize):
2872
2873         Roll-out of 79053.
2874         * history/CachedFrame.cpp:
2875         (WebCore::CachedFrameBase::restore):
2876         * page/FrameView.cpp:
2877         (WebCore::FrameView::FrameView):
2878         (WebCore::FrameView::reset):
2879         (WebCore::FrameView::layout):
2880         * page/FrameView.h:
2881
2882 2011-03-28  Ojan Vafai  <ojan@chromium.org>
2883
2884         Reviewed by Antti Koivisto.
2885
2886         fix style sharing with :any and sibling selectors
2887         https://bugs.webkit.org/show_bug.cgi?id=57211
2888
2889         Test: fast/css/sibling-selectors.html
2890
2891         * css/CSSStyleSelector.cpp:
2892         (WebCore::collectFeaturesFromList):
2893
2894 2011-03-27  Ojan Vafai  <ojan@chromium.org>
2895
2896         Reviewed by Antti Koivisto.
2897
2898         fix :-webkit-any(:last-child)
2899         https://bugs.webkit.org/show_bug.cgi?id=57207
2900
2901         We were passing the wrong arguments to checkSelector. Also, we were not
2902         passing through the encounteredLink bool.
2903
2904         * css/CSSStyleSelector.cpp:
2905         (WebCore::CSSStyleSelector::SelectorChecker::checkSelector):
2906         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
2907         * css/CSSStyleSelector.h:
2908
2909 2011-03-27  Ojan Vafai  <ojan@chromium.org>
2910
2911         Reviewed by Antti Koivisto.
2912
2913         fix :-webkit-any(:last-child)
2914         https://bugs.webkit.org/show_bug.cgi?id=57207
2915
2916         We were passing the wrong arguments to checkSelector. Also, we were not
2917         passing through the encounteredLink bool.
2918
2919         * css/CSSStyleSelector.cpp:
2920         (WebCore::CSSStyleSelector::SelectorChecker::checkSelector):
2921         (WebCore::CSSStyleSelector::SelectorChecker::checkOneSelector):
2922         * css/CSSStyleSelector.h:
2923
2924 2011-03-28  Maciej Stachowiak  <mjs@apple.com>
2925
2926         Reviewed by Darin Adler.
2927
2928         REGRESSION(r82152): fast/dom/HTMLAnchorElement/set-href-attribute-pathname.html
2929         https://bugs.webkit.org/show_bug.cgi?id=57291
2930
2931         * platform/KURL.cpp:
2932         (WebCore::KURL::parse): Instead of considering URLs with
2933         credentials but no host invalid, consider them to have a host
2934         ending in @ (which fails down the line)/
2935
2936 2011-03-28  Kent Tamura  <tkent@chromium.org>
2937
2938         Reviewed by Dimitri Glazkov.
2939
2940         Fix some problems of the appearance of form validation message bubble.
2941         https://bugs.webkit.org/show_bug.cgi?id=57208
2942
2943         No new tests. Validation message bubble appearance is not testable
2944         because it depends on a timer.
2945
2946         * css/html.css:
2947         (::-webkit-validation-bubble):
2948         (::-webkit-validation-bubble-message):
2949         (::-webkit-validation-bubble-arrow):
2950         (::-webkit-validation-bubble-arrow-clipper):
2951           - Explicitly set margin, padding, and color.
2952           - Make the shadow darker.
2953           - Make the background color darker.
2954           - Make opacity larger.
2955           - Make the border color lighter.
2956           - Add inset shadows
2957           - Change the implementation of an arrow.
2958             Stop making a right triangle by the border trick.
2959             Use -webkit-transform instead.
2960           - Make min-width workable by changing display property of
2961             -webkit-validation-bubble to "inline-block".
2962         * html/ValidationMessage.cpp:
2963         (WebCore::ValidationMessage::buildBubbleTree):
2964           Change the node structure. Before this change, -webkit-validation-bubble
2965           had three DIVs inside. After this change, it has two DIVs;
2966           -webkit-validation-bubble-arrow-clipper and
2967           -webkit-validation-bubble-message, and
2968           -webkit-validation-bubble-arrow-clipper contains
2969           -webkit-validation-bubble-arrow.
2970
2971 2011-03-28  Enrica Casucci  <enrica@apple.com>
2972
2973         Reviewed by Sam Weinig.
2974
2975         REGRESSION: Can't enter pasted with context or Edit menu text in search or address field in the browser.
2976         https://bugs.webkit.org/show_bug.cgi?id=57275
2977         <rdar://problem/8246691>
2978
2979         We need to classify cut and paste actions as user typing actions even when
2980         the action is triggered by a context menu selection to
2981         allow the propagation of the textDidChangeInTextField event.
2982
2983         * editing/EditorCommand.cpp:
2984         The following methods have been modified to properly set up
2985         the UserTypingGestureAction when the command source is the
2986         menu or a key binding sequence.
2987         (WebCore::executeCut):
2988         (WebCore::executePaste):
2989         (WebCore::executePasteAndMatchStyle):
2990         (WebCore::executePasteAsPlainText):
2991         (WebCore::executeDelete):
2992         * page/ContextMenuController.cpp:
2993         (WebCore::ContextMenuController::contextMenuItemSelected): Changed to
2994         call execute command instead of referring to the specific method in
2995         the editor class.
2996
2997 2011-03-28  Oliver Hunt  <oliver@apple.com>
2998
2999         Reviewed by Geoffrey Garen.
3000
3001         instanceof Array test fails when using iframes
3002         https://bugs.webkit.org/show_bug.cgi?id=17250
3003
3004         Update for new function and date apis
3005
3006         Test: fast/js/js-constructors-use-correct-global.html
3007
3008         * WebCore.xcodeproj/project.pbxproj:
3009         * bindings/js/JSDOMBinding.cpp:
3010         (WebCore::jsDateOrNull):
3011         * bindings/js/JSLazyEventListener.cpp:
3012         (WebCore::JSLazyEventListener::initializeJSFunction):
3013
3014 2011-03-28  Beth Dakin  <bdakin@apple.com>
3015
3016         Reviewed by Darin Adler.
3017
3018         Fix for https://bugs.webkit.org/show_bug.cgi?id=57124 When the scroller style is 
3019         changed via delegate method, the page needs a full relayout and repaint
3020         -and corresponding-
3021         <rdar://problem/9059129>
3022
3023         Call into WebKitSystemInterface to associate the new painter with the existing 
3024         painter controller. Reset the scrollbar frame rects to the new thickness -- normally 
3025         this only happens when a scrollbar is created, so we have to reset the thickness 
3026         here to pick up the new theme thickness. Finally, force a full relayout and style 
3027         recall with setNeedsRecalcStyleInAllFrames()
3028         * platform/mac/ScrollAnimatorMac.mm:
3029         (-[ScrollbarPainterControllerDelegate scrollerImpPair:updateScrollerStyleForNewRecommendedScrollerStyle:]):
3030
3031         setNeedsRecalcStyleInAllFrames() used to be a static method in Settings.cpp. This 
3032         patch moves it to be a member function on Page so that it can be called from 
3033         FrameView when the scrollbar style changes.
3034         * page/FrameView.cpp:
3035         (WebCore::FrameView::setNeedsRecalcStyleInAllFrames):
3036         * page/FrameView.h:
3037         * page/Page.cpp:
3038         (WebCore::Page::setNeedsRecalcStyleInAllFrames):
3039         * page/Page.h:
3040         * page/Settings.cpp:
3041         (WebCore::Settings::setStandardFontFamily):
3042         (WebCore::Settings::setFixedFontFamily):
3043         (WebCore::Settings::setSerifFontFamily):
3044         (WebCore::Settings::setSansSerifFontFamily):
3045         (WebCore::Settings::setCursiveFontFamily):
3046         (WebCore::Settings::setFantasyFontFamily):
3047         (WebCore::Settings::setMinimumFontSize):
3048         (WebCore::Settings::setMinimumLogicalFontSize):
3049         (WebCore::Settings::setDefaultFontSize):
3050         (WebCore::Settings::setDefaultFixedFontSize):
3051         (WebCore::Settings::setTextAreasAreResizable):
3052         (WebCore::Settings::setAuthorAndUserStylesEnabled):
3053         (WebCore::Settings::setFontRenderingMode):
3054         (WebCore::Settings::setAcceleratedCompositingEnabled):
3055         (WebCore::Settings::setShowDebugBorders):
3056         (WebCore::Settings::setShowRepaintCounter):
3057         * platform/ScrollableArea.h:
3058         (WebCore::ScrollableArea::setNeedsRecalcStyleInAllFrames):
3059
3060 2011-03-28  Dirk Pranke  <dpranke@chromium.org>
3061
3062         RS=Tony Chang.
3063
3064         r81977 moved FontPlatformData.h from
3065         WebCore/platform/graphics/cocoa to platform/graphics. This
3066         change updates the chromium build accordingly.
3067
3068         https://bugs.webkit.org/show_bug.cgi?id=57281
3069
3070         * platform/graphics/chromium/CrossProcessFontLoading.mm:
3071
3072 2011-03-28  Jer Noble  <jer.noble@apple.com>
3073
3074         Reviewed by Darin Adler.
3075
3076         MediaPlayerPrivateAVFoundation should report that it supportsFullScreen()
3077         https://bugs.webkit.org/show_bug.cgi?id=57249
3078
3079         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
3080         (WebCore::MediaPlayerPrivateAVFoundation::supportsFullscreen):
3081         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
3082
3083 2011-03-28  Jer Noble  <jer.noble@apple.com>
3084
3085         Reviewed by Darin Adler.
3086
3087         AVFoundation can indeed support full screen.
3088
3089         MediaPlayerPrivateAVFoundation should report that it supportsFullScreen()
3090         https://bugs.webkit.org/show_bug.cgi?id=57249
3091
3092         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
3093         (WebCore::MediaPlayerPrivateAVFoundation::supportsFullscreen): Return true if using
3094             the new full screen APIs.
3095         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.h:
3096
3097 2011-03-28  Eric Carlson  <eric.carlson@apple.com>
3098
3099         Reviewed by Darin Adler.
3100
3101         http streams don't always display video with AVFoundation backend
3102         https://bugs.webkit.org/show_bug.cgi?id=57203
3103
3104         No new tests, we don't currently have tests for http live streams. Changes verified manually.
3105
3106         * platform/graphics/MediaPlayer.cpp:
3107         (WebCore::MediaPlayer::MediaPlayer): Initialize m_shouldPrepareToRender.
3108         (WebCore::MediaPlayer::loadWithNextMediaEngine): Call prepareForRendering on new engine
3109             if m_shouldPrepareToRender is set.
3110         (WebCore::MediaPlayer::prepareForRendering): Set m_shouldPrepareToRender.
3111         * platform/graphics/MediaPlayer.h:
3112
3113         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundation.cpp:
3114         (WebCore::MediaPlayerPrivateAVFoundation::isReadyForVideoSetup): Don't return true until
3115             m_isAllowedToRender has been set.
3116         (WebCore::MediaPlayerPrivateAVFoundation::prepareForRendering): Always call setUpVideoRendering,
3117             it has logic to figure out when setup is required.
3118         (WebCore::MediaPlayerPrivateAVFoundation::updateStates): Call setUpVideoRendering when we aren't
3119             using the preferred rendering mode because if we get a file's metadata between the
3120             time supportsAcceleratedRendering() and paint() are called, we will allocate a software
3121             renderer even when we prefer a layer backed renderer.
3122         (WebCore::MediaPlayerPrivateAVFoundation::movieLoadType): Return "unknown" until we have metadata.
3123
3124         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.h:
3125         * platform/graphics/avfoundation/MediaPlayerPrivateAVFoundationObjC.mm:
3126         (WebCore::MediaPlayerPrivateAVFoundationObjC::cancelLoad): Use itemKVOProperties() instead of
3127             an explicit list of key path names.
3128         (WebCore::MediaPlayerPrivateAVFoundationObjC::createAVPlayerForURL): Ditto.
3129         (WebCore::MediaPlayerPrivateAVFoundationObjC::beginLoadingMetadata): metadataKeyNames renamed
3130             to assetMetadataKeyNames, return an NSArray instead of a CFArrayRef since that is what the
3131             callers need.
3132         (WebCore::MediaPlayerPrivateAVFoundationObjC::platformDuration): Return the duration of the 
3133             player item, not the asset, because AVAsset.duration always returns an indefinite time
3134             for all streaming files.
3135         (WebCore::MediaPlayerPrivateAVFoundationObjC::assetStatus): metadataKeyNames renamed
3136             to assetMetadataKeyNames.
3137         (WebCore::MediaPlayerPrivateAVFoundationObjC::paintCurrentFrameInContext): Do nothing until
3138             metadata is available.
3139         (WebCore::MediaPlayerPrivateAVFoundationObjC::paint): Ditto.
3140         (WebCore::MediaPlayerPrivateAVFoundationObjC::tracksChanged): Split size calculation logic off
3141             into sizeChanged().
3142         (WebCore::MediaPlayerPrivateAVFoundationObjC::sizeChanged): New. Use AVPlayerItem.presentationSize
3143             until tracks is non-NULL so we have a size as early as possible.
3144         (WebCore::MediaPlayerPrivateAVFoundationObjC::assetMetadataKeyNames): Renamed from metadataKeyNames.
3145         (WebCore::MediaPlayerPrivateAVFoundationObjC::itemKVOProperties): New, return an array of
3146             KVO observable properties.
3147         (-[WebCoreAVFMovieObserver observeValueForKeyPath:ofObject:change:context:]): Respond to 
3148             presentationSize change.
3149
3150 2011-03-28  Anders Carlsson  <andersca@apple.com>
3151
3152         Reviewed by Sam Weinig.
3153
3154         Search field focus ring is missing
3155         https://bugs.webkit.org/show_bug.cgi?id=57270
3156         <rdar://problem/8765555>
3157
3158         Add an _automaticFocusRingDisabled method which returns YES.
3159
3160         * platform/mac/ThemeMac.mm:
3161         (-[WebCoreFlippedView _automaticFocusRingDisabled]):
3162
3163 2011-03-28  Dimitri Glazkov  <dglazkov@chromium.org>
3164
3165         Reviewed by Darin Adler.
3166
3167         Move more events to EventDispatcher.
3168         https://bugs.webkit.org/show_bug.cgi?id=57247
3169
3170         No functional changes, covered by existing tests.
3171
3172         * dom/EventDispatcher.cpp:
3173         (WebCore::eventTargetRespectingSVGTargetRules): Made a static function,
3174             since it's not used anywhere outside of the EventDispatcher.
3175         (WebCore::EventDispatcher::dispatchScopedEvent): Moved from Node.cpp.
3176         (WebCore::EventDispatcher::dispatchKeyEvent): Ditto.
3177         (WebCore::EventDispatcher::dispatchWheelEvent): Ditto.
3178         (WebCore::EventDispatcher::dispatchEvent): Changed to use eventTargetRespectingSVGTargetRules
3179             as a static function.
3180         * dom/EventDispatcher.h: Updated decls.
3181         * dom/Node.cpp:
3182         (WebCore::Node::dispatchScopedEvent): Replaced with calling EventDispatcher.
3183         (WebCore::Node::dispatchKeyEvent): Ditto.
3184         (WebCore::Node::dispatchWheelEvent): Ditto.
3185
3186 2011-03-28  Adele Peterson  <adele@apple.com>
3187
3188         Reviewed by Eric Seidel.
3189
3190         Fix for <rdar://problem/9112694> REGRESSION (r79411): "Check grammar with spelling" context menu doesn't check as you type
3191         https://bugs.webkit.org/show_bug.cgi?id=57173
3192
3193         Test: editing/spelling/grammar.html
3194
3195         * WebCore.exp.in: Add symbol for new selectionStartHasMarkerFor method.
3196         * editing/Editor.cpp:
3197         (WebCore::Editor::markAllMisspellingsAndBadGrammarInRanges): Every use of paragraph is specific to spelling or grammar, 
3198          so to avoid confusion, we should explicitly use spellingParagraph or grammarParagraph.  In the case of this bug, 
3199          when we're consider ambiguous boundary characters (characters that could indicate word boundaries, but are used 
3200          in the middle of words too, like apostrophes), we should use the use the spellingParagraph since the spellingParagraph 
3201          is the only one operated on when this information is used.
3202          (WebCore::Editor::selectionStartHasMarkerFor): Changed from selectionStartHasSpellingMarkerFor so it can check for grammar as well as spelling.
3203         * editing/Editor.h:
3204
3205 2011-03-28  Dan Bernstein  <mitz@apple.com>
3206
3207         Reviewed by Darin Adler.
3208
3209         <rdar://problem/8895977> REGRESSION: multicol crashes with positioned elements
3210         https://bugs.webkit.org/show_bug.cgi?id=48983
3211
3212         Test: fast/multicol/paginated-layer-crash.html
3213
3214         * rendering/RenderLayer.cpp:
3215         (WebCore::RenderLayer::paintPaginatedChildLayer): Bring the logic for finding pagintating layers
3216         into sync with updatePagination() after r68069.
3217         (WebCore::RenderLayer::hitTestPaginatedChildLayer): Ditto.
3218
3219 2011-03-28  Maciej Stachowiak  <mjs@apple.com>
3220
3221         Reviewed by Darin Adler' .
3222
3223         URLSs with non-empty username but empty hostname treat first path segment as hostname, potentially enabling XSS
3224         https://bugs.webkit.org/show_bug.cgi?id=57220
3225
3226         Test: http/tests/uri/username-with-no-hostname.html
3227
3228         * platform/KURL.cpp:
3229         (WebCore::hostPortIsEmptyButUserPassIsNot):
3230         (WebCore::KURL::parse):
3231
3232 2011-03-28  Adam Barth  <abarth@webkit.org>
3233
3234         Reviewed by Eric Seidel.
3235
3236         script-src should block inline event handlers
3237         https://bugs.webkit.org/show_bug.cgi?id=57212
3238
3239         I considered wrapping this into the canExecute check, but that approach
3240         would require passing that function a bunch of context information to
3241         behave correctly once we add support for the "options" directive that
3242         re-enables these features.
3243
3244         Test: http/tests/security/contentSecurityPolicy/script-src-none-inline-event.html
3245
3246         * bindings/js/JSLazyEventListener.cpp:
3247         (WebCore::JSLazyEventListener::initializeJSFunction):
3248             - This function was a mess.  I couldn't resist cleaning it up a
3249               bunch.  Notice that we ASSERT at the beginning of the function
3250               that scriptExecutionContext is a document and that both ways of
3251               getting the global object are the same when document->frame() is
3252               non-zero because the document must be active and there is a
3253               one-to-one relation between Frames and active Documents.
3254         * bindings/v8/V8LazyEventListener.cpp:
3255         (WebCore::V8LazyEventListener::prepareListenerObject):
3256         * page/ContentSecurityPolicy.cpp:
3257         (WebCore::ContentSecurityPolicy::allowInlineEventHandlers):
3258         * page/ContentSecurityPolicy.h:
3259
3260 2011-03-28  Jeff Miller  <jeffm@apple.com>
3261
3262         Reviewed by Adam Roben.
3263
3264         ResourceError::certificate() should return a PCCERT_CONTEXT
3265         https://bugs.webkit.org/show_bug.cgi?id=57262
3266
3267         * platform/network/cf/ResourceError.h: certificate() now returns a PCCERT_CONTEXT.
3268         * platform/network/cf/ResourceErrorCF.cpp:
3269         (WebCore::ResourceError::certificate): Added.
3270
3271 2011-03-28  David Hyatt  <hyatt@apple.com>
3272
3273         Reviewed by Simon Fraser and Darin Adler.
3274
3275         https://bugs.webkit.org/show_bug.cgi?id=57221, memory corruption/crashes when positioned objects
3276         occur at the end of a line.
3277         
3278         The old code and new code for dealing with a trailing space object midpoint manipulated a raw
3279         array instead of the Vector. Otherwise this corruption would have been caught prior to check-in.
3280         
3281         I have patched the code to only go through the Vector and to make it handle the case that led to
3282         the corruption. Trailing positioned objects can occur both prior to and following the trailing space
3283         object's midpoint, so we have to be prepared to deal with both cases.
3284         
3285         This is already tested by fast/block/positioning/052.html, and that test now properly progresses
3286         like the other positioning tests did.
3287
3288         * rendering/RenderBlockLineLayout.cpp:
3289         (WebCore::RenderBlock::findNextLineBreak):
3290
3291 2011-03-28  Andrei Popescu  <andreip@google.com>
3292
3293         Reviewed by Steve Block.
3294
3295         V8IDBKeyCustom.cpp does not compile with INDEXED_DATABASE disabled
3296         https://bugs.webkit.org/show_bug.cgi?id=57100
3297
3298         Close the ENABLE guard and the namespace in the right order.
3299
3300         No new tests, just cleanup.
3301
3302         * bindings/v8/custom/V8IDBAnyCustom.cpp:
3303         * bindings/v8/custom/V8IDBKeyCustom.cpp:
3304
3305 2011-03-28  Jeff Miller  <jeffm@apple.com>
3306
3307         Reviewed by Adam Roben.
3308
3309         Include certificate when sending a WebCore::ResourceError to UI process on Windows
3310         https://bugs.webkit.org/show_bug.cgi?id=57195
3311
3312         Add support for tracking the certificate in WebCore::ResourceError.
3313
3314         * platform/network/ResourceErrorBase.cpp:
3315         (WebCore::ResourceErrorBase::copy): Call platformCopy() to copy platform-specific fields.
3316         * platform/network/ResourceErrorBase.h:
3317         (WebCore::ResourceErrorBase::platformCopy): Added.
3318         * platform/network/cf/ResourceError.h: Added constructor that takes certificate data, shadowed platformCopy, added m_certificate.
3319         (WebCore::ResourceError::certificate): Added.
3320         * platform/network/cf/ResourceErrorCF.cpp:
3321         (WebCore::ResourceError::ResourceError): Added constructor that takes certificate data.
3322         (WebCore::ResourceError::platformLazyInit): Read any certificate from the userInfo dictionary.
3323         (WebCore::ResourceError::platformCopy): Copy m_certificate.
3324         (WebCore::ResourceError::cfError): Add any certificate data to the userInfo dictionary in the CFErrorRef.
3325
3326 2011-03-28  Jessie Berlin  <jberlin@apple.com>
3327
3328         Rubber-stamped by Adam Roben.
3329
3330         Add an extra newline to the end of the generated Inspector.idl file so that it does not
3331         trigger the Windows "no newline at at end of file" warning.
3332
3333         * inspector/generate-inspector-idl:
3334
3335 2011-03-28  Csaba Osztrogon√°c  <ossy@webkit.org>
3336
3337         Buildfix after r82125.
3338
3339         [Qt] QtWebKit will not compile with QT_ASCII_CAST_WARNINGS enabled
3340         https://bugs.webkit.org/show_bug.cgi?id=57087
3341
3342         * platform/graphics/qt/MediaPlayerPrivateQt.cpp: Convert all char* to QString explicitly.
3343         (WebCore::MediaPlayerPrivateQt::getSupportedTypes):
3344         (WebCore::MediaPlayerPrivateQt::commitLoad):
3345
3346 2011-03-28  Sheriff Bot  <webkit.review.bot@gmail.com>
3347
3348         Unreviewed, rolling out r82099.
3349         http://trac.webkit.org/changeset/82099
3350         https://bugs.webkit.org/show_bug.cgi?id=57245
3351
3352         Breaks live edits tests on chromium. (Requested by pfeldman on
3353         #webkit).
3354
3355         * inspector/front-end/ScriptsPanel.js:
3356         (WebInspector.SourceFrameDelegateForScriptsPanel.prototype.editScriptSource):
3357         * inspector/front-end/SourceFrame.js:
3358         (WebInspector.SourceFrame.prototype._handleSave):
3359         (WebInspector.SourceFrameDelegate.prototype.editScriptSource):
3360
3361 2011-03-28  Pavel Feldman  <pfeldman@chromium.org>
3362
3363         Reviewed by Yury Semikhatsky.
3364
3365         Web Inspector: brush up and rename debugger domain functions.
3366         https://bugs.webkit.org/show_bug.cgi?id=57240
3367
3368         * inspector/Inspector.json:
3369         * inspector/InspectorAgent.cpp:
3370         (WebCore::InspectorAgent::setFrontend):
3371         (WebCore::InspectorAgent::postWorkerNotificationToFrontend):
3372         * inspector/InspectorDebuggerAgent.cpp:
3373         (WebCore::InspectorDebuggerAgent::setBreakpointsActive):
3374         (WebCore::InspectorDebuggerAgent::setBreakpointByUrl):
3375         (WebCore::InspectorDebuggerAgent::setBreakpoint):
3376         (WebCore::InspectorDebuggerAgent::removeBreakpoint):
3377         (WebCore::InspectorDebuggerAgent::editScriptSource):
3378         (WebCore::InspectorDebuggerAgent::setPauseOnExceptionsState):
3379         (WebCore::InspectorDebuggerAgent::didParseSource):
3380         (WebCore::InspectorDebuggerAgent::failedToParseSource):
3381         (WebCore::InspectorDebuggerAgent::didPause):
3382         (WebCore::InspectorDebuggerAgent::didContinue):
3383         * inspector/InspectorDebuggerAgent.h:
3384         * inspector/front-end/DebuggerModel.js:
3385         (WebInspector.DebuggerModel.prototype.setBreakpoint):
3386         (WebInspector.DebuggerModel.prototype.setBreakpointBySourceId):
3387         (WebInspector.DebuggerModel.prototype.removeBreakpoint):
3388         (WebInspector.DebuggerModel.prototype._didEditScriptSource):
3389         (WebInspector.DebuggerDispatcher.prototype.paused):
3390         (WebInspector.DebuggerDispatcher.prototype.resumed):
3391         (WebInspector.DebuggerDispatcher.prototype.scriptParsed):
3392         (WebInspector.DebuggerDispatcher.prototype.scriptFailedToParse):
3393         (WebInspector.DebuggerDispatcher.prototype.breakpointResolved):
3394         * inspector/front-end/ScriptsPanel.js:
3395         (WebInspector.ScriptsPanel.prototype.toggleBreakpointsClicked):
3396         * inspector/front-end/inspector.js:
3397         (WebInspector.didCreateWorker):
3398         (WebInspector.didDestroyWorker):
3399
3400 2011-03-28  David Kilzer  <ddkilzer@apple.com>
3401
3402         <http://webkit.org/b/57239> Use forward class declaration instead of including header
3403
3404         Reviewed by Dan Bernstein.
3405
3406         Adding a "using namespace WebCore;" statement in a header may
3407         cause issues when <WebCore/Length.h> is included before
3408         <CoreText/CoreText.h>.
3409
3410         Length.h defines the LengthType enum with a 'Fixed' value.
3411         CoreText.h includes MacTypes.h, which has a
3412         "typedef SInt32 Fixed;" statement, and then CoreText.h includes
3413         other headers that also use 'Fixed', but expect the typedef to
3414         be defined, not the enum.  If another header includes
3415         "using namespace WebCore;" before CoreText.h, the
3416         following compiler errors result (paths abbreviated):
3417
3418             CoreText.framework/Headers/SFNTLayoutTypes.h:689: error: reference to 'Fixed' is ambiguous
3419             MacTypes.h:184: error: candidates are: typedef SInt32 Fixed
3420             Length.h:37: error:                 WebCore::LengthType WebCore::Fixed
3421             SFNTLayoutTypes.h:689: error: 'Fixed' does not name a type
3422
3423         * platform/mac/HTMLConverter.h: Use forward declaration of
3424         DocumentLoader class instead of including header.  Remove the
3425         unused "using namespace WebCore;" statement.
3426
3427 2011-03-26  Dimitri Glazkov  <dglazkov@chromium.org>
3428
3429         Reviewed by Eric Seidel.
3430
3431         Introduce EventDispatcher, the new common way to fire events.
3432         https://bugs.webkit.org/show_bug.cgi?id=57168
3433
3434         The goal here is two-fold:
3435         1) reduce the need to randomly sprinkle guards around the dispatch code
3436         by creating a well-scoped abstraction for dispatching events.
3437         2) create a place where fiddly event-related things like creating event
3438         contexts for ancestors can be done lazily.
3439
3440         Additionally, with all the free-standing static functions, this code was
3441         just begging to come out of Node.cpp.
3442
3443         The first step is a near-mechanical extraction of mouse-related events
3444         from Node.cpp to EventDispatcher. For now, the call sites are just
3445         replaced with invoking EventDispatcher. Later, we can remove these methods
3446         from Node.
3447
3448         Refactoring, no functional changes.
3449
3450         * Android.mk: Added EventDispatcher to build system.
3451         * CMakeLists.txt: Ditto.
3452         * GNUmakefile.am: Ditto.
3453         * WebCore.gypi: Ditto.
3454         * WebCore.pro: Ditto.
3455         * WebCore.vcproj/WebCore.vcproj: Ditto.
3456         * WebCore.xcodeproj/project.pbxproj: Ditto.
3457         * dom/DOMAllInOne.cpp: Ditto.
3458         * dom/EventDispatcher.cpp: Added.
3459         * dom/EventDispatcher.h: Added.
3460         * dom/Node.cpp:
3461         (WebCore::Node::dispatchScopedEvent): Replaced to use EventDispatcher.
3462         (WebCore::Node::dispatchEvent): Ditto.
3463         (WebCore::Node::dispatchMouseEvent): Ditto.
3464         (WebCore::Node::dispatchSimulatedClick): Ditto.
3465         * dom/Node.h: Updated decls.
3466
3467 2011-03-28  Dan Bernstein  <mitz@apple.com>
3468
3469         Reviewed by Maciej Stachowiak.
3470