ChangeLog 8.12 MB
Newer Older
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16
2013-03-28  Zan Dobersek  <zdobersek@igalia.com>

        [GTK] Build GTK-specific, non-layer-violating source code into WebCore-independent libPlatformGtk.la
        https://bugs.webkit.org/show_bug.cgi?id=112546

        Reviewed by Martin Robinson.

        No new tests - no new functionality.

        * GNUmakefile.am: Passing the DATA_DIR value through the cppflags is not required anymore as the affected source is now
        built into libPlatformGtk.la.
        * GNUmakefile.list.am: Build the GTK-specific source files that are already independent of WebCore into the
        libPlatformGtk.la by assigning the build targets listing to the platformgtk_sources variable.
        * platform/gtk/GtkVersioning.c: Renamed from Source/Platform/gtk/GtkVersioning.c.
        * platform/gtk/GtkVersioning.h: Renamed from Source/Platform/gtk/GtkVersioning.h.

17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142
2013-03-28  Matt Falkenhagen  <falken@chromium.org>

        Refactoring: Replace Element::disabled and isEnabledFormControl with isDisabledFormControl
        https://bugs.webkit.org/show_bug.cgi?id=113273

        Reviewed by Kent Tamura.

        Element::disabled is about form controls and Element::isEnabledFormControl
        is redundant with it, so replace them with a single function
        Element::isDisabledFormControl.

        No new tests, there should be no behavior change.

        * accessibility/AccessibilityListBox.cpp:
        (WebCore::AccessibilityListBox::canSetSelectedChildrenAttribute):
        * accessibility/AccessibilityListBoxOption.cpp:
        (WebCore::AccessibilityListBoxOption::canSetSelectedAttribute):
        * accessibility/AccessibilityMenuList.cpp:
        (WebCore::AccessibilityMenuList::canSetFocusAttribute):
        * accessibility/AccessibilityMenuListOption.cpp:
        (WebCore::AccessibilityMenuListOption::isEnabled):
        * accessibility/AccessibilityNodeObject.cpp:
        (WebCore::AccessibilityNodeObject::isEnabled):
        (WebCore::AccessibilityNodeObject::actionElement):
        (WebCore::AccessibilityNodeObject::canSetFocusAttribute):
        * css/SelectorChecker.cpp:
        (WebCore::SelectorChecker::checkOne):
        * css/StyleResolver.cpp:
        (WebCore::StyleResolver::canShareStyleWithControl):
        * dom/Element.cpp:
        (WebCore::Element::isDisabledFormControl):
        * dom/Element.h:
        (Element):
        (WebCore::isDisabledFormControl): Add helper function for convenience.
        (WebCore):
        * dom/EventDispatcher.cpp:
        (WebCore::EventDispatcher::dispatchSimulatedClick):
        * dom/GestureEvent.cpp:
        (WebCore::GestureEventDispatchMediator::dispatchEvent):
        * dom/MouseEvent.cpp:
        (WebCore::MouseEventDispatchMediator::dispatchEvent):
        * dom/Node.cpp:
        (WebCore::Node::handleLocalEvents):
        (WebCore::Node::willRespondToMouseMoveEvents):
        (WebCore::Node::willRespondToMouseClickEvents):
        (WebCore::Node::willRespondToTouchEvents):
        * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
        (WebCore::BaseMultipleFieldsDateAndTimeInputType::isEditControlOwnerDisabled):
        * html/DOMFormData.cpp:
        (WebCore::DOMFormData::DOMFormData):
        * html/FileInputType.cpp:
        (WebCore::FileInputType::handleDOMActivateEvent):
        (WebCore::FileInputType::disabledAttributeChanged):
        * html/HTMLButtonElement.cpp:
        (WebCore::HTMLButtonElement::defaultEventHandler):
        (WebCore::HTMLButtonElement::willRespondToMouseClickEvents):
        (WebCore::HTMLButtonElement::isSuccessfulSubmitButton):
        * html/HTMLCollection.cpp:
        (WebCore::isMatchingElement):
        * html/HTMLFormControlElement.cpp:
        (WebCore::HTMLFormControlElement::updateAncestorDisabledState):
        (WebCore::HTMLFormControlElement::isDisabledFormControl):
        (WebCore::HTMLFormControlElement::supportsFocus):
        * html/HTMLFormControlElement.h:
        (HTMLFormControlElement):
        (WebCore::HTMLFormControlElement::isDisabledOrReadOnly):
        * html/HTMLInputElement.cpp:
        (WebCore::HTMLInputElement::isSuccessfulSubmitButton):
        (WebCore::HTMLInputElement::willRespondToMouseClickEvents):
        * html/HTMLOptGroupElement.cpp:
        (WebCore::HTMLOptGroupElement::isDisabledFormControl):
        * html/HTMLOptGroupElement.h:
        (HTMLOptGroupElement):
        * html/HTMLOptionElement.cpp:
        (WebCore::HTMLOptionElement::isDisabledFormControl):
        * html/HTMLOptionElement.h:
        (HTMLOptionElement):
        * html/HTMLPlugInElement.cpp:
        (WebCore::HTMLPlugInElement::willRespondToMouseClickEvents):
        * html/HTMLSelectElement.cpp:
        (WebCore::HTMLSelectElement::nextValidIndex):
        (WebCore::HTMLSelectElement::updateListBoxSelection):
        (WebCore::HTMLSelectElement::recalcListItems):
        (WebCore::HTMLSelectElement::appendFormData):
        (WebCore::HTMLSelectElement::updateSelectedState):
        (WebCore::HTMLSelectElement::listBoxDefaultEventHandler):
        (WebCore::HTMLSelectElement::defaultEventHandler):
        (WebCore::HTMLSelectElement::optionAtIndex):
        * html/ImageInputType.cpp:
        (WebCore::ImageInputType::handleDOMActivateEvent):
        * html/ResetInputType.cpp:
        (WebCore::ResetInputType::handleDOMActivateEvent):
        * html/SubmitInputType.cpp:
        (WebCore::SubmitInputType::handleDOMActivateEvent):
        * html/shadow/SliderThumbElement.cpp:
        (WebCore::SliderThumbElement::isDisabledFormControl):
        (WebCore::SliderThumbElement::defaultEventHandler):
        (WebCore::SliderThumbElement::willRespondToMouseMoveEvents):
        (WebCore::SliderThumbElement::willRespondToMouseClickEvents):
        * html/shadow/SliderThumbElement.h:
        (SliderThumbElement):
        * html/shadow/SpinButtonElement.h:
        * html/shadow/TextFieldDecorationElement.cpp:
        (WebCore::TextFieldDecorationElement::updateImage):
        * loader/FormSubmission.cpp:
        (WebCore::FormSubmission::create):
        * page/DragController.cpp:
        (WebCore::DragController::tryDocumentDrag):
        (WebCore::DragController::concludeEditDrag):
        * rendering/RenderListBox.cpp:
        (WebCore::RenderListBox::addFocusRingRects):
        (WebCore::RenderListBox::paintItemForeground):
        * rendering/RenderMenuList.cpp:
        (WebCore::RenderMenuList::itemIsEnabled):
        * rendering/RenderTextControl.cpp:
        (WebCore::updateUserModifyProperty):
        * rendering/RenderTheme.cpp:
        (WebCore::RenderTheme::isEnabled):
        * rendering/RenderThemeMac.mm:
        (WebCore::getMediaUIPartStateFlags):
        * rendering/RenderThemeMacShared.mm:
        (WebCore::RenderThemeMacShared::adjustMenuListStyle):
        (WebCore::RenderThemeMacShared::paintSearchFieldCancelButton):
        * rendering/RenderThemeSafari.cpp:
        (WebCore::RenderThemeSafari::adjustMenuListStyle):

143 144 145 146 147 148 149 150 151 152 153 154
2013-03-28  Brady Eidson  <beidson@apple.com>

        Remove workaround for <rdar://problem/5321972>.
        <rdar://problem/12022862> and https://bugs.webkit.org/show_bug.cgi?id=113516

        Reviewed by Sam Weinig.

        No new tests (No point in testing the removal of bizarre behavior).

        * platform/network/mac/WebCoreURLResponse.mm:
        (WebCore::adjustMIMETypeIfNecessary): This workaround isn't needed on Lion+

155 156 157 158 159 160 161 162 163 164 165 166 167 168
2013-03-28  Arnaud Renevier  <a.renevier@sisa.samsung.com>

        use CanvasWindingRule enumeration in CanvasRenderingContext2D.idl
        https://bugs.webkit.org/show_bug.cgi?id=113456

        Reviewed by Kentaro Hara.

        Use enum CanvasWindingRule type instead of DOMString for winding
        arguments when needed. Changed methods are: fill, stroke and isPointInPath.

        Test: fast/canvas/winding-enumeration.html

        * html/canvas/CanvasRenderingContext2D.idl:

169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193
2013-03-28  Scott Graham  <scottmg@chromium.org>

        Move preprocessing of idl to pre-pass for gyp
        https://bugs.webkit.org/show_bug.cgi?id=113448

        Reviewed by Tony Chang.

        Moves the preprocessor invocations when parsing IDL files to a
        pre-pass to avoid reinvocations when IDLs are referenced from others.
        This reduces the number of invocations of the preprocessor from 20071
        to 633, which reduces the runtime from 12m30 to 1m (on a Windows box).

        No new tests, this is a build time improvement, and shouldn't have any
        visible effect.

        * WebCore.gyp/WebCore.gyp:
        * bindings/scripts/CodeGenerator.pm:
        (ParseInterface):
        * bindings/scripts/IDLParser.pm:
        (Parse):
        * bindings/scripts/generate-bindings.pl:
        * bindings/scripts/generate-preprocessed-idls.pl: Added.
        * bindings/scripts/preprocessor.pm:
        (applyPreprocessor):

194 195 196 197 198 199 200 201 202 203 204 205 206 207
2013-03-28  Alok Priyadarshi  <alokp@chromium.org>

        RenderBox::backgroundIsKnownToBeOpaqueInRect may be wrong for theme-painted elements
        https://bugs.webkit.org/show_bug.cgi?id=113419

        Reviewed by Simon Fraser.

        Do not consider control elements as opaque. They are typically theme painted, and we cannot assume opaqueness on the behalf of theme. It can be improved by asking the theme if it paints opaque.

        Test: compositing/contents-opaque/control-layer.html

        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::backgroundIsKnownToBeOpaqueInRect):

208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229
2013-03-28  ChangSeok Oh  <changseok.oh@collabora.com>

        [GTK][AC] Animating layer disappears while running with clutter backend
        https://bugs.webkit.org/show_bug.cgi?id=110470

        Reviewed by Gustavo Noronha Silva.

        The reason of this issue is that clutter_actor_remove_child leads to stopping animations
        of child actor. ClutterActor's animation could be defined only when it has a parent actor.
        So we should avoid the case calling the api as much as we can. At least we don't
        need to reset a actor's parent at all if the current parent is same with new one.
        If we can't avoid invoking clutter_actor_remove_child for an animating actor, we may apply
        a more complicated way to keep the animation. But I haven't faced such a case yet.

        Covered by existing animation tests.

        * platform/graphics/clutter/GraphicsLayerActor.cpp:
        (graphicsLayerActorSetSublayers):
        * platform/graphics/clutter/GraphicsLayerClutter.cpp:
        (WebCore::GraphicsLayerClutter::recursiveCommitChanges):
        (WebCore::GraphicsLayerClutter::updateSublayerList):

230 231 232 233 234 235 236 237 238 239 240 241 242 243 244
2013-03-28  Xianzhu Wang  <wangxianzhu@chromium.org>

        Non-painting fixed elements should not cause repaints on scroll
        https://bugs.webkit.org/show_bug.cgi?id=110430

        Reviewed by Simon Fraser.

        Test: compositing/repaint/scroll-fixed-layer-no-content.html
        Test: compositing/repaint/scroll-fixed-layer-out-of-view.html

        * page/FrameView.cpp:
        (WebCore::FrameView::scrollContentsFastPath): Check for no-content and out-of-view flag set by RLC.
        * rendering/RenderLayerCompositor.cpp:
        (WebCore::RenderLayerCompositor::requiresCompositingForPosition): Moved the check for no-content above out-of-view because it's faster.

245 246 247 248 249 250
2013-03-28  Alexander Pavlov  <apavlov@chromium.org>

        Unreviewed, revert accidentally added line committed in r147117.

        * inspector/front-end/ElementsTreeOutline.js:

251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276
2013-03-28  Alexander Pavlov  <apavlov@chromium.org>

        Web Inspector: [Elements] Syntax-highlight the "Edit as HTML" editor
        https://bugs.webkit.org/show_bug.cgi?id=113306

        Reviewed by Vsevolod Vlasov.

        Use CodeMirror as the raw HTML editor for the "Edit as HTML" menu item
        (and all multiline editors for WebInspector.startEditing()).
        Drive-by fix for handling the editing when the editor has been invoked on the closing tag.

        * inspector/front-end/ElementsTreeOutline.js:
        (WebInspector.ElementsTreeElement.prototype.commit):
        (WebInspector.ElementsTreeElement.prototype._startEditingAsHTML):
        * inspector/front-end/UIUtils.js:
        (WebInspector.EditingConfig.prototype.setMultiline):
        (WebInspector.startEditing):
        (WebInspector.CodeMirrorCSSLoadView): A bogus view to load-unload CodeMirror-related CSS on demand.
        * inspector/front-end/elementsPanel.css:
        (#elements-content .CodeMirror):
        (#elements-content .CodeMirror pre):
        (#elements-content .CodeMirror-lines):
        * inspector/front-end/elementsPanel.css: CodeMirror styles for the "Edit as HTML" editor.
        * inspector/front-end/externs.js: Declare CodeMirror type with some members, as it is third-party code.
        * inspector/front-end/inspector.html: Fix script order (UIUtils.js requires View.js).

277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305
2013-03-28  Hajime Morrita  <morrita@google.com>

        Custom Elements: should support non-HTML namespaces.
        https://bugs.webkit.org/show_bug.cgi?id=111693

        Reviewed by Dimitri Glazkov.

        Some existing code assumes that the element extends HTMLElements.
        This change allow it to extend from Element. Note that the
        namespace URI of a custom element is determined by given element
        prototype: An element will have XHTML namespace if its prototype
        chain includes HTMLElements, SVGElement leads SVG namespace and
        null otherwise, respectively.

        Test: fast/dom/custom/document-register-namespace.html

        * bindings/v8/CustomElementHelpers.cpp:
        (WebCore::hasValidPrototypeChainFor): Factored out from isValidPrototypeParameter()
        (WebCore::CustomElementHelpers::isValidPrototypeParameter): Extend to support non HTMLElement prototype
        (WebCore::CustomElementHelpers::findLocalName): Support non-HTML element names.
        * bindings/v8/CustomElementHelpers.h:
        (CustomElementHelpers):
        * dom/CustomElementConstructor.cpp:
        (WebCore::CustomElementConstructor::createElementInternal):
        * dom/CustomElementRegistry.cpp:
        (WebCore::CustomElementRegistry::registerElement): No longer hard-codes namespace and picks one based on the prototype value.
        * dom/CustomElementRegistry.h:
        (CustomElementRegistry):

306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338
2013-03-28  Hans Muller  <hmuller@adobe.com>

        [CSS Exclusions] Add support for the simple case of padding a polygonal shape-inside
        https://bugs.webkit.org/show_bug.cgi?id=112592

        Reviewed by Dirk Schulze.

        First pass at computing the padded or inset boundary of a polygon.  This version does not handle
        self-intersecting polygons, or values of shape-padding large enough to change the shape of the
        original polygon. The implementation computes an offset edge for each polgon edge, where the offset
        edge is parallel to the original edge and separated by shape-padding. The padded polygon's vertices
        are the intersections of each pair of adjacent offset edges. When adjacent offset edges do not intersect,
        because they share a reflex vertex in the original polygon, an approximation to a circular arc
        connects the offset edges.

        Tests: fast/exclusions/shape-inside/shape-inside-polygon-padding-001.html
               fast/exclusions/shape-inside/shape-inside-polygon-padding-002.html
               fast/exclusions/shape-inside/shape-inside-polygon-padding-003.html

        * rendering/ExclusionPolygon.cpp:
        (WebCore::isReflexVertex): Just moved this function earlier in the file.
        (WebCore::inwardEdgeNormal): Unit vector that's perpindicular to the edge and that points inwards.
        (WebCore::outwardEdgeNormal): Unit vector that's perpindicular to the edge and that points outwards.
        (WebCore::appendArc): Append a linear approximation to a circular arc to a vector of vertices.
        (WebCore::computeShapePaddingBounds): Return a polygon whose edges are all inset by shape-padding from m_polygon.
        (WebCore::computeShapeMarginBounds): Just a stub, see bug 112917.
        (WebCore::ExclusionPolygon::shapePaddingBounds): Lazily use computeShapePaddingBounds() to initialize m_paddingBounds.
        (WebCore::ExclusionPolygon::shapeMarginBounds): Lazily use computeShapeMarginBounds() to initialize m_marginBounds.
        (WebCore::ExclusionPolygon::getIncludedIntervals): Now based on the value of shapePaddingBounds().
        (WebCore::ExclusionPolygon::firstIncludedIntervalLogicalTop): Now based on the value of shapePaddingBounds().
        * rendering/ExclusionPolygon.h:
        (WebCore::ExclusionPolygon::ExclusionPolygon):

339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358
2013-03-28  Chris Hutten-Czapski  <chutten@blackberry.com>

        [BlackBerry] Handle EXIF orientation for ImageDocuments
        https://bugs.webkit.org/show_bug.cgi?id=113423

        Internal Bug: PR 293648
        Informally Reviewed by Jeff Rogers
        Reviewed by Rob Buis.

        Support image orientation in our image draw calls, and advertise
        the capability to the calling code. This allows us to respect EXIF
        orientation data.

        * platform/graphics/BitmapImage.h:
        * platform/graphics/blackberry/ImageBlackBerry.cpp:
        (WebCore::BitmapImage::draw):
        (WebCore):
        * rendering/RenderObject.cpp:
        (WebCore::RenderObject::shouldRespectImageOrientation):

359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381
2013-03-28  Andrey Kosyakov  <caseq@chromium.org>

        Web Inspector: name timeline overview controls consistently
        https://bugs.webkit.org/show_bug.cgi?id=113503

        Reviewed by Yury Semikhatsky.

        Refactoring, covered by existing tests.

        - rename HeapGraph to TimelineMemoryOverview;
        - rename TimelineCategoryStrips to TimelineEventOvrview.

        * inspector/front-end/TimelineOverviewPane.js:
        (WebInspector.TimelineOverviewPane):
        (WebInspector.TimelineOverviewPane.prototype.setMode):
        (WebInspector.TimelineOverviewPane.prototype._setFrameMode):
        (WebInspector.TimelineOverviewPane.prototype._onCategoryVisibilityChanged):
        (WebInspector.TimelineOverviewPane.prototype._update):
        (WebInspector.TimelineOverviewPane.prototype.setMinimumRecordDuration):
        (WebInspector.TimelineMemoryOverview):
        (WebInspector.TimelineEventOverview):
        (WebInspector.TimelineEventOverview.prototype._renderBar):

382 383 384 385 386 387 388 389 390 391
2013-03-28  Eli Fidler  <efidler@blackberry.com>

        [BlackBerry] Correct glyph contour winding direction when fake-bolding
        https://bugs.webkit.org/show_bug.cgi?id=113411

        Reviewed by Rob Buis.

        * platform/graphics/blackberry/FontPlatformDataBlackBerry.cpp:
        (WebCore::FontPlatformData::applyState):

392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407
2013-03-28  Vsevolod Vlasov  <vsevik@chromium.org>

        Web Inspector: Make JavaScriptSourceFrame work correctly with breakpoints when uiSourceCode does not have a scriptFile.
        https://bugs.webkit.org/show_bug.cgi?id=113500

        Reviewed by Pavel Feldman.

        JavaScriptSourceFrame now listens for uiSourceCode working copy related events and supports muting breakpoints without script file.

        * inspector/front-end/JavaScriptSourceFrame.js:
        (WebInspector.JavaScriptSourceFrame):
        (WebInspector.JavaScriptSourceFrame.prototype._workingCopyChanged):
        (WebInspector.JavaScriptSourceFrame.prototype._workingCopyCommitted):
        (WebInspector.JavaScriptSourceFrame.prototype._updateScriptFile):
        (WebInspector.JavaScriptSourceFrame.prototype.dispose):

408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442
2013-03-22  Andrey Kosyakov  <caseq@chromium.org>

        Web Inspector: factor out node search controller from inspector.js
        https://bugs.webkit.org/show_bug.cgi?id=112689

        Reviewed by Pavel Feldman.

        This just extracts the existing logic of toggling node search
        from inspector.js into a class of its own, InspectElementModeController.
        Drive-by: add CtrlOrMeta+Shift+C to help screen.

        * English.lproj/localizedStrings.js:
        * WebCore.gypi:
        * WebCore.vcproj/WebCore.vcproj:
        * WebCore.vcxproj/WebCore.vcxproj:
        * WebCore.vcxproj/WebCore.vcxproj.filters:
        * inspector/compile-front-end.py:
        * inspector/front-end/InspectElementModeController.js: Added.
        (WebInspector.InspectElementModeController):
        (WebInspector.InspectElementModeController.createShortcut):
        (WebInspector.InspectElementModeController.prototype.enabled):
        (WebInspector.InspectElementModeController.prototype.disable):
        (WebInspector.InspectElementModeController.prototype.toggleSearch.callback):
        (WebInspector.InspectElementModeController.prototype.toggleSearch):
        (WebInspector.InspectElementModeController.prototype.handleShortcut):
        * inspector/front-end/InspectorFrontendAPI.js:
        (InspectorFrontendAPI.enterInspectElementMode):
        * inspector/front-end/WebKit.qrc:
        * inspector/front-end/inspector.html:
        * inspector/front-end/inspector.js:
        (WebInspector._createGlobalStatusBarItems):
        (WebInspector._registerShortcuts):
        (WebInspector.documentKeyDown):
        (WebInspector._updateFocusedNode):

443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461
2013-03-28  Eugene Klyuchnikov  <eustas@chromium.org>

        Web Inspector: [Settings] "previouslyViewedFiles" exceeds local storage quota.
        https://bugs.webkit.org/show_bug.cgi?id=113375

        Reviewed by Pavel Feldman.

        Serialized "previouslyViewedFiles" may make local storage overflow.
        Two fixed applied:
        - limit number of history log items
        - limit length of URIs that get serialized;
          this would affect only data-url URIs.

        * inspector/front-end/TabbedEditorContainer.js:
        (WebInspector.TabbedEditorContainer.HistoryItem.prototype.serializeToObject):
        Added length check.
        (WebInspector.TabbedEditorContainer.History.prototype.set _serializeToObject):
        Added output array length limit.

462 463 464 465 466 467 468 469 470 471 472 473
2013-03-28  Alexei Filippov  <alph@chromium.org>

        Web Inspector: Heap snapshots retained size falls out of the grid if column is too narrow
        https://bugs.webkit.org/show_bug.cgi?id=113497

        Reviewed by Pavel Feldman.

        * inspector/front-end/HeapSnapshotGridNodes.js:
        (WebInspector.HeapSnapshotGridNode.prototype._createValueCell):
        * inspector/front-end/heapProfiler.css:
        (.heap-snapshot-view .data-grid div.heap-snapshot-multiple-values):

474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503
2013-03-28  Vsevolod Vlasov  <vsevik@chromium.org>

        Web Inspector: ResourceScriptFile should check if resource content really matches VM script when determining hasDiverged state.
        https://bugs.webkit.org/show_bug.cgi?id=113488

        Reviewed by Pavel Feldman.

        Enabled support for checking that file content matches VM script in ResourceScriptFile (For script resources only).
        This check is never done before content is loaded in corresponding editor to avoid regressing performance.
        File - script content matching is done bearing in mind sourceURLs. 
        Live edit keeps sourceURL in script content now even if it is not present in file's content.

        * inspector/front-end/JavaScriptSourceFrame.js:
        (WebInspector.JavaScriptSourceFrame.prototype._updateScriptFile):
        (WebInspector.JavaScriptSourceFrame.prototype.onTextEditorContentLoaded):
        * inspector/front-end/LiveEditSupport.js:
        (WebInspector.LiveEditScriptFile.prototype.checkMapping):
        * inspector/front-end/ResourceScriptMapping.js:
        (WebInspector.ResourceScriptMapping.prototype._bindUISourceCodeToScripts):
        (WebInspector.ScriptFile.prototype.checkMapping):
        (WebInspector.ResourceScriptFile):
        (WebInspector.ResourceScriptFile.prototype._workingCopyCommitted):
        (WebInspector.ResourceScriptFile.prototype._isDiverged):
        (WebInspector.ResourceScriptFile.prototype._sourceMatchesScriptSource):
        (WebInspector.ResourceScriptFile.prototype._sourceEndsWithSourceURL):
        (WebInspector.ResourceScriptFile.prototype.checkMapping.callback):
        (WebInspector.ResourceScriptFile.prototype.checkMapping):
        * inspector/front-end/ScriptSnippetModel.js:
        (WebInspector.SnippetScriptFile.prototype.checkMapping):

504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547
2013-03-28  Vsevolod Vlasov  <vsevik@chromium.org>

        Web Inspector: Simplify ResourceScriptFile so that it stores hasDiverged state in it.
        https://bugs.webkit.org/show_bug.cgi?id=113489

        Reviewed by Pavel Feldman.

        ResourceScriptFile._hasDiverged is the one flag that shows whether we have diverged from VM.
        It's values is based both on dirty flag on uiSourceCode and information about live edit failures stored in _lastLiveEditFailed field.
        Removed willMerge/Diverge events from ScriptFile.
        JavaScriptSourceFrame now uses isMergingToVM/DivergingFromVM methods on ScriptFile.
        to determine whether breakpointAdded/Removed events should be ignored.
        Introduced muted state on JavaScriptSourceFrame to determine whether it should ignore user attempts to set/remove breakpoints.

        * inspector/front-end/JavaScriptSourceFrame.js:
        (WebInspector.JavaScriptSourceFrame):
        (WebInspector.JavaScriptSourceFrame.prototype._didMergeToVM):
        (WebInspector.JavaScriptSourceFrame.prototype._didDivergeFromVM):
        (WebInspector.JavaScriptSourceFrame.prototype._muteBreakpointsWhileEditing):
        (WebInspector.JavaScriptSourceFrame.prototype._restoreBreakpointsAfterEditing):
        (WebInspector.JavaScriptSourceFrame.prototype._addBreakpointDecoration):
        (WebInspector.JavaScriptSourceFrame.prototype._removeBreakpointDecoration):
        (WebInspector.JavaScriptSourceFrame.prototype._shouldIgnoreExternalBreakpointEvents):
        (WebInspector.JavaScriptSourceFrame.prototype._breakpointAdded):
        (WebInspector.JavaScriptSourceFrame.prototype._breakpointRemoved):
        (WebInspector.JavaScriptSourceFrame.prototype._updateScriptFile):
        (WebInspector.JavaScriptSourceFrame.prototype.onTextEditorContentLoaded):
        * inspector/front-end/LiveEditSupport.js:
        (WebInspector.LiveEditScriptFile.prototype.isMergingToVM):
        * inspector/front-end/ResourceScriptMapping.js:
        (WebInspector.ResourceScriptMapping.prototype.rawLocationToUILocation):
        (WebInspector.ScriptFile.prototype.isMergingToVM):
        (WebInspector.ResourceScriptFile):
        (WebInspector.ResourceScriptFile.prototype._workingCopyCommitted):
        (WebInspector.ResourceScriptFile.prototype._isDiverged):
        (WebInspector.ResourceScriptFile.prototype._workingCopyChanged):
        (WebInspector.ResourceScriptFile.prototype._update):
        (WebInspector.ResourceScriptFile.prototype._divergeFromVM):
        (WebInspector.ResourceScriptFile.prototype._mergeToVM):
        (WebInspector.ResourceScriptFile.prototype.hasDivergedFromVM):
        (WebInspector.ResourceScriptFile.prototype.isMergingToVM):
        * inspector/front-end/ScriptSnippetModel.js:
        (WebInspector.SnippetScriptFile.prototype.isMergingToVM):

548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566
2013-03-25  Andrey Kosyakov  <caseq@chromium.org>

        Web Inspector: DOMContentLoaded event divider is not shown on Timeline's main view
        https://bugs.webkit.org/show_bug.cgi?id=113196

        Reviewed by Pavel Feldman.

        - keep event divider records in TimelinePresentationModel, not in TimelinePanel;
        - process event divider records on every level, not just on top.

        * inspector/front-end/TimelinePanel.js:
        (WebInspector.TimelinePanel.prototype._updateEventDividers):
        (WebInspector.TimelinePanel.prototype._innerAddRecordToTimeline.checkVisible):
        (WebInspector.TimelinePanel.prototype._resetPanel):
        * inspector/front-end/TimelinePresentationModel.js:
        (WebInspector.TimelinePresentationModel.prototype.reset):
        (WebInspector.TimelinePresentationModel.prototype._innerAddRecord):
        (WebInspector.TimelinePresentationModel.prototype.eventDividerRecords):

567 568 569 570 571 572
2013-03-28  Vsevolod Vlasov  <vsevik@chromium.org>

        Unreviewed inspector front-end closure compilation fix.

        * inspector/front-end/CookiesTable.js:

573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596
2013-03-28  Andrey Lushnikov  <lushnikov@chromium.org>

        Web Inspector: [DTE] Paint overlay highlight over line background color
        https://bugs.webkit.org/show_bug.cgi?id=113346

        Reviewed by Pavel Feldman.

        No new tests: no change in behaviour.

        - Append spans instead of text nodes to lineRows.
        - Set positioning of all spans inside of webkit-line-content as
        relative
        - Set z-index property so that overlay highlight is above line
        background but under text.

        * inspector/front-end/DefaultTextEditor.js:
        (WebInspector.TextEditorMainPanel.prototype._measureHighlightDescriptor):
        (WebInspector.TextEditorMainPanel.prototype._measureSpans):
        (WebInspector.TextEditorMainPanel.prototype._renderRanges):
        (WebInspector.TextEditorMainPanel.prototype._insertSpanBefore):
        * inspector/front-end/textEditor.css:
        (.webkit-line-content > .text-editor-overlay-highlight):
        (.webkit-line-content > *):

597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612
2013-03-28  Alexander Pavlov  <apavlov@chromium.org>

        Web Inspector: [REGRESSION] [Styles] Pasting a property in the "name" field is broken
        https://bugs.webkit.org/show_bug.cgi?id=113491

        Reviewed by Pavel Feldman.

        Update the CSSProperty name and value upon pasting properties into the Styles pane.
        Drive-by: start editing the next/new property name after pasting.

        Test: inspector/styles/paste-property.html

        * inspector/front-end/StylesSidebarPane.js:
        (.selectElement):
        (.moveDirection.alreadyNew):

613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631
2013-03-28  Alexei Filippov  <alph@chromium.org>

        Web Inspector: Auto expand retaining path until there are more than one retainer.
        https://bugs.webkit.org/show_bug.cgi?id=112596

        Reviewed by Yury Semikhatsky.

        When retainers view gets opened automatically expand retaining path
        for objects having just a single retainer.

        Test: inspector/profiler/heap-snapshot-summary-retainers.html

        * inspector/front-end/HeapSnapshotDataGrids.js:
        (WebInspector.HeapSnapshotRetainmentDataGrid.prototype.populateComplete):
        (WebInspector.HeapSnapshotRetainmentDataGrid.prototype.setDataSource):
        * inspector/front-end/HeapSnapshotGridNodes.js:
        (WebInspector.HeapSnapshotGridNode.prototype.childrenRetrieved):
        (WebInspector.HeapSnapshotGridNode.prototype._populateChildren):

632 633 634 635 636 637 638 639 640 641 642 643
2013-03-28  Vladislav Kaznacheev  <kaznacheev@chromium.org>

        Web Inspector: Fixed property text indentation in Styles sidebar.
        https://bugs.webkit.org/show_bug.cgi?id=113409

        Reviewed by Alexander Pavlov.

        When the sidebar is too narrow and the property text wraps around it breaks the indentation.
        This was introduced in r143207 which spuriously modified DOM elements order.

        * inspector/front-end/StylesSidebarPane.js:

644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666
2013-03-28  Arpita Bahuguna  <a.bah@samsung.com>

        Regression: Crash when selecting Hebrew and numbers in a list
        https://bugs.webkit.org/show_bug.cgi?id=111894

        Reviewed by Ryosuke Niwa.

        There is a crash when trying to click/select an anonymous
        renderer.

        This is a regression due to r143313 which tries to add border/padding
        to the computed caret rect in RenderBox::localCaretRect().
        The patch calls on the node() method for the corresponding
        renderer. For an anonymous renderer though, node() returns
        null. Since no check had been added for this, a crash occurs when
        caret rect for an anonymous renderer is being computed.

        Test: editing/selection/click-on-anonymous-content-crash.html

        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::localCaretRect):
        Added a check for validating the return from the node() call.

667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702
2013-03-28  Mike West  <mkwst@chromium.org>

        X-Frame-Options: Multiple headers are ignored completely.
        https://bugs.webkit.org/show_bug.cgi?id=113387

        Reviewed by Nate Chapin.

        If a server sends multiple 'X-Frame-Options' headers, we end up with a
        value like 'SAMEORIGIN, SAMEORIGIN'. Currently, we're treating that as
        invalid, and ignoring the header. It would be safer to follow Gecko's
        lead[1] by:

        - Folding duplicated entries into their common value (that is:
          'sameorigin, sameorigin' -> 'sameorigin').

        - Failing closed in the case of conflicts (that is:
          'sameorigin, allowall' -> 'deny').

        [1]: https://bugzilla.mozilla.org/show_bug.cgi?id=761655

        Tests: http/tests/security/XFrameOptions/x-frame-options-multiple-headers-conflict.html
               http/tests/security/XFrameOptions/x-frame-options-multiple-headers-sameorigin-allow.html
               http/tests/security/XFrameOptions/x-frame-options-multiple-headers-sameorigin-deny.html

        * loader/FrameLoader.cpp:
        (WebCore::FrameLoader::shouldInterruptLoadForXFrameOptions):
            Call out to parseXFrameOptionsHeader to get the header's disposition
            and deal with each case in a switch statement for clarity. Add a new
            console warning for the conflict case described above.
        * platform/network/HTTPParsers.cpp:
        (WebCore::parseXFrameOptionsHeader):
        * platform/network/HTTPParsers.h:
            Move X-Frame-Options parsing out into HTTPParsers, as it's getting
            more and more complicated. To do this, the patch defines a new enum
            to pass around the header's disposition.

703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738
2013-03-28  Mihnea Ovidenie  <mihnea@adobe.com>

        [CSSRegions] Consolidate use of RenderRegion::isValid
        https://bugs.webkit.org/show_bug.cgi?id=113154

        Reviewed by David Hyatt.

        After https://bugs.webkit.org/show_bug.cgi?id=98752, the list of invalid regions is kept separately than the list of valid regions.
        A valid region has always a valid flow thread attached. We can use isValid() throughout the RenderRegion code
        instead of testing for both isValid() and m_flowThread.

        No new tests since there is no change is functionality, just code refactoring.

        * rendering/RenderNamedFlowThread.cpp:
        (WebCore::RenderNamedFlowThread::addRegionToNamedFlowThread): Added a new function to keep the code
        used in addRegionToThread and checkInvalidRegions.
        (WebCore::RenderNamedFlowThread::addRegionToThread):
        (WebCore::RenderNamedFlowThread::checkInvalidRegions):
        * rendering/RenderNamedFlowThread.h:
        * rendering/RenderRegion.cpp:
        (WebCore::RenderRegion::overflowRectForFlowThreadPortion):
        (WebCore::RenderRegion::isFirstRegion):
        (WebCore::RenderRegion::isLastRegion):
        (WebCore::RenderRegion::paintObject):
        (WebCore::RenderRegion::nodeAtPoint):
        (WebCore::RenderRegion::incrementAutoLogicalHeightCount):
        (WebCore::RenderRegion::decrementAutoLogicalHeightCount):
        (WebCore::RenderRegion::layoutBlock):
        (WebCore::RenderRegion::repaintFlowThreadContentRectangle):
        (WebCore::RenderRegion::attachRegion):
        (WebCore::RenderRegion::renderBoxRegionInfo):
        (WebCore::RenderRegion::setRenderBoxRegionInfo):
        (WebCore::RenderRegion::logicalTopOfFlowThreadContentRect):
        (WebCore::RenderRegion::logicalBottomOfFlowThreadContentRect):
        (WebCore::RenderRegion::computePreferredLogicalWidths):

739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768
2013-03-27  Ilya Tikhonovsky  <loislo@chromium.org>

        Web Inspector: Timeline. Refresh is slow when user drags the overview window.
        https://bugs.webkit.org/show_bug.cgi?id=113371

        Reviewed by Pavel Feldman.

        The root of problem is the 300ms delay in scheduleRefresh method.
        It was introduced for the case when we add a huge number of records per second.
        The scheduleRefresh was written such a way that refresh happened immediately
        only for the scrolling operations. Actually we would like to see fast
        refresh every time when it is forced by an user action.

        In this patch additional flag newRecordWasAdded was added to the
        _invalidateAndScheduleRefresh. I made it mandatory because the function
        is also used as a callback for an event and it is easy to make a mistake and
        interpret the event as the flag.

        * inspector/front-end/TimelinePanel.js:
        (WebInspector.TimelinePanel.prototype._onCategoryCheckboxClicked):
        (WebInspector.TimelinePanel.prototype._durationFilterChanged):
        (WebInspector.TimelinePanel.prototype._repopulateRecords):
        (WebInspector.TimelinePanel.prototype._onTimelineEventRecorded):
        (WebInspector.TimelinePanel.prototype._onRecordsCleared):
        (WebInspector.TimelinePanel.prototype._invalidateAndScheduleRefresh):
        (WebInspector.TimelinePanel.prototype._scheduleRefresh):
        (WebInspector.TimelinePanel.prototype._revealRecord):
        (WebInspector.TimelinePanel.prototype._refreshRecords):
        (WebInspector.TimelinePanel.prototype.performFilter):

769 770 771 772 773 774 775 776 777 778 779 780 781 782
2013-03-27  Keishi Hattori  <keishi@webkit.org>

        Dragging to edge should always snap to min/max.
        https://bugs.webkit.org/show_bug.cgi?id=113477

        Reviewed by Kent Tamura.

        Dragging to the edge of a slider should always snap to the min/max.

        Test: fast/forms/range/range-slow-drag-to-edge.html

        * html/shadow/SliderThumbElement.cpp:
        (WebCore::SliderThumbElement::setPositionFromPoint):

783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816
2013-03-27  Simon Fraser  <simon.fraser@apple.com>

        Add a way to update GraphicsLayerCA visibleRects without having to do a flush
        https://bugs.webkit.org/show_bug.cgi?id=113459

        Reviewed by Tim Horton.
        
        Some platforms need to update TiledBacking visible rects from
        outside of WebKit, for example if they use delegated scrolling.
        They want to avoid forcing layout to be up-to-date when doing this.
        
        Currently, updating the visibleRect happens when the GraphicsLayerCA
        layer are being flushed, but that makes some assumptions about
        layout being up-to-date.
        
        To fix this, add a light-weight pass over the layer tree that
        uses TransformState to compute the visibleRect for each
        layer, and only if the visibleRect would cause a change in the
        tiles in a TiledBacking trigger a layer flush.

        * platform/graphics/GraphicsLayer.h:
        (WebCore::GraphicsLayer::recomputeVisibleRects):
        * platform/graphics/TiledBacking.h:
        * platform/graphics/ca/GraphicsLayerCA.cpp:
        (WebCore::GraphicsLayerCA::recursiveComputeVisibleRect):
        (WebCore::GraphicsLayerCA::recomputeVisibleRects):
        (WebCore::GraphicsLayerCA::computeVisibleRect):
        * platform/graphics/ca/GraphicsLayerCA.h:
        * platform/graphics/ca/mac/TileController.h:
        * platform/graphics/ca/mac/TileController.mm:
        (WebCore::TileController::tilesWouldChangeForVisibleRect):
        (WebCore::TileController::computeTileCoverageRect):
        (WebCore::TileController::revalidateTiles):

817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857
2013-03-27  Philip Rogers  <pdr@google.com>

        Rename toScriptElement -> toScriptElementIfPossible
        https://bugs.webkit.org/show_bug.cgi?id=113473

        Reviewed by Ryosuke Niwa.

        Rename ScriptElement::toScriptElement to ScriptElement::toScriptElementIfPossible to
        differentiate this function from other to*Element functions, and to better describe the
        function's behavior. Other to*Element functions do not return null if the cast fails,
        whereas toScriptElementIfPossible does.

        No new tests as this is just a refactoring.

        * dom/ScriptElement.cpp:
        (WebCore::toScriptElementIfPossible):
        * dom/ScriptElement.h:
        (WebCore):
        * dom/ScriptRunner.cpp:
        (WebCore::ScriptRunner::timerFired):

            This is the only unchecked return value but there isn't a security issue here.

        * html/HTMLOptionElement.cpp:
        (WebCore::HTMLOptionElement::collectOptionInnerText):
        * html/parser/HTMLConstructionSite.cpp:
        (WebCore::HTMLConstructionSite::attachLater):
        (WebCore::HTMLConstructionSite::insertForeignElement):
        * html/parser/HTMLScriptRunner.cpp:
        (WebCore::HTMLScriptRunner::executePendingScriptAndDispatchEvent):
        (WebCore::HTMLScriptRunner::requestPendingScript):
        (WebCore::HTMLScriptRunner::runScript):
        * xml/parser/XMLDocumentParser.cpp:
        (WebCore::XMLDocumentParser::notifyFinished):
        * xml/parser/XMLDocumentParserLibxml2.cpp:
        (WebCore::XMLDocumentParser::startElementNs):
        (WebCore::XMLDocumentParser::endElementNs):
        * xml/parser/XMLDocumentParserQt.cpp:
        (WebCore::XMLDocumentParser::parseStartElement):
        (WebCore::XMLDocumentParser::parseEndElement):

858 859 860 861 862 863 864 865 866
2013-03-27  Ryosuke Niwa  <rniwa@webkit.org>

        Debug test fix after r147018.

        toElement() asserts. What we want here is isElementNode().

        * html/parser/HTMLConstructionSite.cpp:
        (WebCore::HTMLConstructionSite::attachLater):

867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915
2013-03-27  Noel Gordon  <noel.gordon@gmail.com>

        Add webp image color profile support
        https://bugs.webkit.org/show_bug.cgi?id=113184

        Reviewed by Eric Seidel.

        Requires libwebp version 0.3.0 (decoder ABI version 0x201). For images
        with an ICC color profile chunk, poll the incremental decoder for the
        current decoded height with the WebPIDecGetRGB() API and color correct
        any newly decoded rows in-situ in the frame buffer.

        Note: the ICC chunk appears before the encoded image frame in the webp
        encoding (RIFF container) format. When the incremental decoder outputs
        decoded pixels, enough encoded data has arrived to read the entire ICC
        color profile data chunk.

        Tests: fast/images/webp-color-profile-lossless.html
               fast/images/webp-color-profile-lossy-alpha.html
               fast/images/webp-color-profile-lossy.html

        * platform/image-decoders/webp/WEBPImageDecoder.cpp:
        (WebCore::WEBPImageDecoder::WEBPImageDecoder):
        (WebCore::WEBPImageDecoder::~WEBPImageDecoder): Call clear().
        (WebCore):
        (WebCore::WEBPImageDecoder::clear):
        Added. Helper to clean up the webp decoder and color transform members.
        (WebCore::WEBPImageDecoder::createColorTransform):
        Create m_transform using the supplied profile memory data. Note that
        the |deviceProfile| is not owned, but the |inputProfile| temporary is
        so release it here with qcms_release_profile().
        (WebCore::WEBPImageDecoder::readColorProfile):
        Called once only when the decoder begins to output decoded rows of an
        image containing an ICC chunk, to read the ICC color profile data from
        the encoded data stream, verify it, and use it to create m_transform.
        (WebCore::WEBPImageDecoder::applyColorProfile):
        Since there is no row callback in libwebp, poll for the decoded height
        of the image so far. If new rows are decoded, color correct the pixels
        of those new rows and re-write them back into the frame buffer using
        buffer.setRGBA() to 1) alpha pre-multiply the pixels if needed, and 2)
        shuffle the pixel bytes into the platform's RGBA pixel endian-ness.
        (WebCore::WEBPImageDecoder::decode):
        If the container format indicates the image has an ICC color profile,
        decode the image to RGBA format for subsequent input to the QCMS color
        correction library in applyColorProfile().
        * platform/image-decoders/webp/WEBPImageDecoder.h:
        (WEBPImageDecoder):
        (WebCore::WEBPImageDecoder::colorTransform): m_transform getter.

916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941
2013-03-27  Jun Jiang  <jun.a.jiang@intel.com>

        Refactor validation checks for texture uploads
        https://bugs.webkit.org/show_bug.cgi?id=111012

        Reviewed by Kenneth Russell.

        Move the validation checks to the entry level of tex{Sub}Image2D, return early for invalid parameters and avoid duplicated checks.
        Moreover, turn all the validation checks at the bottom level - tex{Sub}Image2DBase into assertions.

        Already covered by current tests.

        * html/canvas/WebGLRenderingContext.cpp:
        (WebCore::WebGLRenderingContext::copyTexSubImage2D):
        (WebCore::WebGLRenderingContext::texImage2DBase):
        (WebCore::WebGLRenderingContext::texImage2DImpl):
        (WebCore::WebGLRenderingContext::validateTexFunc): A helper function for tex{Sub}Image2D to check input parameters.
        (WebCore::WebGLRenderingContext::texImage2D):
        (WebCore::WebGLRenderingContext::texSubImage2DBase):
        (WebCore::WebGLRenderingContext::texSubImage2DImpl):
        (WebCore::WebGLRenderingContext::texSubImage2D):
        (WebCore::WebGLRenderingContext::validateHTMLImageElement):
        (WebCore::WebGLRenderingContext::validateHTMLCanvasElement):
        (WebCore::WebGLRenderingContext::validateHTMLVideoElement):
        * html/canvas/WebGLRenderingContext.h:

942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961
2013-03-27  Arnaud Renevier  <a.renevier@sisa.samsung.com>

        remove parentsOnly variable in codeGenerator.pm
        https://bugs.webkit.org/show_bug.cgi?id=113457

        Reviewed by Kentaro Hara.

        Remove unused variable parentsOnly.

        No new tests: no change in behaviour.

        * bindings/scripts/CodeGenerator.pm:
        (ForAllParents):
        (AddMethodsConstantsAndAttributesFromParentInterfaces):
        (ParseInterface):
        (InheritsInterface):
        (InheritsExtendedAttribute):
        * bindings/scripts/CodeGeneratorV8.pm:
        (BaseInterfaceName):

962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072
2013-03-27  Beth Dakin  <bdakin@apple.com>

        Need WK2 API to give a WebView a header and footer
        https://bugs.webkit.org/show_bug.cgi?id=113352
        -and corresponding-
        <rdar://problem/13383835>

        Reviewed by Simon Fraser.

        This API will require RenderLayerCompositor to keep layers for the header and 
        footer when the exist. It also requires the scrolling machinery to know that the 
        size of the scrollable area will differ from the contentsSize when there is a 
        header or footer.

        setWantsLayerForHeader() and setWantsLayerForFooter() return GraphicsLayers to 
        WK2. setHeaderHeight() and setFooterHeight() set the header and footer heights
        respectively.
        * WebCore.exp.in:
        * page/FrameView.h:
        (FrameView):
        * page/FrameView.cpp:
        (WebCore::FrameView::FrameView):
        (WebCore::FrameView::setWantsLayerForHeader):
        (WebCore::FrameView::setWantsLayerForFooter):
        (WebCore::FrameView::setHeaderHeight):
        (WebCore::FrameView::setFooterHeight):

        Should use totalContentsSize() instead of contentsSize().
        (WebCore::FrameView::windowClipRect):
        (WebCore::FrameView::isScrollable):
        * page/SpatialNavigation.cpp:
        (WebCore::canScrollInDirection):

        This should also use totalContentsSize() instead of contentsSize(), and while 
        we're at it, re-name the variable and function names in the scrolling tree code 
        from contentsSize to totalContentsSize.
        * page/scrolling/ScrollingStateScrollingNode.cpp:
        (WebCore::ScrollingStateScrollingNode::ScrollingStateScrollingNode):
        (WebCore::ScrollingStateScrollingNode::setTotalContentsSize):
        (WebCore::ScrollingStateScrollingNode::dumpProperties):
        * page/scrolling/ScrollingStateScrollingNode.h:
        (WebCore::ScrollingStateScrollingNode::totalContentsSize):
        (ScrollingStateScrollingNode):
        * page/scrolling/ScrollingTreeScrollingNode.cpp:
        (WebCore::ScrollingTreeScrollingNode::updateBeforeChildren):
        * page/scrolling/ScrollingTreeScrollingNode.h:
        (WebCore::ScrollingTreeScrollingNode::totalContentsSize):
        (ScrollingTreeScrollingNode):
        * page/scrolling/mac/ScrollingCoordinatorMac.h:
        (ScrollParameters):
        * page/scrolling/mac/ScrollingCoordinatorMac.mm:
        (WebCore::ScrollingCoordinatorMac::frameViewLayoutUpdated):
        (WebCore::ScrollingCoordinatorMac::setScrollParametersForNode):
        * page/scrolling/mac/ScrollingTreeScrollingNodeMac.mm:
        (WebCore::ScrollingTreeScrollingNodeMac::updateAfterChildren):
        (WebCore::ScrollingTreeScrollingNodeMac::setScrollLayerPosition):
        (WebCore::ScrollingTreeScrollingNodeMac::maximumScrollPosition):

        Use totalContentsSize() instead of contentsSize().
        * platform/ScrollView.cpp:
        (WebCore::ScrollView::maximumScrollPosition):
        (WebCore::ScrollView::setScrollOffset):
        (WebCore::ScrollView::overhangAmount):
        (WebCore::ScrollView::updateScrollbars):
        (WebCore::ScrollView::calculateOverhangAreasForPainting):

        scrollOffset() represents the offset within the totalContentsSize, but that is 
        not what we need here. So subtract out the headerHeight() for the appropriate 
        value.
        (WebCore::ScrollView::windowToContents):
        (WebCore::ScrollView::contentsToWindow):

        Use totalContentsSize() instead of contentsSize().
        * platform/ScrollableArea.cpp:
        (WebCore::ScrollableArea::maximumScrollPosition):
        (WebCore):
        (WebCore::ScrollableArea::totalContentsSize):
        * platform/ScrollableArea.h:
        (WebCore::ScrollableArea::headerHeight):
        (WebCore::ScrollableArea::footerHeight):
        (ScrollableArea):
        * platform/mac/ScrollAnimatorMac.mm:
        (WebCore::ScrollAnimatorMac::adjustScrollPositionIfNecessary):
        (WebCore::ScrollAnimatorMac::pinnedInDirection):
        * platform/mac/ThemeMac.mm:
        (WebCore::ThemeMac::ensuredView):

        The rootContentLayer needs to be offset by the headerHeight().
        * rendering/RenderLayerCompositor.cpp:
        (WebCore::RenderLayerCompositor::updateRootLayerPosition):

        New member variables m_layerForHeader and m_layerForFooter. This code properly 
        creates and manages them.
        (WebCore::RenderLayerCompositor::updateLayerForBottomOverhangArea):
        (WebCore::RenderLayerCompositor::updateLayerForHeader):
        (WebCore):
        (WebCore::RenderLayerCompositor::updateLayerForFooter):
        (WebCore::RenderLayerCompositor::computeFixedViewportConstraints):
        (WebCore::RenderLayerCompositor::reportMemoryUsage):
        * rendering/RenderLayerCompositor.h:
        (RenderLayerCompositor):

        Test infrastructure. 
        * testing/Internals.cpp:
        (WebCore::Internals::resetToConsistentState):
        (WebCore::Internals::setHeaderHeight):
        (WebCore):
        (WebCore::Internals::setFooterHeight):
        * testing/Internals.h:
        * testing/Internals.idl:

1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150
2013-03-27  Arnaud Renevier  <a.renevier@sisa.samsung.com>

        javascriptcore bindings do not check exception after calling valueToStringWithNullCheck
        https://bugs.webkit.org/show_bug.cgi?id=113219

        Reviewed by Kentaro Hara.

        When converting JSValue to native value in attribute setter, store the
        native value in a temporary variable. After this variable assignment,
        always check if an exception has been raised.

        Update binding tests.

        Test: fast/dom/exception-in-binding.html

        * bindings/scripts/CodeGeneratorJS.pm:
        (GenerateImplementation):
        (GetNativeType):
        (JSValueToNative):
        * bindings/scripts/test/JS/JSTestInterface.cpp:
        (WebCore::setJSTestInterfaceConstructorSupplementalStaticAttr):
        (WebCore::setJSTestInterfaceSupplementalStr2):
        (WebCore::setJSTestInterfaceSupplementalNode):
        * bindings/scripts/test/JS/JSTestObj.cpp:
        (WebCore::setJSTestObjConstructorStaticStringAttr):
        (WebCore::setJSTestObjEnumAttr):
        (WebCore::setJSTestObjShortAttr):
        (WebCore::setJSTestObjUnsignedShortAttr):
        (WebCore::setJSTestObjLongAttr):
        (WebCore::setJSTestObjLongLongAttr):
        (WebCore::setJSTestObjUnsignedLongLongAttr):
        (WebCore::setJSTestObjStringAttr):
        (WebCore::setJSTestObjTestObjAttr):
        (WebCore::setJSTestObjXMLObjAttr):
        (WebCore::setJSTestObjCreate):
        (WebCore::setJSTestObjReflectedStringAttr):
        (WebCore::setJSTestObjReflectedIntegralAttr):
        (WebCore::setJSTestObjReflectedUnsignedIntegralAttr):
        (WebCore::setJSTestObjReflectedBooleanAttr):
        (WebCore::setJSTestObjReflectedURLAttr):
        (WebCore::setJSTestObjReflectedCustomIntegralAttr):
        (WebCore::setJSTestObjReflectedCustomBooleanAttr):
        (WebCore::setJSTestObjReflectedCustomURLAttr):
        (WebCore::setJSTestObjTypedArrayAttr):
        (WebCore::setJSTestObjAttrWithGetterException):
        (WebCore::setJSTestObjAttrWithSetterException):
        (WebCore::setJSTestObjStringAttrWithGetterException):
        (WebCore::setJSTestObjStringAttrWithSetterException):
        (WebCore::setJSTestObjWithScriptStateAttribute):
        (WebCore::setJSTestObjWithScriptExecutionContextAttribute):
        (WebCore::setJSTestObjWithScriptStateAttributeRaises):
        (WebCore::setJSTestObjWithScriptExecutionContextAttributeRaises):
        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttribute):
        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateAttributeRaises):
        (WebCore::setJSTestObjWithScriptExecutionContextAndScriptStateWithSpacesAttribute):
        (WebCore::setJSTestObjWithScriptArgumentsAndCallStackAttribute):
        (WebCore::setJSTestObjConditionalAttr1):
        (WebCore::setJSTestObjConditionalAttr2):
        (WebCore::setJSTestObjConditionalAttr3):
        (WebCore::setJSTestObjAnyAttribute):
        (WebCore::setJSTestObjMutablePoint):
        (WebCore::setJSTestObjImmutablePoint):
        (WebCore::setJSTestObjStrawberry):
        (WebCore::setJSTestObjStrictFloat):
        (WebCore::setJSTestObjId):
        (WebCore::setJSTestObjNullableLongSettableAttribute):
        (WebCore::setJSTestObjNullableStringValue):
        * bindings/scripts/test/JS/JSTestSerializedScriptValueInterface.cpp:
        (WebCore::setJSTestSerializedScriptValueInterfaceValue):
        (WebCore::setJSTestSerializedScriptValueInterfaceCachedValue):
        * bindings/scripts/test/JS/JSTestTypedefs.cpp:
        (WebCore::setJSTestTypedefsUnsignedLongLongAttr):
        (WebCore::setJSTestTypedefsImmutableSerializedScriptValue):
        (WebCore::setJSTestTypedefsAttrWithGetterException):
        (WebCore::setJSTestTypedefsAttrWithSetterException):
        (WebCore::setJSTestTypedefsStringAttrWithGetterException):
        (WebCore::setJSTestTypedefsStringAttrWithSetterException):

1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168
2013-03-27  Arnaud Renevier  <a.renevier@sisa.samsung.com>

        cache parsed interfaces in CodeGenerator.pm
        https://bugs.webkit.org/show_bug.cgi?id=113446

        Reviewed by Kentaro Hara.

        When generating binding for an interface, informations about parent
        interfaces are sometimes needed several times. This patch caches
        those the parsed interface. When generating all WebCore bindings, this
        results in a speedup of about 40% for JavaScriptCore and about 80% for
        V8.

        No new tests: no change in behaviour.

        * bindings/scripts/CodeGenerator.pm:
        (ParseInterface):

1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206
2013-03-27  KyungTae Kim <ktf.kim@samsung.com> and Yongjun Zhang  <yongjun_zhang@apple.com>

        Add a settings to disallow initializing background-size if background shorthand doesn't include it.
        https://bugs.webkit.org/show_bug.cgi?id=113363

        Reviewed by David Kilzer.

        This is based on KyungTae Kim's patch in https://bugs.webkit.org/show_bug.cgi?id=97761.  Many legacy sites set
        background-size first and then set background for setting background-image.  For backward-compatibility
        in some WebKit based clients, if 'background' shorthand have no 'background-size' attribute, we could add
        a settings to let the css parser not initialize 'background-size'.

        Test: fast/backgrounds/background-shorthand-after-set-backgroundSize.html

        * css/CSSParser.cpp:
        (WebCore::CSSParserContext::CSSParserContext): initialize useLegacyBackgroundSizeShorthandBehavior.
        (WebCore::operator==):
        (WebCore::CSSParser::useLegacyBackgroundSizeShorthandBehavior): add a method to return if we want background-size
            to be initialized by background shorthand.
        (WebCore):
        (WebCore::CSSParser::parseFillShorthand): don't initialize background-size in background shorthand if we have
            useLegacyBackgroundSizeShorthandBehavior set to true.
        * css/CSSParser.h:
        (CSSParser):
        * css/CSSParserMode.h: add member useLegacyBackgroundSizeShorthandBehavior to CSSParserContext.
        (CSSParserContext):
        * page/Settings.in: initialize useLegacyBackgroundSizeShorthandBehavior to false.
        * testing/InternalSettings.cpp:
        (WebCore::InternalSettings::Backup::Backup): add the new settings useLegacyBackgroundSizeShorthandBehavior to Backup.
        (WebCore::InternalSettings::Backup::restoreTo): restore useLegacyBackgroundSizeShorthandBehavior from Backup.
        (WebCore::InternalSettings::setUseLegacyBackgroundSizeShorthandBehavior):
        (WebCore):
        * testing/InternalSettings.h:
        (Backup):
        (InternalSettings):
        * testing/InternalSettings.idl: add a JS testing API setUseLegacyBackgroundSizeShorthandBehavior to turn on/off
            the new settings.

1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219
2013-03-27  Florin Malita  <fmalita@chromium.org>

        Remove unused RenderLayer::renderBox{X,Y} methods
        https://bugs.webkit.org/show_bug.cgi?id=113408

        Reviewed by Simon Fraser.

        Minor cleanup - renderBoxX() and renderBox() are no longer used.

        No new tests: no functional changes.

        * rendering/RenderLayer.h:

1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268
2013-03-27  PhistucK  <phistuck@chromium.org>

        Web Inspector: Plumb and expose cookie clearing options throughout the Resources Cookies tree and views
        https://bugs.webkit.org/show_bug.cgi?id=87140

        Reviewed by Vsevolod Vlasov.

        Added cookie clearing buttons and context menu options
        throughout the tree and views.
        Drive by -
        - Made sure the delete button is only visible
        when a cookie is selected.
        - Fixed a wrong JSDoc comment.

        * inspector/front-end/CookieItemsView.js:
        (WebInspector.CookieItemsView):
        (WebInspector.CookieItemsView.prototype.statusBarItems):
        (WebInspector.CookieItemsView.prototype._updateWithCookies):
        (WebInspector.CookieItemsView.prototype.clear):
        Added. Clears the entire cookie view.
        (WebInspector.CookieItemsView.prototype._clearButtonClicked):
        Added. Ditto (when clicking on the button).
        (WebInspector.CookieItemsView.prototype._showDeleteButton):
        Added. Shows the delete button when selecting a cookie row.
        * inspector/CookiesTable.js:
        (WebInspector.CookiesTable):
        (WebInspector.CookiesTable.prototype._clearAndRefresh):
        Added. Clears the cookies of the current table and updates it.
        (WebInspector.CookiesTable.prototype._handleContextMenuEvent):
        Added. Manages the context menu within the table.
        (WebInspector.CookiesTable.prototype.clear):
        Added. Clears the cookies of the current table.
        (WebInspector.CookiesTable.prototype.setCookies):
         Fixed a wrong JSDoc comment structure.
        * inspector/front-end/ResourcesPanel.js:
        (WebInspector.ResourcesPanel.prototype.clearCookies):
        Added. Clears the cookies of the given domain view.
        (WebInspector.CookieTreeElement.prototype.onattach):
        Added. Adds a contextmenu handler.
        (WebInspector.CookieTreeElement.prototype._handleContextMenuEvent):
        Added. Manages the context menu within cookie tree.
        (WebInspector.CookieTreeElement.prototype._clearCookies):
        Added. Clears the cookies of the view of the tree item.
        * inspector/front-end/treeoutline.js:
        (TreeOutline): Fixed a wrong JSDoc comment.

        * English.lproj/localizedStrings.js:
        Added strings for the context menu options.

1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294
2013-03-27  Andrey Lushnikov  <lushnikov@chromium.org>

        Web Inspector: [DTE] implement "tokenAtTextPosition" method
        https://bugs.webkit.org/show_bug.cgi?id=113390

        Reviewed by Pavel Feldman.

        Test: inspector/editor/text-editor-token-at-position.html

        - Add TextEditor.tokenAtTextPosition method
        - Implement tokenAtTextPosition method in DefaultTextEditor

        * inspector/front-end/DefaultTextEditor.js:
        (WebInspector.DefaultTextEditor.prototype.tokenAtTextPosition):
        (WebInspector.TextEditorMainPanel.prototype.compare):
        (WebInspector.TextEditorMainPanel.prototype.tokenAtTextPosition):
        (WebInspector.TextEditorMainPanel.prototype._tokenAtUnhighlightedLine):
        (WebInspector.TextEditorMainPanel.prototype.set mimeType):
        (WebInspector.TextEditorMainPanel.prototype.get mimeType):
        * inspector/front-end/TextEditor.js:
        (WebInspector.TextEditor.prototype.tokenAtTextPosition):
        * inspector/front-end/TextEditorHighlighter.js:
        (WebInspector.TextEditorHighlighter):
        (WebInspector.TextEditorHighlighter.prototype.get mimeType):
        (WebInspector.TextEditorHighlighter.prototype.set mimeType):

1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331
2013-03-27  Charles Wei  <charles.wei@torchmobile.com.cn>

        Remove build warning for unused function parameters in indexeddb.
        https://bugs.webkit.org/show_bug.cgi?id=113043

        Reviewed by Tony Chang.

        No new tests, just remove build warning.

        * Modules/indexeddb/IDBCallbacks.h:
        (WebCore::IDBCallbacks::onBlocked):
        (WebCore::IDBCallbacks::onUpgradeNeeded):
        * Modules/indexeddb/IDBCursor.cpp:
        (WebCore::IDBCursor::stringToDirection):
        * Modules/indexeddb/IDBCursor.h:
        (IDBCursor):
        * Modules/indexeddb/IDBCursorBackendImpl.cpp:
        (WebCore::IDBCursorBackendImpl::prefetchReset):
        * Modules/indexeddb/IDBDatabase.cpp:
        (WebCore::IDBDatabase::transaction):
        * Modules/indexeddb/IDBDatabaseBackendImpl.cpp:
        (WebCore::IDBDatabaseBackendImpl::setIndexesReady):
        * Modules/indexeddb/IDBIndex.cpp:
        (WebCore::IDBIndex::openCursor):
        (WebCore::IDBIndex::openKeyCursor):
        * Modules/indexeddb/IDBLevelDBCoding.cpp:
        (IDBLevelDBCoding):
        * Modules/indexeddb/IDBObjectStore.cpp:
        (WebCore):
        (WebCore::IDBObjectStore::openCursor):
        * Modules/indexeddb/IDBTransaction.cpp:
        (WebCore::IDBTransaction::stringToMode):
        * Modules/indexeddb/IDBTransaction.h:
        (IDBTransaction):
        * inspector/InspectorIndexedDBAgent.cpp:
        (WebCore):

1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345
2013-03-27  Sergey Ryazanov  <serya@chromium.org>

        REGRESSION (r146588): Cannot correctly display Chinese SNS Renren
        https://bugs.webkit.org/show_bug.cgi?id=113142

        Reviewed by Pavel Feldman.

        Changed CSS grammar to be equivalent to pre-r146588.
        CSS error reporting disabled to prevent message overflow.

        * css/CSSGrammar.y.in:
        * css/CSSParser.cpp:
        (WebCore::CSSParser::isLoggingErrors):

1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363
2013-03-27  Andrey Lushnikov  <lushnikov@chromium.org>

        Web Inspector: enhance Popover.js to rely on hover element coordinates
        https://bugs.webkit.org/show_bug.cgi?id=113340

        Reviewed by Pavel Feldman.

        No new tests: no change in behaviour.

        Introduce a coordinates-based method that checks if mouse is inside hover
        element and use it in PopoverHelper instead of DOM hierarchy.

        * inspector/front-end/Popover.js:
        (WebInspector.PopoverHelper.prototype._eventInHoverElement): Added.
        (WebInspector.PopoverHelper.prototype._mouseDown):
        (WebInspector.PopoverHelper.prototype._mouseMove):
        (WebInspector.PopoverHelper.prototype._mouseOut):

1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378
2013-03-27  Andrey Lushnikov  <lushnikov@chromium.org>

        Web Inspector: [CodeMirror] fix webinspector-css theme for CodeMirror
        https://bugs.webkit.org/show_bug.cgi?id=113399

        Reviewed by Alexander Pavlov.

        Add style rule to highlight css properties for CodeMirror
        webinspector-css theme.

        No new tests: no change in behaviour.

        * inspector/front-end/cm/cmdevtools.css:
        (.cm-s-web-inspector-css span.cm-property):

1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393
2013-03-27  Andrey Lushnikov  <lushnikov@chromium.org>

        Web Inspector: [DTE] paint overlay highlight for unhighlighted lines
        https://bugs.webkit.org/show_bug.cgi?id=113344

        Reviewed by Pavel Feldman.

        No new tests.

        Remove fast-return condition from paintLine method that checked for
        highlight existence.

        * inspector/front-end/DefaultTextEditor.js:
        (WebInspector.TextEditorMainPanel.prototype._paintLine):

1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418
2013-03-27  Ryosuke Niwa  <rniwa@webkit.org>

        Shift clicking on an element with -webkit-user-select: all doesn't extend selection
        https://bugs.webkit.org/show_bug.cgi?id=113270

        Reviewed by Enrica Casucci.

        The bug was caused by updateSelectionForMouseDownDispatchingSelectStart always replacing selection whenever
        the target node was inside an element with -webkit-suer-select even when we were attemping to extend selection
        in handleMousePressEventSingleClick.

        Fixed the bug by extracting this logic as a separate function (expandSelectionToRespectUserSelectAll) and deploying
        it in handleMousePressEventSingleClick to extend selection as needed.

        Test: editing/selection/user-select-all-with-shift.html

        * page/EventHandler.cpp:
        (WebCore::expandSelectionToRespectUserSelectAll): Extracted from updateSelectionForMouseDownDispatchingSelectStart.
        (WebCore::EventHandler::updateSelectionForMouseDownDispatchingSelectStart):
        (WebCore::EventHandler::selectClosestWordFromHitTestResult):
        (WebCore::EventHandler::selectClosestWordOrLinkFromMouseEvent):
        (WebCore::EventHandler::handleMousePressEventTripleClick):
        (WebCore::EventHandler::handleMousePressEventSingleClick): Adjust "pos" as needed when extending selection.
        Also use shouldConsiderSelectionAsDirectional() instead of manually peeking editingBehaviorType while we're at it.

1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439
2013-03-27  Zalan Bujtas  <zalan@apple.com>

        REGRESSION(r143102): iframe with percentage height within table with anonymous cell fails.
        https://bugs.webkit.org/show_bug.cgi?id=113077

        Reviewed by Antti Koivisto.
        
        http://www.w3.org/TR/CSS21/visuren.html#anonymous-block-level
        "Anonymous block boxes are ignored when resolving percentage values that would refer to it:
        the closest non-anonymous ancestor box is used instead."
        When figuring out whether auto height needs to be applied on the current box, ignore anonymous
        ancestors until the first non-anonymous containing block is found. This matches both
        Firefox and Opera behaviour.
        
        Test: fast/replaced/iframe-with-percentage-height-within-table-with-anonymous-table-cell.html

        * rendering/RenderBoxModelObject.cpp:
        (WebCore::RenderBoxModelObject::hasAutoHeightOrContainingBlockWithAutoHeight): Switch from
        isAnonymousBlock() to isAnonymous() to make sure all anonymous boxes are ignored.
        Remove isTableCell() check which is a noop as table cell isn't an anonymous block.
        
1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454
2013-03-27  Pierre Rossi  <pierre.rossi@gmail.com>

        [Qt] Add WOFF support when using zlib
        https://bugs.webkit.org/show_bug.cgi?id=112805

        Reviewed by Allan Sandfeld Jensen.

        Covered by existing test:
        fast/css/font-face-woff.html

        * Target.pri: Conditional inclusion of WOFFFileFormat
        * platform/graphics/qt/FontCustomPlatformDataQt.cpp:
        (WebCore::createFontCustomPlatformData): Try to unpack WOFF data, otherwise spit out a warning and bail.
        (WebCore::FontCustomPlatformData::supportsFormat): accept WOFF webfonts if USE(ZLIB).

1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479
2013-03-27  Robert Hogan  <robert@webkit.org>

        Growing a position:absolute element in a position:relative one in a table does not update scrollHeight
        https://bugs.webkit.org/show_bug.cgi?id=111977

        Reviewed by David Hyatt.

        During simplified layout tables still need to know about overflow from positioned objects in any of
        their cells.

        Test: fast/table/cell-overflow-simplified-layout.html

        * rendering/RenderBlock.h:
        (RenderBlock):
        * rendering/RenderTable.cpp:
        (WebCore::RenderTable::simplifiedNormalFlowLayout):
        (WebCore):
        * rendering/RenderTable.h:
        * rendering/RenderTableSection.cpp:
        (WebCore::RenderTableSection::layoutRows):
        (WebCore):
        (WebCore::RenderTableSection::computeOverflowFromCells):
        * rendering/RenderTableSection.h:
        (RenderTableSection):

1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508
2013-03-22  Geoffrey Garen  <ggaren@apple.com>

        Honor the setting for whether JavaScript markup is enabled
        https://bugs.webkit.org/show_bug.cgi?id=113122

        Reviewed by Ryosuke Niwa.

        * dom/ScriptableDocumentParser.cpp:
        (WebCore::ScriptableDocumentParser::ScriptableDocumentParser): Applied the
        setting here, so all document parsing would be covered. This is similar
        to what we do for plug-in stripping.

        * html/parser/HTMLConstructionSite.cpp:
        (WebCore::HTMLConstructionSite::insertForeignElement): Fixed a bug where
        we would insert an SVG script element into the document even in script
        markup disabled mode.

        (This bug has existed for copy/paste for a long time, but other bugs and
        quirks in SVG copy/paste papered over it. It's a serious issue now
        that non-paste clients will rely on this mode.)

        * html/parser/HTMLTreeBuilder.cpp:
        (WebCore::HTMLTreeBuilder::processTokenInForeignContent): Fixed the same
        bug -- this time in the part of the parser that executes scripts as they
        parse.

        I adopted the toScriptElement() convention for testing for a script
        element to match the XML parser.

1509 1510 1511 1512 1513 1514 1515 1516 1517
2013-03-27  Dean Jackson  <dino@apple.com>

        Chromium Mac fails to build after r146995 because the new NSFont category
        may conflict with the system. Add the WebCoreTheme category to the whitelist.

        Unreviewed.

        * WebCore.gyp/WebCore.gyp:

1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531
2013-03-27  Ryosuke Niwa  <rniwa@webkit.org>

        Selection code spends a lot of time in InlineTextBox::localSelectionRect
        https://bugs.webkit.org/show_bug.cgi?id=113364

        Reviewed by Enrica Casucci.

        Avoid computing the font width when we're selecting the entire line box.

        This appears to be 25-26% improvement on Interactive/SelectAll:Time.

        * rendering/InlineTextBox.cpp:
        (WebCore::InlineTextBox::localSelectionRect):

1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567
2013-03-26  Timothy Hatcher  <timothy@apple.com>

        Add support for dock-to-right of the Web Inspector in the Mac port.

        Unfortunately this requires Safari changes, so it is disabled in the nightly builds.

        https://webkit.org/b/113341
        rdar://problem/10368152

        Reviewed by Joseph Pecoraro.

        * WebCore.exp.in:
        * inspector/InspectorFrontendClient.h:
        (InspectorFrontendClient):
        * inspector/InspectorFrontendClientLocal.cpp:
        (WebCore):
        (WebCore::InspectorFrontendClientLocal::frontendLoaded):
        (WebCore::InspectorFrontendClientLocal::requestSetDockSide):
        (WebCore::InspectorFrontendClientLocal::canAttachWindow):
        (WebCore::InspectorFrontendClientLocal::changeAttachedWindowWidth):
        (WebCore::InspectorFrontendClientLocal::setAttachedWindow):
        (WebCore::InspectorFrontendClientLocal::constrainedAttachedWindowWidth):
        * inspector/InspectorFrontendClientLocal.h:
        (InspectorFrontendClientLocal):
        * inspector/InspectorFrontendHost.cpp:
        (WebCore::InspectorFrontendHost::setAttachedWindowWidth):
        (WebCore):
        * inspector/InspectorFrontendHost.h:
        (InspectorFrontendHost):
        * inspector/InspectorFrontendHost.idl:
        * inspector/front-end/InspectorFrontendHostStub.js:
        (.WebInspector.InspectorFrontendHostStub.prototype.setAttachedWindowWidth):
        * inspector/front-end/externs.js:
        (InspectorFrontendHostAPI.prototype.setAttachedWindowWidth):
        * testing/Internals.cpp:

1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591
2013-03-27  Eric Carlson  <eric.carlson@apple.com>

        [Mac] webkitClosedCaptionsVisible doesn't work
        https://bugs.webkit.org/show_bug.cgi?id=113417

        Reviewed by Jer Noble.

        Test: media/track/track-in-band-legacy-api.html

        * html/HTMLMediaElement.cpp:
        (WebCore::HTMLMediaElement::HTMLMediaElement): Delete m_disableCaptions, it is no longer used.
        (WebCore::HTMLMediaElement::configureTextTrackGroup): Pass this to textTrackSelectionScore.
        (WebCore::HTMLMediaElement::setClosedCaptionsVisible):  Delete m_disableCaptions, it is no longer used.
        * html/HTMLMediaElement.h: Ditto.

        * page/CaptionUserPreferences.cpp:
        (WebCore::CaptionUserPreferences::textTrackSelectionScore): Add an HTMLMediaElement parameter.
        * page/CaptionUserPreferences.h:

        * page/CaptionUserPreferencesMac.h:
        * page/CaptionUserPreferencesMac.mm:
        (WebCore::CaptionUserPreferencesMac::textTrackSelectionScore): Return a score if the media element
            is showing captions, even if the preference says captions are disabled.

1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603
2013-03-27  Eric Carlson  <eric.carlson@apple.com>

        [Mac] Text track menu items sometimes labeled incorrectly
        https://bugs.webkit.org/show_bug.cgi?id=113406

        Reviewed by Jer Noble.

        media/video-controls-captions-trackmenu-localized.html was updated to test this.

        * page/CaptionUserPreferencesMac.mm:
        (WebCore::trackDisplayName): Use the 'label' attribute for the menu text when necessary.

1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627
2013-03-27  Sergio Villar Senin  <svillar@igalia.com>

        Inserting a blank (" ") at the end of a line does not insert anything in Overtype mode
        https://bugs.webkit.org/show_bug.cgi?id=113413

        Reviewed by Ryosuke Niwa.

        Perform a "normal" insert instead of a replace when there is
        nothing to replace (like at the end of a line) as this case is not
        supported by the replacing code path. This will allow us to
        properly rebalance whitespaces in those cases.

        Updated the editing/execCommand/overtype.html test to check also
        this use case.

        * editing/InsertTextCommand.cpp:
        (WebCore::InsertTextCommand::setEndingSelectionWithoutValidation):
        (WebCore::InsertTextCommand::performTrivialReplace):
        (WebCore::InsertTextCommand::performOverwrite):
        (WebCore::InsertTextCommand::doApply): use the recently added
        setEndingSelectionWithoutValidation() to avoid code duplication.
        * editing/InsertTextCommand.h:
        (InsertTextCommand):

1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648
2013-03-27  Dean Jackson  <dino@apple.com>

        [Mac] Use fontName rather than familyName for internal fonts
        https://bugs.webkit.org/show_bug.cgi?id=113392
        <rdar://problem/13474743>

        Reviewed by Enrica Casucci.

        Some internal fonts on OS X have a family name that
        isn't listed in availableFontFamilies. In this case
        we should use the font name rather than the family
        name when looking for a match.

        * platform/mac/ThemeMac.h: NSFont category to provide a web-friendly family name.
        * platform/mac/ThemeMac.mm:
        (-[NSFont webCoreFamilyName]): Returns the font name for internal fonts, otherwise the family name.
        (WebCore::ThemeMac::controlFont):
        * rendering/RenderThemeMacShared.mm: Use the webCoreFamilyName.
        (WebCore::RenderThemeMacShared::systemFont): Ditto.
        (WebCore::RenderThemeMacShared::setFontFromControlSize): Ditto.

1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699
2013-03-26  Jer Noble  <jer.noble@apple.com>

        Mac: Media Controls always hide time display elements
        https://bugs.webkit.org/show_bug.cgi?id=113355

        Reviewed by Eric Carlson.

        No new tests; rebaselined existing tests against correct behavior.

        A prior commit set the "min-width:0" property on the time display elements, which, combined
        with the "-webkit-flex-box:0 0" setting, caused the flex-box container to collapse the width
        of the elements to zero. To achieve the desired effect of hiding the time display elements,
        first set the elements' min-width to the desired width, as the new flex-box spec treats the
        default value of "min-width:auto" as the intrinsic width, and will collapse the text display
        elements to the intrinsic width of its contained text node.

        The above allows the timeline container to collapse beyond the sum of its childrens'
        intrinsic width. Create a custom renderer that detects when this happens, and hide the time
        display controls.

        * css/mediaControls.css:
        * css/mediaControlsQuickTime.css:
        (audio::-webkit-media-controls-current-time-display, video::-webkit-media-controls-current-time-display):
            Set the "min-width:" property to equal the "width:" property.
        (audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display):
            Ditto.
        * css/mediaControlsChromium.css:
        (audio::-webkit-media-controls-time-remaining-display, video::-webkit-media-controls-time-remaining-display):
            Chromium assumes the time display controls are flex-boxes, so make that explicit.
        * html/shadow/MediaControlElementTypes.cpp: Removed MediaControlTimeDisplayElement::createRenderer().
        * html/shadow/MediaControlElementTypes.h:
        (MediaControlTimeDisplayElement): Ditto.
        * html/shadow/MediaControlElements.cpp:
        (WebCore::MediaControlTimelineContainerElement::setTimeDisplaysHidden): Added, walks through the 
            container's children and shows or hides time display elements.
        (WebCore::MediaControlTimelineContainerElement::createRenderer): Added, creates a RenderMediaControlTimelineContainer.
        (WebCore::getMediaControlTimeRemainingDisplayElementShadowPseudoId): Added, allow setTimeDisplaysHidden to
            query against children's shadowPseudoId().
        (WebCore::MediaControlTimeRemainingDisplayElement::shadowPseudoId): Moved contents to getMediaControlTimeRemainingDisplayElementShadowPseudoId.
        (WebCore::getMediaControlCurrentTimeDisplayElementShadowPseudoId): Added, allow setTimeDisplaysHidden to
            query against children's shadowPseudoId().
        (WebCore::MediaControlCurrentTimeDisplayElement::shadowPseudoId): Moved contents to getMediaControlCurrentTimeDisplayElementShadowPseudoId.
        * html/shadow/MediaControlElements.h:
        (MediaControlTimelineContainerElement):
        * rendering/RenderMediaControlElements.cpp:
        (WebCore::RenderMediaControlTimelineContainer::RenderMediaControlTimelineContainer): Added, simple constructor.
        (WebCore::RenderMediaControlTimelineContainer::layout): Detect when the controller's width is greater than
            a certain value, and show or hide the time display elements in response.
        * rendering/RenderMediaControlElements.h:
        (RenderMediaControlTimelineContainer):

1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714
2013-03-27  Ilya Tikhonovsky  <loislo@chromium.org>

        Web Inspector: CPU profiler. Swap FlameChart with Data Grid.
        https://bugs.webkit.org/show_bug.cgi?id=113395

        Reviewed by Pavel Feldman.

        Looks like FlameChart is more powerful and flexible instrument
        than plain old ProfileTree in DataGrid. The same action like
        'look for the most expensive function in a frame' could be easily
        done with FlameChart and need number of clicks in DataGrid.
        So in an offline discussion we decided to place FlameChart on top of DataGrid.

        * inspector/front-end/CPUProfileView.js:

1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727
2013-03-27  Chris Fleizach  <cfleizach@apple.com>

        Regression in tests due to https://bugs.webkit.org/show_bug.cgi?id=113339
        https://bugs.webkit.org/show_bug.cgi?id=113361

        Fix the red bots. No review.

        Ensure only pop-up buttons get the AXRequired attribute instead of all buttons.        

        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
        (-[WebAccessibilityObjectWrapper additionalAccessibilityAttributeNames]):
        (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):

1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758
2013-03-27  Vsevolod Vlasov  <vsevik@chromium.org>

        Web Inspector: Breakpoint manager should restore breakpoints when uiSourceCode is added.
        https://bugs.webkit.org/show_bug.cgi?id=113381

        Reviewed by Pavel Feldman.

        Breakpoint manager now restores breakpoints on UISourceCodeAdded event.
        Breakpoint manager now only resets breakpoints in debugger when source mapping is changed to/from non identity one.

        * inspector/front-end/BreakpointManager.js:
        (WebInspector.BreakpointManager.prototype._uiSourceCodeAdded):
        (WebInspector.BreakpointManager.prototype._resetBreakpoints):
        (WebInspector.BreakpointManager.prototype._uiSourceCodeMappingChanged):
        * inspector/front-end/CompilerScriptMapping.js:
        (WebInspector.CompilerScriptMapping.prototype.get isIdentity):
        * inspector/front-end/DefaultScriptMapping.js:
        (WebInspector.DefaultScriptMapping.prototype.isIdentity):
        * inspector/front-end/ResourceScriptMapping.js:
        (WebInspector.ResourceScriptMapping.prototype.isIdentity):
        * inspector/front-end/SASSSourceMapping.js:
        (WebInspector.SASSSourceMapping.prototype.isIdentity):
        * inspector/front-end/ScriptSnippetModel.js:
        (WebInspector.SnippetScriptMapping.prototype.isIdentity):
        * inspector/front-end/SourceMapping.js:
        (WebInspector.SourceMapping.prototype.isIdentity):
        * inspector/front-end/StylesSourceMapping.js:
        (WebInspector.StylesSourceMapping.prototype.isIdentity):
        * inspector/front-end/UISourceCode.js:
        (WebInspector.UISourceCode.prototype.setSourceMapping):

1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770
2013-03-27  Yury Semikhatsky  <yurys@chromium.org>

        Web Inspector: update Timeline.TimelineEvent definition to include DOM counters and native memory stats
        https://bugs.webkit.org/show_bug.cgi?id=113376

        Reviewed by Vsevolod Vlasov.

        Fixed assertion failure in debug mode after r146975.

        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline):

1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785
2013-03-27  Ilya Tikhonovsky  <loislo@chromium.org>

        Web Inspector: FlameChart. Provide 15px padding left for the chart so developers will see the first divider with '0' title.
        https://bugs.webkit.org/show_bug.cgi?id=113404

        Reviewed by Pavel Feldman.

        15px paddingLeft was added to the code for the chart.

        * inspector/front-end/FlameChart.js:
        (WebInspector.FlameChart):
        (WebInspector.FlameChart.Calculator.prototype._updateBoundaries):
        (WebInspector.FlameChart.Calculator.prototype.computePosition):
        (WebInspector.FlameChart.prototype.draw):

1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828
2013-03-27  Kent Tamura  <tkent@chromium.org>

        Rename HTMLFormControlElement::readOnly to isReadOnly
        https://bugs.webkit.org/show_bug.cgi?id=113297

        Reviewed by Alexey Proskuryakov.

        HTMLFormControlElement::readOnly is not an implementation of
        'readOnly' IDL attribute. It's confusing and we don't need to
        violate our naming convention.

        No new tests. Just a refactoring.

        * accessibility/AccessibilityNodeObject.cpp:
        (WebCore::AccessibilityNodeObject::isReadOnly):
        * html/BaseMultipleFieldsDateAndTimeInputType.cpp:
        (WebCore::BaseMultipleFieldsDateAndTimeInputType::isEditControlOwnerReadOnly):
        * html/HTMLFormControlElement.cpp:
        (WebCore::HTMLFormControlElement::HTMLFormControlElement):
        (WebCore::HTMLFormControlElement::parseAttribute):
        * html/HTMLFormControlElement.h:
        (WebCore::HTMLFormControlElement::isReadOnly):
        (WebCore::HTMLFormControlElement::isDisabledOrReadOnly):
        * html/HTMLInputElement.cpp:
        (WebCore::HTMLInputElement::matchesReadOnlyPseudoClass):
        (WebCore::HTMLInputElement::matchesReadWritePseudoClass):
        * html/HTMLTextAreaElement.cpp:
        (WebCore::HTMLTextAreaElement::matchesReadOnlyPseudoClass):
        (WebCore::HTMLTextAreaElement::matchesReadWritePseudoClass):
        * html/shadow/SliderThumbElement.cpp:
        (WebCore::SliderThumbElement::defaultEventHandler):
        (WebCore::SliderThumbElement::willRespondToMouseMoveEvents):
        (WebCore::SliderThumbElement::willRespondToMouseClickEvents):
        * html/shadow/TextControlInnerElements.cpp:
        (WebCore::InputFieldSpeechButtonElement::willRespondToMouseClickEvents):
        (WebCore::InputFieldSpeechButtonElement::setRecognitionResult):
        * html/shadow/TextFieldDecorationElement.cpp:
        (WebCore::TextFieldDecorationElement::updateImage):
        * rendering/RenderTextControl.cpp:
        (WebCore::updateUserModifyProperty):
        * rendering/RenderThemeMacShared.mm:
        (WebCore::RenderThemeMacShared::paintSearchFieldCancelButton):

1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846
2013-03-27  Yury Semikhatsky  <yurys@chromium.org>

        Web Inspector: update Timeline.TimelineEvent definition to include DOM counters and native memory stats
        https://bugs.webkit.org/show_bug.cgi?id=113376

        Reviewed by Vsevolod Vlasov.

        Added missing fields to Timeline.TimelineEvent type definition in Inspector.json

        * inspector/Inspector.json:
        * inspector/InspectorTimelineAgent.cpp:
        (WebCore::InspectorTimelineAgent::innerAddRecordToTimeline):
        (WebCore::InspectorTimelineAgent::setDOMCounters):
        Switched InspectorTimelineAgent to the new typed event builders.
        (WebCore::InspectorTimelineAgent::setNativeHeapStatistics):
        * inspector/InspectorTimelineAgent.h:
        (InspectorTimelineAgent):

1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858
2013-03-27  Vsevolod Vlasov  <vsevik@chromium.org>

        Web Inspector: Follow-up to r146898: test that uiSourceCodes are not leaking in breakpoint manager.
        https://bugs.webkit.org/show_bug.cgi?id=113368

        Reviewed by Pavel Feldman.

        Added a missed line and a test.

        * inspector/front-end/BreakpointManager.js:
        (WebInspector.BreakpointManager.prototype._projectWillReset):

1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875
2013-03-27  Andrey Lushnikov  <lushnikov@chromium.org>

        Web Inspector: [CodeMirror] CodeMirrorTextEditor.highlightRange has bugs
        https://bugs.webkit.org/show_bug.cgi?id=113348

        Reviewed by Vsevolod Vlasov.

        No new tests.

        - Append additional "<class>-start" class to the first highlighted span
        and "<class>-end" class to the last highlighted span to provide a way
        to set up a css classes with borders.
        - Increment end column of the markup range to simulate inclusive range.

        * inspector/front-end/CodeMirrorTextEditor.js:
        (WebInspector.CodeMirrorTextEditor.prototype.highlightRange):

1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900
2013-03-27  Andrey Lushnikov  <lushnikov@chromium.org>

        Web Inspector: Add isClean/markClean method pair to textEditor.js
        https://bugs.webkit.org/show_bug.cgi?id=112815

        Reviewed by Vsevolod Vlasov.

        No new tests: no change in behaviour.

        - Add TextEditor.isClean and TextEditor.markClean methods
        - Implement these methods in DefaultTextEditor
        - Implement these methods in CodeMirrorTextEditor

        * inspector/front-end/CodeMirrorTextEditor.js:
        (WebInspector.CodeMirrorTextEditor.prototype.isClean):
        (WebInspector.CodeMirrorTextEditor.prototype.markClean):
        * inspector/front-end/DefaultTextEditor.js:
        (WebInspector.DefaultTextEditor.prototype.isClean):
        (WebInspector.DefaultTextEditor.prototype.markClean):
        * inspector/front-end/TextEditor.js:
        (WebInspector.TextEditor.prototype.isClean):
        (WebInspector.TextEditor.prototype.markClean):
        * inspector/front-end/TextEditorModel.js:
        (WebInspector.TextEditorModel.endsWithBracketRegex.):

1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919
2013-03-27  Ilya Tikhonovsky  <loislo@chromium.org>

        Unreviewed. Web Inspector. rename method Timeline.Calculator.grandMinimumBoundary to Timeline.Calculator.zeroTime

        No changes in behaviour.

        * inspector/front-end/FlameChart.js:
        (WebInspector.FlameChart.Calculator.prototype.zeroTime):
        (WebInspector.FlameChart.OverviewCalculator.prototype.zeroTime):
        * inspector/front-end/NetworkPanel.js:
        (WebInspector.NetworkBaseCalculator.prototype.zeroTime):
        * inspector/front-end/TimelineGrid.js:
        (WebInspector.TimelineGrid.prototype.updateDividers):
        (WebInspector.TimelineGrid.Calculator.prototype.zeroTime):
        * inspector/front-end/TimelineOverviewPane.js:
        (WebInspector.TimelineOverviewCalculator.prototype.zeroTime):
        * inspector/front-end/TimelinePanel.js:
        (WebInspector.TimelineCalculator.prototype.zeroTime):

1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940
2013-03-26  Ilya Tikhonovsky  <loislo@chromium.org>

        Web Inspector: Timeline. Scroll dividers with the underlying events.
        https://bugs.webkit.org/show_bug.cgi?id=113315

        Reviewed by Pavel Feldman.

        Now when TimelineGrid is able to draw dividers with any offset
        we could cut away paddingLeft member of Timeline.Calculator
        and clear the code of TimelineGrid.

        * inspector/front-end/TimelineGrid.js:
        (WebInspector.TimelineGrid.prototype.updateDividers):
        * inspector/front-end/TimelinePanel.js:
        (WebInspector.TimelinePanel.prototype._refresh):
        (WebInspector.TimelineCalculator.prototype.computePosition):
        (WebInspector.TimelineCalculator.prototype.setDisplayWindow):
        (WebInspector.TimelineCalculator.prototype.grandMinimumBoundary):
        * inspector/front-end/inspectorCommon.css:
        (.resources-dividers-label-bar):

1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974
2013-03-27  Kondapally Kalyan  <kalyan.kondapally@intel.com>

        [CoordGfx] Support to share GraphicsSurface flags with client.
        https://bugs.webkit.org/show_bug.cgi?id=112982

        Reviewed by Noam Rosenthal.

        Covered by existing WebGL tests.

        This patch adds support to pass GraphicsSurface flags during it's client creation.
        This would be helpful to determine cases when blending can be disabled on client
        side i.e When AlphaSupport is disabled during Graphics Surface creation.
        With GLX, we rely on Window to provide us with necessary information on client side.
        This might not be the case on other platforms or when not using Window on X.
        This patch doesn't change original behaviour of creating GraphicsSurface client
        with default flags GraphicsSurface::SupportsTextureTarget and GraphicsSurface::SupportsSharing.

        * platform/graphics/texmap/TextureMapperPlatformLayer.h:
        (WebCore::TextureMapperPlatformLayer::graphicsSurfaceFlags):
        * platform/graphics/texmap/coordinated/CoordinatedGraphicsLayer.cpp:
        (WebCore::CoordinatedGraphicsLayer::createCanvasIfNeeded):
        * platform/graphics/texmap/coordinated/CoordinatedGraphicsScene.cpp:
        (WebCore::CoordinatedGraphicsScene::createCanvasIfNeeded):
        * platform/graphics/texmap/coordinated/CoordinatedGraphicsState.h:
        (CoordinatedGraphicsLayerState):
        * platform/graphics/efl/GraphicsContext3DPrivate.cpp:
        (WebCore):
        (WebCore::GraphicsContext3DPrivate::graphicsSurfaceFlags):
        * platform/graphics/efl/GraphicsContext3DPrivate.h:
        (GraphicsContext3DPrivate):
        * platform/graphics/surfaces/efl/GraphicsSurfaceCommon.cpp:
        (WebCore::GraphicsSurfacePrivate::GraphicsSurfacePrivate):
        (WebCore::GraphicsSurfacePrivate::initializeClient):

1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992
2013-03-26  Takashi Sakamoto  <tasak@google.com>

        [shadow] styleForText should consider the case where parent node has no style
        https://bugs.webkit.org/show_bug.cgi?id=113275

        If a text node is distributed, its parent node for rendering and
        styling might have no style. In the case, styleForText should return
        default style.

        Reviewed by Hajime Morrita.

        Test: fast/dom/shadow/text-node-distributed-crash.html

        * css/StyleResolver.cpp:
        (WebCore::StyleResolver::styleForText):
        Check whether a parent node has any style or not. If not, return
        default style. This is the same behavior as styleForElement.

1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012
2013-03-26  Takeshi Yoshino  <tyoshino@chromium.org>

        Make SocketStreamHandle (Chromium port) fully use IPC window in send()
        https://bugs.webkit.org/show_bug.cgi?id=113304

        Reviewed by Kent Tamura.

        socket_stream of Chromium buffers send data up to 32KiB (exact) bytes.

        However, SocketStreamHandleInternal::send() method now keeps in-flight
        send data not greater than m_maxPendingSendAllowed - 1 that is
        32KiB - 1. This means that SocketStreamHandleInternal consumes the
        buffered data in SocketStreamHandleBase by 32KiB - 1. It makes memory
        copy operations unaligned unnecessarily. It should just use the
        allowed size fully.

        * platform/network/chromium/SocketStreamHandle.cpp:
        (WebCore::SocketStreamHandleInternal::send):
        (WebCore):

2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091
2013-03-26  Hayato Ito  <hayato@chromium.org>

        Allow ShadowContents in HitTests by default.
        https://bugs.webkit.org/show_bug.cgi?id=113171

        Reviewed by Dimitri Glazkov.

        HitTestRequest is widely used in WebCore, but AllowShadowContents
        flag is not turned on by default.  In most places, we can set the
        flag on.

        This change makes HitTests allow shadow contents by default.

        To track all existing HitTests which do not allow shadow contents,
        and discourage such a HitTest in the future, I've introduced
        disallowShadowContenet flag so that callers must turn on this flag
        explicitly if they want to disallow shadow contents in their HitTests.

        This change should be refactoring and should not include any
        behavior changes.  After this change, we'll investigate each place
        where disallowShadowContents is used step by step and get rid of
        the flag if it is okay to remove.

        No new tests, no behavior change.

        * dom/Document.h:
        (Document):
        * dom/TreeScope.cpp:
        (WebCore::nodeFromPoint):
        * editing/FrameSelection.cpp:
        (WebCore::FrameSelection::contains):
        * page/DragController.cpp:
        (WebCore::elementUnderMouse):
        (WebCore::DragController::canProcessDrag):
        (WebCore::DragController::startDrag):
        * page/EventHandler.cpp:
        (WebCore::EventHandler::handleMouseDraggedEvent):
        (WebCore::EventHandler::eventMayStartDrag):
        (WebCore::EventHandler::updateSelectionForMouseDrag):
        (WebCore::EventHandler::hitTestResultAtPoint):
        (WebCore::EventHandler::handleMousePressEvent):
        (WebCore::EventHandler::handleMouseDoubleClickEvent):
        (WebCore::EventHandler::handleMouseMoveEvent):
        (WebCore::EventHandler::handleMouseReleaseEvent):
        (WebCore::EventHandler::updateDragAndDrop):
        (WebCore::EventHandler::isInsideScrollbar):
        (WebCore::EventHandler::handleWheelEvent):
        (WebCore::EventHandler::handleGestureEvent):
        (WebCore::EventHandler::handleGestureLongPress):
        (WebCore::EventHandler::handleGestureScrollBegin):
        (WebCore::EventHandler::bestClickableNodeForTouchPoint):
        (WebCore::EventHandler::bestContextMenuNodeForTouchPoint):
        (WebCore::EventHandler::bestZoomableAreaForTouchPoint):
        (WebCore::EventHandler::sendContextMenuEvent):
        (WebCore::EventHandler::sendContextMenuEventForKey):
        (WebCore::EventHandler::hoverTimerFired):
        (WebCore::EventHandler::dragSourceEndedAt):
        (WebCore::EventHandler::handleDrag):
        (WebCore::EventHandler::handleTouchEvent):
        (WebCore::EventHandler::dispatchSyntheticTouchEventIfEnabled):
        * page/EventHandler.h:
        (EventHandler):
        * page/FocusController.cpp:
        (WebCore::updateFocusCandidateIfNeeded):
        * page/Frame.cpp:
        (WebCore::Frame::visiblePositionForPoint):
        * page/TouchDisambiguation.cpp:
        (WebCore::findGoodTouchTargets):
        * rendering/HitTestRequest.h:
        (WebCore::HitTestRequest::disallowsShadowContent):
        * rendering/HitTestResult.cpp:
        (WebCore::HitTestResult::addNodeToRectBasedTestResult):
        * rendering/RenderFlowThread.cpp:
        (WebCore::RenderFlowThread::hitTestFlowThreadPortionInRegion):
        * rendering/svg/RenderSVGResourceClipper.cpp:
        (WebCore::RenderSVGResourceClipper::hitTestClipContent):
        * testing/Internals.cpp:
        (WebCore::Internals::nodesFromRect):

2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104
2013-03-26  Tim Horton  <timothy_horton@apple.com>

        [ca] Tell CA to clean up unused resources if a given WebProcess won't be drawing
        https://bugs.webkit.org/show_bug.cgi?id=107539
        <rdar://problem/13032692>

        Reviewed by Simon Fraser.

        Update WebCoreSystemInterface.

        * platform/mac/WebCoreSystemInterface.h:
        * platform/mac/WebCoreSystemInterface.mm:

2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146
2013-03-26  Antti Koivisto  <antti@apple.com>

        Test if non-immediate descendants obscure background
        https://bugs.webkit.org/show_bug.cgi?id=113137

        Reviewed by Simon Fraser.

        The current obscuration test only covers immediate children. We can find more cases by looking deeper into descendants.
        
        The patch makes the test sufficiently smart to stop a heavy fully obscured gif animation on micrsoft.com.

        * loader/cache/CachedImage.cpp:
        (WebCore::CachedImage::animationAdvanced):
        * rendering/RenderBox.cpp:
        (WebCore::RenderBox::styleDidChange):
        
            Invalidate parents to max test depth.

        (WebCore::RenderBox::backgroundPaintedExtent):
        
            Background painting is pixel snapped.

        (WebCore::isCandidateForOpaquenessTest):
        (WebCore::RenderBox::foregroundIsKnownToBeOpaqueInRect):
        
            Separate foreground testing and make it recursive.
            Add fast bailout for common static positioned case.
            Remove maximum child count, the fast bailouts should prevent long tests.
            Add maximum depth so we know how deep we need to invalidate in styleDidChange.

        (WebCore::RenderBox::computeBackgroundIsKnownToBeObscured):
        (WebCore):
        * rendering/RenderBox.h:
        (RenderBox):
        * rendering/RenderImage.cpp:
        (WebCore::RenderImage::foregroundIsKnownToBeOpaqueInRect):
        (WebCore):
        (WebCore::RenderImage::computeBackgroundIsKnownToBeObscured):
        
        * rendering/RenderImage.h:
        (RenderImage):

2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167
2013-03-26  Benjamin Poulain  <bpoulain@apple.com>

        Regression (r145601): out-of-bounds read in line breaking / new width cache
        https://bugs.webkit.org/show_bug.cgi?id=113347

        Reviewed by Geoffrey Garen.

        The values zero and 0xffff have special values with the default HashTraits. Those values
        are also valid values for UChar.

        To avoid any table inconsitency, switch from UChar to uint32_t as the key type for
        the WidthCache's single char map. The traits is also changed to allow zero as a normal
        value.

        This makes no space or time change over the previous code because:
        -The struct KeyValuePair was already 64bits due to the ABI alignment restrictions on floats.
        -The two hashes take the same number of instructions.

        * platform/graphics/WidthCache.h:
        (WidthCache):

2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186
2013-03-26  Kent Tamura  <tkent@chromium.org>

        Make HTMLProgressElement::isDeterminate private
        https://bugs.webkit.org/show_bug.cgi?id=113299

        Reviewed by Kentaro Hara.

        The only callsite of isDeterminate outside of HTMLProgressElement
        is in StyleResolver::sharingCandidateHasIdenticalStyleAffectingAttributes,
        and we can replace it with Element::shouldAppearIndeterminate.

        No new tests. Just a refactoring.

        * css/StyleResolver.cpp:
        (WebCore::StyleResolver::sharingCandidateHasIdenticalStyleAffectingAttributes):
        Use Element::shouldAppearIndeterminate.
        * html/HTMLProgressElement.h:
        (HTMLProgressElement): Make isDeterminate private.

2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204
2013-03-26  David Grogan  <dgrogan@chromium.org>

        IndexedDB: Histogram cause of LevelDB write errors
        https://bugs.webkit.org/show_bug.cgi?id=113350

        Reviewed by Tony Chang.

        Add histogram for source of LevelDB errors on Write in addition to
        Open.

        No new tests - no good way to test histogram code.

        * platform/leveldb/LevelDBDatabase.cpp:
        (WebCore::histogramLevelDBError):
        (WebCore):
        (WebCore::LevelDBDatabase::open):
        (WebCore::LevelDBDatabase::write):

2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218
2013-03-26  Chris Fleizach  <cfleizach@apple.com>

        WebKit does not expose @required or @aria-required as AXRequired on select elements
        https://bugs.webkit.org/show_bug.cgi?id=113339

        Reviewed by Tim Horton.

        Make sure button types can return the AXRequired attribute.

        Tests: platform/mac/accessibility/aria-required-popup-button.html

        * accessibility/mac/WebAccessibilityObjectWrapperMac.mm:
        (-[WebAccessibilityObjectWrapper accessibilityAttributeNames]):

2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246
2013-03-26  Dean Jackson  <dino@apple.com>

        When a primary plugin is restarted, also start similar plugins
        https://bugs.webkit.org/show_bug.cgi?id=113265

        Reviewed by Tim Horton.

        If we detect a primary plugin that is snapshotted, we immediately restart it.
        When this happens, we should also restart any other plugins that
        match the same origin and type. This allows sites with a lot of
        (geometrically) nearby plugins to behave as if they are a single big plugin.

        Tests: plugins/snapshotting/autoplay-similar-to-dominant-after-delay.html
               plugins/snapshotting/autoplay-similar-to-dominant.html

        * WebCore.exp.in: Export mimeTypeFromURL.
        * html/HTMLPlugInImageElement.cpp:
        (WebCore::addPlugInsFromNodeListMatchingPlugInOrigin): Use loadedMimeType helper.
        (WebCore::HTMLPlugInImageElement::restartSimilarPlugIns): New method, which copied the
            existing code from userDidClickSnapshot.
        (WebCore::HTMLPlugInImageElement::userDidClickSnapshot): Move the similar plugin detection
            out into another function and call it.
        (WebCore::HTMLPlugInImageElement::setIsPrimarySnapshottedPlugIn): Call restartSimilarPlugIns.
        (WebCore::HTMLPlugInImageElement::subframeLoaderWillCreatePlugIn): Use loadedMimeType helper.
        * html/HTMLPlugInImageElement.h: Declaration of restartSimilarPlugIns.
        (WebCore::HTMLPlugInImageElement::loadedMimeType): New helper method since this
            code was being often duplicated.

2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261
2013-03-26  Brent Fulgham  <bfulgham@webkit.org>

        [Windows, WinCairo] Scroll offset being applied to plugins during print operations.
        https://bugs.webkit.org/show_bug.cgi?id=39889

        Reviewed by Anders Carlsson.

        This must be tested manually. See the issue for details.

        * plugins/win/PluginViewWin.cpp:
        (WebCore::PluginView::paintWindowedPluginIntoContext):
        Revise the Windows implementation of the PluginView class
        paintWindowedPluginIntoContext to use the containing window
        position when computing the plugin's position for printing.

2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276
2013-03-26  Xianzhu Wang  <wangxianzhu@chromium.org>

        Non-paintsContent fixed position layer should not cause slow scrolling
        https://bugs.webkit.org/show_bug.cgi?id=113238

        Reviewed by James Robinson.

        Added NotCompositedForNoVisibleContent in ViewportConstrainedNotCompositedReason and set it in RLC.

        Test: compositing/layer-creation/fixed-position-no-content-scroll-reason.html

        * rendering/RenderLayer.h: Add NotCompositedForNoVisibleContent.
        * rendering/RenderLayerCompositor.cpp:
        (WebCore::RenderLayerCompositor::requiresCompositingForPosition): Set NotCompositedForNoVisibleContent reason when the fixed position layer has no visible content.

2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292
2013-03-26  Zoltan Horvath  <zoltan@webkit.org>

        [CSS Exclusions] The radius of a circle should be computed based on the shorter available dimension
        https://bugs.webkit.org/show_bug.cgi?id=113255

        Reviewed by Julien Chaffraix.

        When we decide what should be the radius of a circle, we should choose the smallest available space. For instance when the
        width or height is not resolvable for the circle we should not have a radius for it. This change modifies the behavior to
        use the smaller available space, so we won't render unnecessary circle shapes.

        Test: fast/exclusions/shape-inside/shape-inside-on-nested-container-with-unresolved-height.html

        * rendering/ExclusionShape.cpp:
        (WebCore::ExclusionShape::createExclusionShape):

2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305
2013-03-26  Timothy Hatcher  <timothy@apple.com>

        Make the Web Inspector console work in strict mode with JavaScriptCore.

        https://webkit.org/b/65829
        rdar://problem/11271238

        Reviewed by Joseph Pecoraro.

        * inspector/InjectedScriptSource.js:
        (InjectedScript.prototype._evaluateOn): Don't use 'eval' parameter (it isn't
        allowed in strict mode). Swap window.eval with our known eval instead.

2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323
2013-03-26  Ryosuke Niwa  <rniwa@webkit.org>

        Heap-use-after-free regression
        https://bugs.webkit.org/show_bug.cgi?id=113337

        Reviewed by Abhishek Arya and Alexey Proskuryakov.

        Use RefPtr instead of raw pointer in m_associatedFormControls.

        * dom/Document.cpp:
        (WebCore::Document::didAssociateFormControlsTimerFired):
        * dom/Document.h:
        (Document):
        * loader/EmptyClients.h:
        (WebCore::EmptyChromeClient::didAssociateFormControls):
        * page/ChromeClient.h:
        (WebCore::ChromeClient::didAssociateFormControls):

2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411
2013-03-26  Alexey Proskuryakov  <ap@apple.com>

        <rdar://problem/13194263> Crashes in NetworkProcess due to threading issues
        https://bugs.webkit.org/show_bug.cgi?id=113256

        Reviewed by Brady Eidson.

        Added a new code path in ResourceHandle/ResourceHandleClient that doesn't need
        blocking calls. Implemented it for NSURLConnection by changing NSOperationQueue
        version to forward calls to main thread.

        * WebCore.exp.in: Export new methods.
        * WebCore.xcodeproj/project.pbxproj: Added WebCoreResourceHandleAsOperationQueueDelegate.

        * platform/network/CredentialStorage.cpp: Assert that unprotected global map operations
        happen on main thread.

        * platform/network/ResourceHandle.cpp: Added default implementations of functions
        that handle async responses.

        * platform/network/chromium/ResourceHandle.cpp: Ditto.

        * platform/network/ResourceHandle.h: Added functions that are called in response
        to new async functions in ResourceHandleClient. Changed Mac delegate type to id,
        ast can now be either WebCoreResourceHandleAsDelegate or WebCoreResourceHandleAsOperationQueueDelegate.

        * platform/network/ResourceHandleClient.cpp:
        (WebCore::ResourceHandleClient::willSendRequestAsync):
        (WebCore::ResourceHandleClient::shouldUseCredentialStorageAsync):
        (WebCore::ResourceHandleClient::canAuthenticateAgainstProtectionSpaceAsync):
        (WebCore::ResourceHandleClient::willCacheResponseAsync):
        Default implementations of async client functions. These match default behavior of
        sync versions.

        * platform/network/ResourceHandleClient.h: Added async functions. A ResourceHandle
        should use these when the client returns true from usesAsyncCallbacks().

        * platform/network/ResourceHandleInternal.h: Changed to use id for delegate type
        here, too.

        * platform/network/mac/ResourceHandleMac.mm:
        (WebCore::ResourceHandle::delegate): Create an appropriate delegate for the client.
        (WebCore::ResourceHandle::willSendRequest): Since this function has a lot of common
        behavior in sync and async cases, implement the new code path as a branch inside
        it, not as a new function.
        (WebCore::ResourceHandle::continueWillSendRequest): Unblock the connection when
        response is known.
        (WebCore::ResourceHandle::shouldUseCredentialStorage): Branched here too, for consistency.
        Perhaps we'll want to break this into separate functions though.
        (WebCore::ResourceHandle::continueShouldUseCredentialStorage): Unblock the connection.
        (WebCore::ResourceHandle::canAuthenticateAgainstProtectionSpace): Same change as above.
        (WebCore::ResourceHandle::continueCanAuthenticateAgainstProtectionSpace): Ditto.
        (WebCore::ResourceHandle::continueWillCacheResponse): Ditto. Currently, delegate
        calls the client directly, so we only have a "continue" function, and no "willCacheResponse".

        * platform/network/mac/WebCoreResourceHandleAsDelegate.mm:
        (-[WebCoreResourceHandleAsDelegate connection:willCacheResponse:]): Removed some
        nonsense code.

        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.h: Copied from Source/WebCore/platform/network/mac/WebCoreResourceHandleAsDelegate.h.
        This delegate is responsible for forwarding calls to main thread. Unfortunately,
        this adds some code duplication, which I tried to rectify somewhat in previous patches
        by moving more logic to ResourceHandle.

        * platform/network/mac/WebCoreResourceHandleAsOperationQueueDelegate.mm: Copied from Source/WebCore/platform/network/mac/WebCoreResourceHandleAsDelegate.mm.
        (-[WebCoreResourceHandleAsOperationQueueDelegate detachHandle]): Unblock waiting
        threads if we don't expect a response any more.
        (-[WebCoreResourceHandleAsOperationQueueDelegate dealloc]): Release the semaphore.
        (-[WebCoreResourceHandleAsOperationQueueDelegate continueWillSendRequest:]): Unblock
        a waiting thread with a response.
        (-[WebCoreResourceHandleAsOperationQueueDelegate continueShouldUseCredentialStorage:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate continueCanAuthenticateAgainstProtectionSpace:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate continueWillCacheResponse:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:willSendRequest:redirectResponse:]):
        Run code that uses WebCore objects on main thread.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connectionShouldUseCredentialStorage:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveAuthenticationChallenge:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didCancelAuthenticationChallenge:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:canAuthenticateAgainstProtectionSpace:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveResponse:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveDataArray:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didReceiveData:lengthReceived:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:willStopBufferingData:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didSendBodyData:totalBytesWritten:totalBytesExpectedToWrite:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connectionDidFinishLoading:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:didFailWithError:]): Ditto.
        (-[WebCoreResourceHandleAsOperationQueueDelegate connection:willCacheResponse:]): Ditto.

2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436
2013-03-26  Tony Chang  <tony@chromium.org>

        Autogenerate the scrollAnimatorEnabled setting in Settings.in
        https://bugs.webkit.org/show_bug.cgi?id=113253

        Reviewed by James Robinson.

        Convert scrollAnimatorEnabled into an autogenerated setting. This involves renaming
        the setter from setEnableScrollAnimator(bool) to setScrollAnimatorEnabled(bool) and
        updating the callers. I didn't change any WebKit API methods.

        Also remove the code in InternalSettings since it's never used and will now be
        autogenerated with proper resetting code.

        No new tests, this is a refactor and should compile.

        * page/Settings.cpp:
        (WebCore::Settings::Settings): Remove code that is now autogenerated.
        * page/Settings.h:
        (Settings): Remove code that is now autogenerated.
        * page/Settings.in: Add entry for scrollAnimatorEnabled.
        * testing/InternalSettings.cpp: Remove unused code.
        * testing/InternalSettings.h: Remove unused code.
        * testing/InternalSettings.idl: Remove unused code.

2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455
2013-03-26  Joe Mason  <jmason@blackberry.com>

        [BlackBerry] In RSSFilterStream, don't swallow headers when there's no body
        https://bugs.webkit.org/show_bug.cgi?id=113334

        Reviewed by Rob Buis.

        RIM PR 316345

        When receiving an HTTP response that has a Content-Type header such as text/xml, but no
        body, RSSFilterStream::notifyHeadersReceived reads the Content-Type as "potential RSS", and
        calls saveHeaders. It expects to sniff the body in notifyDataReceived to see if it's RSS,
        and then call sendSavedHeaders to pass on the headers. But since there is no body,
        notifyDataReceived is never called. So call sendSavedHeaders in notifyClose too (it will not
        send them again if they were already sent.)

        * platform/network/blackberry/rss/RSSFilterStream.cpp:
        (WebCore::RSSFilterStream::notifyClose):

2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470
2013-03-26  Dmitry Zvorygin  <zvorygin@chromium.org>

        Web Inspector: Faster drawer animation.
        https://bugs.webkit.org/show_bug.cgi?id=113330

        250ms -> 100ms

        Reviewed by Pavel Feldman.

        * inspector/front-end/inspector.css:
        (.animate #main):
        (.animate #floating-status-bar-container):
        (.animate #drawer):
        (.animate #bottom-status-bar-container > *):

2471 2472 2473 2474 2475 2476 2477 2478
2013-03-26  Brent Fulgham  <bfulgham@webkit.org>

        [WinCairo] Unreviewed Build fix.

        * platform/graphics/win/FontCustomPlatformDataCairo.h:
        (FontCustomPlatformData): Correct signature in header to match
        required implementation.

2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497
2013-03-26  Arvid Nilsson  <anilsson@rim.com>

        [BlackBerry] Scrolling up and down can cause the screen to flash black
        https://bugs.webkit.org/show_bug.cgi?id=113269

        Reviewed by Rob Buis.

        PR 296106

        The LayerRenderer should never clear before drawing the layers, from
        now on that's the responsibility of the caller.

        Only manually testable.

        * platform/graphics/blackberry/LayerRenderer.cpp:
        (WebCore::LayerRenderer::setViewport):
        * platform/graphics/blackberry/LayerRendererClient.h:
        (LayerRendererClient):

2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518
2013-03-26  Allan Sandfeld Jensen  <allan.jensen@digia.com>

        [Qt] editing/pasteboard/can-read-in-dragstart-event.html and /can-read-in-copy-and-cut-events.html are crashing
        https://bugs.webkit.org/show_bug.cgi?id=113126

        Reviewed by Jocelyn Turcotte.

        Make it possible to read from a writable Clipboard.

        Test: editing/pasteboard/can-read-in-copy-and-cut-events.html

        * platform/qt/ClipboardQt.cpp:
        (WebCore::ClipboardQt::getData):
        (WebCore::ClipboardQt::types):
        (WebCore::ClipboardQt::files):
        (WebCore::ClipboardQt::readClipboardData):
        (WebCore::ClipboardQt::hasData):
        (WebCore::ClipboardQt::items):
        * platform/qt/ClipboardQt.h:
        (ClipboardQt):