[webkit-changes] [251898] trunk/Tools
Title: [251898] trunk/Tools Revision 251898 Author mattba...@apple.com Date 2019-10-31 17:39:05 -0700 (Thu, 31 Oct 2019) Log Message Changed my emails list. * Scripts/webkitpy/common/config/contributors.json: Modified Paths trunk/Tools/ChangeLog trunk/Tools/Scripts/webkitpy/common/config/contributors.json Diff Modified: trunk/Tools/ChangeLog (251897 => 251898) --- trunk/Tools/ChangeLog 2019-11-01 00:31:57 UTC (rev 251897) +++ trunk/Tools/ChangeLog 2019-11-01 00:39:05 UTC (rev 251898) @@ -1,3 +1,9 @@ +2019-10-31 Matt Baker + +Changed my emails list. + +* Scripts/webkitpy/common/config/contributors.json: + 2019-10-31 Tim Horton Turn on IOSurface support in the iOS Simulator Modified: trunk/Tools/Scripts/webkitpy/common/config/contributors.json (251897 => 251898) --- trunk/Tools/Scripts/webkitpy/common/config/contributors.json 2019-11-01 00:31:57 UTC (rev 251897) +++ trunk/Tools/Scripts/webkitpy/common/config/contributors.json 2019-11-01 00:39:05 UTC (rev 251898) @@ -3783,7 +3783,7 @@ }, "Matt Baker" : { "emails" : [ - "mattba...@apple.com" + "mattbake...@gmail.com" ], "expertise" : "Web Inspector", "nicks" : [ ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [247169] trunk/Source/WebInspectorUI
Title: [247169] trunk/Source/WebInspectorUI Revision 247169 Author mattba...@apple.com Date 2019-07-05 13:06:47 -0700 (Fri, 05 Jul 2019) Log Message Web Inspector: Elements: use a CSS transition when showing/hiding DOM breakpoint gutter https://bugs.webkit.org/show_bug.cgi?id=199411 Reviewed by Devin Rousso. * UserInterface/Views/DOMTreeContentView.css: (.content-view.dom-tree .tree-outline.dom): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeContentView.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (247168 => 247169) --- trunk/Source/WebInspectorUI/ChangeLog 2019-07-05 19:19:28 UTC (rev 247168) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-07-05 20:06:47 UTC (rev 247169) @@ -1,3 +1,13 @@ +2019-07-05 Matt Baker + +Web Inspector: Elements: use a CSS transition when showing/hiding DOM breakpoint gutter +https://bugs.webkit.org/show_bug.cgi?id=199411 + +Reviewed by Devin Rousso. + +* UserInterface/Views/DOMTreeContentView.css: +(.content-view.dom-tree .tree-outline.dom): + 2019-07-02 Devin Rousso Web Inspector: Elements: allow nodes to be copied and pasted Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeContentView.css (247168 => 247169) --- trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeContentView.css 2019-07-05 19:19:28 UTC (rev 247168) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeContentView.css 2019-07-05 20:06:47 UTC (rev 247169) @@ -29,6 +29,7 @@ .content-view.dom-tree .tree-outline.dom { -webkit-padding-start: 7px; +transition: padding 200ms ease-in-out; } .content-view.dom-tree.show-gutter .tree-outline.dom { ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [247052] trunk/Source/WebInspectorUI
Title: [247052] trunk/Source/WebInspectorUI Revision 247052 Author mattba...@apple.com Date 2019-07-02 09:14:19 -0700 (Tue, 02 Jul 2019) Log Message REGRESSION (r238563): Web Inspector: Selection is erratic when holding Up/Down on Network Table https://bugs.webkit.org/show_bug.cgi?id=193841 Reviewed by Devin Rousso. Selecting and revealing a row after reloading Table data, but before the layout that populates visible rows, could cause the Table to always be scrolled so that the revealed row is first. This patch fixes `revealRow` by calculating the position of the row being revealed in the absence of its DOM element, so that the Table is only scrolled when necessary. * UserInterface/Views/Table.js: (WI.Table.prototype.revealRow): (WI.Table.prototype._resizeColumnsAndFiller): Drive-by fix: use realOffsetWidth for consistency. (WI.Table.prototype._updateVisibleRows): (WI.Table.prototype._calculateOffsetHeight): (WI.Table.prototype._calculateScrollTop): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (247051 => 247052) --- trunk/Source/WebInspectorUI/ChangeLog 2019-07-02 16:00:05 UTC (rev 247051) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-07-02 16:14:19 UTC (rev 247052) @@ -1,3 +1,27 @@ +2019-07-02 Matt Baker + +REGRESSION (r238563): Web Inspector: Selection is erratic when holding Up/Down on Network Table +https://bugs.webkit.org/show_bug.cgi?id=193841 + + +Reviewed by Devin Rousso. + +Selecting and revealing a row after reloading Table data, but before the +layout that populates visible rows, could cause the Table to always be +scrolled so that the revealed row is first. + +This patch fixes `revealRow` by calculating the position of the row being +revealed in the absence of its DOM element, so that the Table is only +scrolled when necessary. + +* UserInterface/Views/Table.js: +(WI.Table.prototype.revealRow): +(WI.Table.prototype._resizeColumnsAndFiller): +Drive-by fix: use realOffsetWidth for consistency. +(WI.Table.prototype._updateVisibleRows): +(WI.Table.prototype._calculateOffsetHeight): +(WI.Table.prototype._calculateScrollTop): + 2019-07-02 Devin Rousso Web Inspector: Debug: "Reset Web Inspector" should also clear the saved window size and attachment side Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (247051 => 247052) --- trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2019-07-02 16:00:05 UTC (rev 247051) +++ trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2019-07-02 16:14:19 UTC (rev 247052) @@ -365,18 +365,28 @@ if (rowIndex < 0 || rowIndex >= this.numberOfRows) return; -// Force our own scroll update because we may have scrolled. -this._cachedScrollTop = NaN; - if (this._isRowVisible(rowIndex)) { let row = this._cachedRows.get(rowIndex); console.assert(row, "Visible rows should always be in the cache."); -if (row) +if (row) { row.scrollIntoViewIfNeeded(false); -this.needsLayout(); +this._cachedScrollTop = NaN; +this.needsLayout(); +} } else { -this._scrollContainerElement.scrollTop = rowIndex * this._rowHeight; -this.updateLayout(); +let rowPosition = rowIndex * this._rowHeight; +let scrollableOffsetHeight = this._calculateOffsetHeight(); +let scrollTop = this._calculateScrollTop(); +let newScrollTop = NaN; +if (rowPosition + this._rowHeight < scrollTop) +newScrollTop = rowPosition; +else if (rowPosition > scrollTop + scrollableOffsetHeight) +newScrollTop = scrollTop + scrollableOffsetHeight - this._rowHeight; + +if (!isNaN(newScrollTop)) { +this._scrollContainerElement.scrollTop = newScrollTop; +this.updateLayout(); +} } } @@ -855,7 +865,7 @@ _resizeColumnsAndFiller() { if (isNaN(this._cachedWidth) || !this._cachedWidth) -this._cachedWidth = Math.floor(this._scrollContainerElement.getBoundingClientRect().width); +this._cachedWidth = this._scrollContainerElement.realOffsetWidth; // Not visible yet. if (!this._cachedWidth) @@ -1064,15 +1074,9 @@ let updateOffsetThreshold = rowHeight * 10; let overflowPadding = updateOffsetThreshold * 3; -if (isNaN(this._cachedScrollTop)) -this._cachedScrollTop = this._scrollContainerElement.scrollTop; +let scrollTop = this._calculateScrollTop(); +let scrollableOffsetHeight = this._calculateOffsetHeight(); -if (isNaN(this._cachedHeight
[webkit-changes] [246821] trunk/Source/WebInspectorUI
Title: [246821] trunk/Source/WebInspectorUI Revision 246821 Author mattba...@apple.com Date 2019-06-25 16:45:37 -0700 (Tue, 25 Jun 2019) Log Message Web Inspector: Elements: show shadow DOM by default https://bugs.webkit.org/show_bug.cgi?id=199128 Reviewed by Devin Rousso. * UserInterface/Base/Setting.js: * UserInterface/Test/Test.js: (WI.loaded): Overriding the default value isn't necessary since the default is now true. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/Setting.js trunk/Source/WebInspectorUI/UserInterface/Test/Test.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246820 => 246821) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-25 23:44:09 UTC (rev 246820) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-25 23:45:37 UTC (rev 246821) @@ -1,3 +1,16 @@ +2019-06-25 Matt Baker + +Web Inspector: Elements: show shadow DOM by default +https://bugs.webkit.org/show_bug.cgi?id=199128 + +Reviewed by Devin Rousso. + +* UserInterface/Base/Setting.js: + +* UserInterface/Test/Test.js: +(WI.loaded): +Overriding the default value isn't necessary since the default is now true. + 2019-06-25 Nikita Vasilyev REGRESSION(r246621): Web Inspector: Styles: property may get removed when editing after deleting value Modified: trunk/Source/WebInspectorUI/UserInterface/Base/Setting.js (246820 => 246821) --- trunk/Source/WebInspectorUI/UserInterface/Base/Setting.js 2019-06-25 23:44:09 UTC (rev 246820) +++ trunk/Source/WebInspectorUI/UserInterface/Base/Setting.js 2019-06-25 23:45:37 UTC (rev 246821) @@ -168,7 +168,7 @@ showRulers: new WI.Setting("show-rulers", false), showRulersDuringElementSelection: new WI.Setting("show-rulers-during-element-selection", true), showScopeChainOnPause: new WI.Setting("show-scope-chain-sidebar", true), -showShadowDOM: new WI.Setting("show-shadow-dom", false), +showShadowDOM: new WI.Setting("show-shadow-dom", true), showWhitespaceCharacters: new WI.Setting("show-whitespace-characters", false), tabSize: new WI.Setting("tab-size", 4), timelinesAutoStop: new WI.Setting("timelines-auto-stop", true), Modified: trunk/Source/WebInspectorUI/UserInterface/Test/Test.js (246820 => 246821) --- trunk/Source/WebInspectorUI/UserInterface/Test/Test.js 2019-06-25 23:44:09 UTC (rev 246820) +++ trunk/Source/WebInspectorUI/UserInterface/Test/Test.js 2019-06-25 23:45:37 UTC (rev 246821) @@ -69,9 +69,6 @@ // Register for events. document.addEventListener("DOMContentLoaded", WI.contentLoaded); -// Non-default global setting values for tests. -WI.settings.showShadowDOM.value = true; - // Targets. WI.backendTarget = null; WI.pageTarget = null; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [246724] trunk/Source/WebInspectorUI
Title: [246724] trunk/Source/WebInspectorUI Revision 246724 Author mattba...@apple.com Date 2019-06-23 15:36:27 -0700 (Sun, 23 Jun 2019) Log Message Web Inspector: REGRESSION (r246684): Dark Mode: dashboard buttons should have no background https://bugs.webkit.org/show_bug.cgi?id=199136 Reviewed by Joseph Pecoraro. * UserInterface/Views/DefaultDashboardView.css: (@media (prefers-color-scheme: dark)): (.toolbar .dashboard .item.button,): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DefaultDashboardView.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246723 => 246724) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-23 19:34:44 UTC (rev 246723) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-23 22:36:27 UTC (rev 246724) @@ -1,3 +1,15 @@ +2019-06-23 Matt Baker + +Web Inspector: REGRESSION (r246684): Dark Mode: dashboard buttons should have no background +https://bugs.webkit.org/show_bug.cgi?id=199136 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/DefaultDashboardView.css: +(@media (prefers-color-scheme: dark)): +(.toolbar .dashboard .item.button,): + 2019-06-23 Nikita Vasilyev Web Inspector: Styles: show green highlight for newly added properties only when name and value are present Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DefaultDashboardView.css (246723 => 246724) --- trunk/Source/WebInspectorUI/UserInterface/Views/DefaultDashboardView.css 2019-06-23 19:34:44 UTC (rev 246723) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DefaultDashboardView.css 2019-06-23 22:36:27 UTC (rev 246724) @@ -200,6 +200,11 @@ filter: var(--filter-invert); } +.toolbar .dashboard .item.button, +.toolbar .dashboard .item.button:active { +background: none; +} + .dashboard-container .advance-arrow { filter: var(--filter-invert); } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [246686] trunk/Source/WebInspectorUI
Title: [246686] trunk/Source/WebInspectorUI Revision 246686 Author mattba...@apple.com Date 2019-06-21 11:21:17 -0700 (Fri, 21 Jun 2019) Log Message Web Inspector: remove unused DataGrid style .force-focus https://bugs.webkit.org/show_bug.cgi?id=199112 Reviewed by Timothy Hatcher. * UserInterface/Views/HeapAllocationsTimelineView.css: (.timeline-view.heap-allocations > .data-grid:not(:focus) tr.selected.invalid): (.timeline-view.heap-allocations > .data-grid:not(:focus, .force-focus) tr.selected.invalid): Deleted. * UserInterface/Views/ResourceTreeElement.css: (.item.resource.resource-type-websocket:not(.selected) .status .ready-state.open,): (.item.resource.resource-type-websocket:not(.selected) .status .ready-state.connecting,): Missed in https://bugs.webkit.org/show_bug.cgi?id=190480. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.css trunk/Source/WebInspectorUI/UserInterface/Views/ResourceTreeElement.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246685 => 246686) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-21 18:01:13 UTC (rev 246685) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-21 18:21:17 UTC (rev 246686) @@ -1,5 +1,22 @@ 2019-06-21 Matt Baker +Web Inspector: remove unused DataGrid style .force-focus +https://bugs.webkit.org/show_bug.cgi?id=199112 + + +Reviewed by Timothy Hatcher. + +* UserInterface/Views/HeapAllocationsTimelineView.css: +(.timeline-view.heap-allocations > .data-grid:not(:focus) tr.selected.invalid): +(.timeline-view.heap-allocations > .data-grid:not(:focus, .force-focus) tr.selected.invalid): Deleted. + +* UserInterface/Views/ResourceTreeElement.css: +(.item.resource.resource-type-websocket:not(.selected) .status .ready-state.open,): +(.item.resource.resource-type-websocket:not(.selected) .status .ready-state.connecting,): +Missed in https://bugs.webkit.org/show_bug.cgi?id=190480. + +2019-06-21 Matt Baker + Web Inspector: remove .legacy-mac/.latest-mac CSS classes, standardize on .latest-mac UI https://bugs.webkit.org/show_bug.cgi?id=199109 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.css (246685 => 246686) --- trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.css 2019-06-21 18:01:13 UTC (rev 246685) +++ trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.css 2019-06-21 18:21:17 UTC (rev 246686) @@ -39,7 +39,7 @@ color: gray; } -.timeline-view.heap-allocations > .data-grid:not(:focus, .force-focus) tr.selected.invalid { +.timeline-view.heap-allocations > .data-grid:not(:focus) tr.selected.invalid { color: gray !important; } Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ResourceTreeElement.css (246685 => 246686) --- trunk/Source/WebInspectorUI/UserInterface/Views/ResourceTreeElement.css 2019-06-21 18:01:13 UTC (rev 246685) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ResourceTreeElement.css 2019-06-21 18:21:17 UTC (rev 246686) @@ -41,13 +41,13 @@ } .item.resource.resource-type-websocket:not(.selected) .status .ready-state.open, -.tree-outline:not(:focus, .force-focus) .item.resource.resource-type-websocket.selected .status .ready-state.open, +.tree-outline:not(:focus) .item.resource.resource-type-websocket.selected .status .ready-state.open, body:matches(.window-inactive, .window-docked-inactive) .item.resource.resource-type-websocket.selected .status .ready-state.open { background-color: limegreen; } .item.resource.resource-type-websocket:not(.selected) .status .ready-state.connecting, -.tree-outline:not(:focus, .force-focus) .item.resource.resource-type-websocket.selected .status .ready-state.connecting, +.tree-outline:not(:focus) .item.resource.resource-type-websocket.selected .status .ready-state.connecting, body:matches(.window-inactive, .window-docked-inactive) .item.resource.resource-type-websocket.selected .status .ready-state.connecting { background-color: yellow; } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [246684] trunk/Source/WebInspectorUI
Title: [246684] trunk/Source/WebInspectorUI Revision 246684 Author mattba...@apple.com Date 2019-06-21 10:53:33 -0700 (Fri, 21 Jun 2019) Log Message Web Inspector: remove .legacy-mac/.latest-mac CSS classes, standardize on .latest-mac UI https://bugs.webkit.org/show_bug.cgi?id=199109 Reviewed by Timothy Hatcher. Drop legacy macOS version support from Web Inspector UI. * UserInterface/Base/Main.js: * UserInterface/Views/DefaultDashboardView.css: (@media (prefers-color-scheme: dark)): (body.latest-mac .toolbar .dashboard .item.button): Deleted. * UserInterface/Views/Toolbar.css: (.toolbar): (.toolbar .item.button,): (.toolbar .search-bar > input[type="search"]): (.toolbar .search-bar > input[type="search"]:focus): (@media (-webkit-min-device-pixel-ratio: 2)): (.toolbar .item.button:active): (body.window-inactive .toolbar .item.button,): (@media (prefers-color-scheme: dark)): (.toolbar .search-bar > input[type="search"]::placeholder): (body.window-inactive .toolbar .search-bar > input[type="search"]::placeholder): (body.window-inactive .toolbar .search-bar > input[type="search"]::-webkit-search-results-button): (.toolbar .dashboard-container): (body .toolbar): Deleted. (body.legacy-mac .toolbar .item.button,): Deleted. (body.legacy-mac .toolbar .search-bar > input[type="search"]): Deleted. (body.legacy-mac .toolbar .search-bar > input[type="search"]:focus): Deleted. (body.legacy-mac .toolbar .item.button:active): Deleted. (body.window-inactive.legacy-mac .toolbar .item.button,): Deleted. (body.latest-mac .toolbar .item.button,): Deleted. (body.latest-mac .toolbar .search-bar > input[type="search"]): Deleted. (body.latest-mac .toolbar .search-bar > input[type="search"]:focus): Deleted. (body.latest-mac .toolbar .item.button:active): Deleted. (body.latest-mac.window-inactive .toolbar .item.button,): Deleted. (body.latest-mac .toolbar .search-bar > input[type="search"]::placeholder): Deleted. (body.latest-mac.window-inactive .toolbar .search-bar > input[type="search"]::placeholder): Deleted. (body.latest-mac.window-inactive .toolbar .search-bar > input[type="search"]::-webkit-search-results-button): Deleted. (body.latest-mac .toolbar .dashboard-container): Deleted. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/Main.js trunk/Source/WebInspectorUI/UserInterface/Views/DefaultDashboardView.css trunk/Source/WebInspectorUI/UserInterface/Views/Toolbar.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246683 => 246684) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-21 17:45:01 UTC (rev 246683) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-21 17:53:33 UTC (rev 246684) @@ -1,3 +1,48 @@ +2019-06-21 Matt Baker + +Web Inspector: remove .legacy-mac/.latest-mac CSS classes, standardize on .latest-mac UI +https://bugs.webkit.org/show_bug.cgi?id=199109 + + +Reviewed by Timothy Hatcher. + +Drop legacy macOS version support from Web Inspector UI. + +* UserInterface/Base/Main.js: + +* UserInterface/Views/DefaultDashboardView.css: +(@media (prefers-color-scheme: dark)): +(body.latest-mac .toolbar .dashboard .item.button): Deleted. + +* UserInterface/Views/Toolbar.css: +(.toolbar): +(.toolbar .item.button,): +(.toolbar .search-bar > input[type="search"]): +(.toolbar .search-bar > input[type="search"]:focus): +(@media (-webkit-min-device-pixel-ratio: 2)): +(.toolbar .item.button:active): +(body.window-inactive .toolbar .item.button,): +(@media (prefers-color-scheme: dark)): +(.toolbar .search-bar > input[type="search"]::placeholder): +(body.window-inactive .toolbar .search-bar > input[type="search"]::placeholder): +(body.window-inactive .toolbar .search-bar > input[type="search"]::-webkit-search-results-button): +(.toolbar .dashboard-container): +(body .toolbar): Deleted. +(body.legacy-mac .toolbar .item.button,): Deleted. +(body.legacy-mac .toolbar .search-bar > input[type="search"]): Deleted. +(body.legacy-mac .toolbar .search-bar > input[type="search"]:focus): Deleted. +(body.legacy-mac .toolbar .item.button:active): Deleted. +(body.window-inactive.legacy-mac .toolbar .item.button,): Deleted. +(body.latest-mac .toolbar .item.button,): Deleted. +(body.latest-mac .toolbar .search-bar > input[type="search"]): Deleted. +(body.latest-mac .toolbar .search-bar > input[type="search"]:focus): Deleted. +(body.latest-mac .toolbar .item.button:active): Deleted. +(body.latest-mac.window-inactive .toolbar .item.button,): Deleted. +(body.latest-mac .toolbar .search-bar > input[type="search"]::placeholder): Deleted. +(body.latest-mac.window-inactive .toolbar .search-bar > input[type="search"]::placeholder): Deleted. +(body.latest-mac.window-inactive .toolbar .search-bar
[webkit-changes] [246672] trunk/Source/WebInspectorUI
Title: [246672] trunk/Source/WebInspectorUI Revision 246672 Author mattba...@apple.com Date 2019-06-20 22:44:02 -0700 (Thu, 20 Jun 2019) Log Message Web Inspector: rename shadowRootPushed parameter to match protocol https://bugs.webkit.org/show_bug.cgi?id=199098 Reviewed by Devin Rousso. * UserInterface/Protocol/DOMObserver.js: (WI.DOMObserver.prototype.shadowRootPushed): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Protocol/DOMObserver.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246671 => 246672) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-21 05:37:04 UTC (rev 246671) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-21 05:44:02 UTC (rev 246672) @@ -1,3 +1,13 @@ +2019-06-20 Matt Baker + +Web Inspector: rename shadowRootPushed parameter to match protocol +https://bugs.webkit.org/show_bug.cgi?id=199098 + +Reviewed by Devin Rousso. + +* UserInterface/Protocol/DOMObserver.js: +(WI.DOMObserver.prototype.shadowRootPushed): + 2019-06-20 Devin Rousso Web Inspector: Error "null is not an object (evaluating 'syntaxTree.containersOfPosition')" when setting a breakpoint Modified: trunk/Source/WebInspectorUI/UserInterface/Protocol/DOMObserver.js (246671 => 246672) --- trunk/Source/WebInspectorUI/UserInterface/Protocol/DOMObserver.js 2019-06-21 05:37:04 UTC (rev 246671) +++ trunk/Source/WebInspectorUI/UserInterface/Protocol/DOMObserver.js 2019-06-21 05:44:02 UTC (rev 246672) @@ -37,9 +37,9 @@ WI.domManager.inspectElement(nodeId); } -setChildNodes(parentId, payloads) +setChildNodes(parentId, nodes) { -WI.domManager._setChildNodes(parentId, payloads); +WI.domManager._setChildNodes(parentId, nodes); } attributeModified(nodeId, name, value) @@ -67,9 +67,9 @@ WI.domManager._childNodeCountUpdated(nodeId, childNodeCount); } -childNodeInserted(parentNodeId, previousNodeId, payload) +childNodeInserted(parentNodeId, previousNodeId, node) { -WI.domManager._childNodeInserted(parentNodeId, previousNodeId, payload); +WI.domManager._childNodeInserted(parentNodeId, previousNodeId, node); } childNodeRemoved(parentNodeId, nodeId) @@ -77,14 +77,14 @@ WI.domManager._childNodeRemoved(parentNodeId, nodeId); } -shadowRootPushed(parentNodeId, nodeId) +shadowRootPushed(hostId, root) { -WI.domManager._childNodeInserted(parentNodeId, 0, nodeId); +WI.domManager._childNodeInserted(hostId, 0, root); } -shadowRootPopped(parentNodeId, nodeId) +shadowRootPopped(hostId, rootId) { -WI.domManager._childNodeRemoved(parentNodeId, nodeId); +WI.domManager._childNodeRemoved(hostId, rootId); } customElementStateChanged(nodeId, customElementState) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [246618] trunk/Source/WebInspectorUI
Title: [246618] trunk/Source/WebInspectorUI Revision 246618 Author mattba...@apple.com Date 2019-06-19 17:15:55 -0700 (Wed, 19 Jun 2019) Log Message Web Inspector: Remove unused _pendingFilter from NetworkTableContentView https://bugs.webkit.org/show_bug.cgi?id=199026 Reviewed by Devin Rousso. This flag is no longer set as of https://trac.webkit.org/changeset/225895. * UserInterface/Views/NetworkTableContentView.js: (WI.NetworkTableContentView): (WI.NetworkTableContentView.prototype._processPendingEntries): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246617 => 246618) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-20 00:14:11 UTC (rev 246617) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-20 00:15:55 UTC (rev 246618) @@ -1,3 +1,16 @@ +2019-06-19 Matt Baker + +Web Inspector: Remove unused _pendingFilter from NetworkTableContentView +https://bugs.webkit.org/show_bug.cgi?id=199026 + +Reviewed by Devin Rousso. + +This flag is no longer set as of https://trac.webkit.org/changeset/225895. + +* UserInterface/Views/NetworkTableContentView.js: +(WI.NetworkTableContentView): +(WI.NetworkTableContentView.prototype._processPendingEntries): + 2019-06-19 Devin Rousso Web Inspector: Uncaught Exception: TypeError: undefined is not an object (evaluating 'sourceCodePosition.lineNumber') Modified: trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js (246617 => 246618) --- trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js 2019-06-20 00:14:11 UTC (rev 246617) +++ trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js 2019-06-20 00:15:55 UTC (rev 246618) @@ -39,7 +39,6 @@ this._entriesSortComparator = null; -this._pendingFilter = false; this._showingRepresentedObjectCookie = null; this._table = null; @@ -1333,10 +1332,9 @@ { let collection = this._activeCollection; let needsSort = collection.pendingUpdates.length > 0; -let needsFilter = this._pendingFilter; -// No global sort or filter is needed, so just insert new records into their sorted position. -if (!needsSort && !needsFilter) { +// No global sort is needed, so just insert new records into their sorted position. +if (!needsSort) { let originalLength = collection.pendingInsertions.length; for (let resource of collection.pendingInsertions) this._insertResourceAndReloadTable(resource); @@ -1358,8 +1356,6 @@ } collection.pendingUpdates = []; -this._pendingFilter = false; - this._updateSort(); this._updateFilteredEntries(); this._reloadTable(); ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [246532] trunk/Source/WebInspectorUI
Title: [246532] trunk/Source/WebInspectorUI Revision 246532 Author mattba...@apple.com Date 2019-06-17 21:32:41 -0700 (Mon, 17 Jun 2019) Log Message Web Inspector: Elements: remove ellipses from "Break on" context menu item title https://bugs.webkit.org/show_bug.cgi?id=198944 Reviewed by Devin Rousso. Update context menu title to comply with Apple HI guidelines. * Localizations/en.lproj/localizedStrings.js: * UserInterface/Views/ContextMenuUtilities.js: Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246531 => 246532) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-18 02:33:50 UTC (rev 246531) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-18 04:32:41 UTC (rev 246532) @@ -1,3 +1,15 @@ +2019-06-17 Matt Baker + +Web Inspector: Elements: remove ellipses from "Break on" context menu item title +https://bugs.webkit.org/show_bug.cgi?id=198944 + +Reviewed by Devin Rousso. + +Update context menu title to comply with Apple HI guidelines. + +* Localizations/en.lproj/localizedStrings.js: +* UserInterface/Views/ContextMenuUtilities.js: + 2019-06-17 Devin Rousso Web Inspector: Debugger: adding a DOM/Event/URL breakpoint should enable breakpoints Modified: trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js (246531 => 246532) --- trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js 2019-06-18 02:33:50 UTC (rev 246531) +++ trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js 2019-06-18 04:32:41 UTC (rev 246532) @@ -166,9 +166,9 @@ localizedStrings["Body:"] = "Body:"; localizedStrings["Boundary"] = "Boundary"; localizedStrings["Box Model"] = "Box Model"; +localizedStrings["Break on"] = "Break on"; localizedStrings["Break on events with name:"] = "Break on events with name:"; localizedStrings["Break on request with URL:"] = "Break on request with URL:"; -localizedStrings["Break on\u2026"] = "Break on\u2026"; localizedStrings["Breakdown"] = "Breakdown"; localizedStrings["Breakdown of each memory category at the end of the selected time range"] = "Breakdown of each memory category at the end of the selected time range"; localizedStrings["Breakdown of time spent on the main thread"] = "Breakdown of time spent on the main thread"; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js (246531 => 246532) --- trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js 2019-06-18 02:33:50 UTC (rev 246531) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js 2019-06-18 04:32:41 UTC (rev 246532) @@ -291,7 +291,7 @@ contextMenu.__domBreakpointItemsAdded = true; -let subMenu = contextMenu.appendSubMenuItem(WI.UIString("Break on\u2026")); +let subMenu = contextMenu.appendSubMenuItem(WI.UIString("Break on")); let breakpoints = WI.domDebuggerManager.domBreakpointsForNode(domNode); let keyValuePairs = breakpoints.map((breakpoint) => [breakpoint.type, breakpoint]); ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [246026] trunk/Source/WebInspectorUI
Title: [246026] trunk/Source/WebInspectorUI Revision 246026 Author mattba...@apple.com Date 2019-06-02 17:05:10 -0700 (Sun, 02 Jun 2019) Log Message Web Inspector: Debugger: sidebar should always reveal active call frame when hitting a breakpoint https://bugs.webkit.org/show_bug.cgi?id=198228 Reviewed by Devin Rousso. Reveal the active call frame TreeElement when call frames change. Refreshing the current target's ThreadTreeElement children is insufficient, since the sidebar panel content may have been scrolled. This patch also introduces a workaround to prevent the DetailsSection header element, which has sticky positioning, from covering a revealed TreeElement. This can be the case when the TreeElement being revealed is at the topmost edge of the scrolled content element. * UserInterface/Base/Utilities.js: * UserInterface/Views/DebuggerSidebarPanel.js: (WI.DebuggerSidebarPanel.prototype.createContentTreeOutline): (WI.DebuggerSidebarPanel.prototype._debuggerCallFramesDidChange): * UserInterface/Views/DetailsSection.js: (WI.DetailsSection.prototype.get element): (WI.DetailsSection.prototype.get headerElement): (WI.DetailsSection.prototype.get identifier): * UserInterface/Views/SourcesNavigationSidebarPanel.js: (WI.SourcesNavigationSidebarPanel.prototype.createContentTreeOutline): (WI.SourcesNavigationSidebarPanel.prototype._handleDebuggerCallFramesDidChange): * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.reveal): * UserInterface/Views/TreeOutline.js: Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/Utilities.js trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/DetailsSection.js trunk/Source/WebInspectorUI/UserInterface/Views/SourcesNavigationSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (246025 => 246026) --- trunk/Source/WebInspectorUI/ChangeLog 2019-06-02 23:34:36 UTC (rev 246025) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-06-03 00:05:10 UTC (rev 246026) @@ -1,3 +1,39 @@ +2019-06-02 Matt Baker + +Web Inspector: Debugger: sidebar should always reveal active call frame when hitting a breakpoint +https://bugs.webkit.org/show_bug.cgi?id=198228 + + +Reviewed by Devin Rousso. + +Reveal the active call frame TreeElement when call frames change. Refreshing +the current target's ThreadTreeElement children is insufficient, since +the sidebar panel content may have been scrolled. + +This patch also introduces a workaround to prevent the DetailsSection header +element, which has sticky positioning, from covering a revealed TreeElement. +This can be the case when the TreeElement being revealed is at the topmost edge +of the scrolled content element. + +* UserInterface/Base/Utilities.js: + +* UserInterface/Views/DebuggerSidebarPanel.js: +(WI.DebuggerSidebarPanel.prototype.createContentTreeOutline): +(WI.DebuggerSidebarPanel.prototype._debuggerCallFramesDidChange): + +* UserInterface/Views/DetailsSection.js: +(WI.DetailsSection.prototype.get element): +(WI.DetailsSection.prototype.get headerElement): +(WI.DetailsSection.prototype.get identifier): + +* UserInterface/Views/SourcesNavigationSidebarPanel.js: +(WI.SourcesNavigationSidebarPanel.prototype.createContentTreeOutline): +(WI.SourcesNavigationSidebarPanel.prototype._handleDebuggerCallFramesDidChange): + +* UserInterface/Views/TreeElement.js: +(WI.TreeElement.prototype.reveal): +* UserInterface/Views/TreeOutline.js: + 2019-06-02 Devin Rousso Web Inspector: propagate whether to show prototype information to subobject views Modified: trunk/Source/WebInspectorUI/UserInterface/Base/Utilities.js (246025 => 246026) --- trunk/Source/WebInspectorUI/UserInterface/Base/Utilities.js 2019-06-02 23:34:36 UTC (rev 246025) +++ trunk/Source/WebInspectorUI/UserInterface/Base/Utilities.js 2019-06-03 00:05:10 UTC (rev 246026) @@ -388,6 +388,14 @@ } }); +Object.defineProperty(Element.prototype, "totalOffsetBottom", +{ +get() +{ +return this.getBoundingClientRect().bottom; +} +}); + Object.defineProperty(Element.prototype, "removeChildren", { value() Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js (246025 => 246026) --- trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js 2019-06-02 23:34:36 UTC (rev 246025) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js 2019-06-03 00:05:10 UTC (rev 246026) @@ -161,8 +161,8 @@ breakpointNavigationBar.addNavigationItem(this._createBreakpointButton); let breakpointsGroup = new WI.DetailsS
[webkit-changes] [245713] trunk/Source/WebInspectorUI
Title: [245713] trunk/Source/WebInspectorUI Revision 245713 Author mattba...@apple.com Date 2019-05-23 14:06:56 -0700 (Thu, 23 May 2019) Log Message Web Inspector: Remove unused CSS class "offset-sections" https://bugs.webkit.org/show_bug.cgi?id=198194 Reviewed by Devin Rousso. * UserInterface/Views/DebuggerSidebarPanel.js: * UserInterface/Views/StyleDetailsPanel.js: (WI.StyleDetailsPanel): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/StyleDetailsPanel.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (245712 => 245713) --- trunk/Source/WebInspectorUI/ChangeLog 2019-05-23 20:56:56 UTC (rev 245712) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-05-23 21:06:56 UTC (rev 245713) @@ -1,3 +1,15 @@ +2019-05-23 Matt Baker + +Web Inspector: Remove unused CSS class "offset-sections" +https://bugs.webkit.org/show_bug.cgi?id=198194 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/DebuggerSidebarPanel.js: +* UserInterface/Views/StyleDetailsPanel.js: +(WI.StyleDetailsPanel): + 2019-05-23 Devin Rousso Web Inspector: clicking a source link should never open the Network tab Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js (245712 => 245713) --- trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js 2019-05-23 20:56:56 UTC (rev 245712) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js 2019-05-23 21:06:56 UTC (rev 245713) @@ -124,9 +124,6 @@ this._debuggerStepOutButtonItem.enabled = false; this._navigationBar.addNavigationItem(this._debuggerStepOutButtonItem); -// Add this offset-sections class name so the sticky headers don't overlap the navigation bar. -this.element.classList.add(WI.DebuggerSidebarPanel.OffsetSectionsStyleClassName); - function showResourcesWithIssuesOnlyFilterFunction(treeElement) { // Issues are only shown in the scripts tree outline. Modified: trunk/Source/WebInspectorUI/UserInterface/Views/StyleDetailsPanel.js (245712 => 245713) --- trunk/Source/WebInspectorUI/UserInterface/Views/StyleDetailsPanel.js 2019-05-23 20:56:56 UTC (rev 245712) +++ trunk/Source/WebInspectorUI/UserInterface/Views/StyleDetailsPanel.js 2019-05-23 21:06:56 UTC (rev 245713) @@ -31,8 +31,7 @@ this._delegate = delegate || null; -// Add this offset-sections class name so the sticky headers don't overlap the navigation bar. -this.element.classList.add(className, "offset-sections"); +this.element.classList.add(className); this._navigationInfo = {identifier, label}; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [244063] trunk/Source/WebInspectorUI
Title: [244063] trunk/Source/WebInspectorUI Revision 244063 Author mattba...@apple.com Date 2019-04-08 18:31:54 -0700 (Mon, 08 Apr 2019) Log Message Web Inspector: Elements tab: Classes toggle should use accent color on hover https://bugs.webkit.org/show_bug.cgi?id=196266 Reviewed by Devin Rousso. * UserInterface/Views/GeneralStyleDetailsSidebarPanel.css: (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle): (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle::before): (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:matches(.selected, :hover)): (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:matches(.selected, :hover)::before): (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:not(.selected):hover::before): (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle.selected:active::before): (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle.selected): Deleted. (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:not(.selected):hover): Deleted. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/GeneralStyleDetailsSidebarPanel.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (244062 => 244063) --- trunk/Source/WebInspectorUI/ChangeLog 2019-04-09 01:26:23 UTC (rev 244062) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-04-09 01:31:54 UTC (rev 244063) @@ -1,3 +1,20 @@ +2019-04-08 Matt Baker + +Web Inspector: Elements tab: Classes toggle should use accent color on hover +https://bugs.webkit.org/show_bug.cgi?id=196266 + +Reviewed by Devin Rousso. + +* UserInterface/Views/GeneralStyleDetailsSidebarPanel.css: +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle): +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle::before): +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:matches(.selected, :hover)): +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:matches(.selected, :hover)::before): +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:not(.selected):hover::before): +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle.selected:active::before): +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle.selected): Deleted. +(.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:not(.selected):hover): Deleted. + 2019-04-08 Devin Rousso Web Inspector: REGRESSION: Audit: default audits aren't added when an existing audit is present Modified: trunk/Source/WebInspectorUI/UserInterface/Views/GeneralStyleDetailsSidebarPanel.css (244062 => 244063) --- trunk/Source/WebInspectorUI/UserInterface/Views/GeneralStyleDetailsSidebarPanel.css 2019-04-09 01:26:23 UTC (rev 244062) +++ trunk/Source/WebInspectorUI/UserInterface/Views/GeneralStyleDetailsSidebarPanel.css 2019-04-09 01:31:54 UTC (rev 244063) @@ -99,6 +99,7 @@ } .sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle { +position: relative; margin: 0 0 1px; -webkit-margin-end: 5px; padding: 2px 4px 3px; @@ -110,16 +111,34 @@ -webkit-appearance: none; } -.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle.selected { -color: var(--selected-foreground-color); -background-color: var(--selected-background-color); +.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle::before { +position: absolute; +content: ""; +left: 0; +top: 0; +width: 100%; +height: 100%; +border-radius: 3px; +opacity: var(--glyph-opacity); +z-index: -1; } -.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:not(.selected):hover { +.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:matches(.selected, :hover) { color: var(--selected-foreground-color); -background-color: var(--selected-background-color-hover); } +.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:matches(.selected, :hover)::before { +background-color: var(--glyph-color-active); +} + +.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:not(.selected):hover::before { +opacity: 0.5; +} + +.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-c
[webkit-changes] [242578] trunk/Source/WebInspectorUI
Title: [242578] trunk/Source/WebInspectorUI Revision 242578 Author mattba...@apple.com Date 2019-03-06 16:13:15 -0800 (Wed, 06 Mar 2019) Log Message Web Inspector: system accent color follow-ups https://bugs.webkit.org/show_bug.cgi?id=195190 Reviewed by Devin Rousso. * UserInterface/Views/ButtonToolbarItem.css: (.toolbar .item.button:not(.disabled):matches(:focus, .activate.activated)): (@media (prefers-color-scheme: dark)): (.toolbar .item.button:not(.disabled):active:matches(:focus, .activate.activated)): Deleted. Drop pressed toolbar button style. It's extremely subtle and not worth the hassle. * UserInterface/Views/LogContentView.css: (.console-messages:focus .console-item.selected::after): (@media (prefers-color-scheme: dark)): * UserInterface/Views/ScopeBar.css: (.scope-bar > li.selected:active::before): * UserInterface/Views/TimelineRecordBar.css: (.timeline-record-bar.selected > .segment): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/ButtonToolbarItem.css trunk/Source/WebInspectorUI/UserInterface/Views/LogContentView.css trunk/Source/WebInspectorUI/UserInterface/Views/ScopeBar.css trunk/Source/WebInspectorUI/UserInterface/Views/TimelineRecordBar.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (242577 => 242578) --- trunk/Source/WebInspectorUI/ChangeLog 2019-03-07 00:09:23 UTC (rev 242577) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-03-07 00:13:15 UTC (rev 242578) @@ -1,5 +1,28 @@ 2019-03-06 Matt Baker +Web Inspector: system accent color follow-ups +https://bugs.webkit.org/show_bug.cgi?id=195190 + +Reviewed by Devin Rousso. + +* UserInterface/Views/ButtonToolbarItem.css: +(.toolbar .item.button:not(.disabled):matches(:focus, .activate.activated)): +(@media (prefers-color-scheme: dark)): +(.toolbar .item.button:not(.disabled):active:matches(:focus, .activate.activated)): Deleted. +Drop pressed toolbar button style. It's extremely subtle and not worth the hassle. + +* UserInterface/Views/LogContentView.css: +(.console-messages:focus .console-item.selected::after): +(@media (prefers-color-scheme: dark)): + +* UserInterface/Views/ScopeBar.css: +(.scope-bar > li.selected:active::before): + +* UserInterface/Views/TimelineRecordBar.css: +(.timeline-record-bar.selected > .segment): + +2019-03-06 Matt Baker + REGRESSION: Elements tab: Uncaught Exception: No node with given id found https://bugs.webkit.org/show_bug.cgi?id=194299 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ButtonToolbarItem.css (242577 => 242578) --- trunk/Source/WebInspectorUI/UserInterface/Views/ButtonToolbarItem.css 2019-03-07 00:09:23 UTC (rev 242577) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ButtonToolbarItem.css 2019-03-07 00:13:15 UTC (rev 242578) @@ -38,13 +38,9 @@ } .toolbar .item.button:not(.disabled):matches(:focus, .activate.activated) { -color: var(--selected-background-color); +color: var(--glyph-color-active); } -.toolbar .item.button:not(.disabled):active:matches(:focus, .activate.activated) { -color: var(--selected-background-color-active); -} - .toolbar .item.button > .glyph { width: 16px; height: 16px; @@ -73,11 +69,7 @@ background: var(--button-background-color-pressed); } -.toolbar .item.button:not(.disabled):matches(:focus, .activate.activated) { -color: var(--glyph-color-active); +body:not(.window-inactive) .toolbar .item.button:not(.disabled):matches(:focus, .activate.activated) > .glyph { +filter: brightness(1.35); } - -.toolbar .item.button:not(.disabled):active:matches(:focus, .activate.activated) { -color: var(--glyph-color-active-pressed); -} } Modified: trunk/Source/WebInspectorUI/UserInterface/Views/LogContentView.css (242577 => 242578) --- trunk/Source/WebInspectorUI/UserInterface/Views/LogContentView.css 2019-03-07 00:09:23 UTC (rev 242577) +++ trunk/Source/WebInspectorUI/UserInterface/Views/LogContentView.css 2019-03-07 00:13:15 UTC (rev 242578) @@ -148,7 +148,7 @@ } .console-messages:focus .console-item.selected::after { -background: hsl(210, 100%, 49%); +background-color: var(--glyph-color-active); } .console-messages:focus .console-item.selected .go-to-link { @@ -309,10 +309,6 @@ color: var(--selected-secondary-text-color-active); } -.console-messages:focus .console-item.selected::after { -background: hsl(210, 100%, 75%); -} - .console-error-level { background-color: var(--error-background-color-secondary); border-color: var(--border-color-error); Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ScopeBar.css (242577 => 242578) --- trunk/Source/WebInspectorUI/UserInterface/Views/ScopeBar.css 2019-03-07 00:09:23 UTC (rev 242577) +++ trunk/Source/WebInspectorUI/User
[webkit-changes] [242577] trunk/Source/WebInspectorUI
Title: [242577] trunk/Source/WebInspectorUI Revision 242577 Author mattba...@apple.com Date 2019-03-06 16:09:23 -0800 (Wed, 06 Mar 2019) Log Message REGRESSION: Elements tab: Uncaught Exception: No node with given id found https://bugs.webkit.org/show_bug.cgi?id=194299 Reviewed by Devin Rousso. When removing the selection, TreeOutline subclasses should have more control over which item becomes selected after the selection is removed. DOMTreeOutline should track the items that are being removed, and prevent them or their descendants from becoming selected. * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline): (WI.DOMTreeOutline.prototype.ondelete): (WI.DOMTreeOutline.prototype.canSelectTreeElement): * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.selectionControllerLastSelectableItem): (WI.TreeOutline.prototype.selectionControllerPreviousSelectableItem): (WI.TreeOutline.prototype.selectionControllerNextSelectableItem): (WI.TreeOutline.prototype.canSelectTreeElement): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (242576 => 242577) --- trunk/Source/WebInspectorUI/ChangeLog 2019-03-07 00:06:47 UTC (rev 242576) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-03-07 00:09:23 UTC (rev 242577) @@ -1,3 +1,27 @@ +2019-03-06 Matt Baker + +REGRESSION: Elements tab: Uncaught Exception: No node with given id found +https://bugs.webkit.org/show_bug.cgi?id=194299 + + +Reviewed by Devin Rousso. + +When removing the selection, TreeOutline subclasses should have more +control over which item becomes selected after the selection is removed. +DOMTreeOutline should track the items that are being removed, and prevent +them or their descendants from becoming selected. + +* UserInterface/Views/DOMTreeOutline.js: +(WI.DOMTreeOutline): +(WI.DOMTreeOutline.prototype.ondelete): +(WI.DOMTreeOutline.prototype.canSelectTreeElement): + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype.selectionControllerLastSelectableItem): +(WI.TreeOutline.prototype.selectionControllerPreviousSelectableItem): +(WI.TreeOutline.prototype.selectionControllerNextSelectableItem): +(WI.TreeOutline.prototype.canSelectTreeElement): + 2019-03-06 Joseph Pecoraro Web Inspector: CPU Usage Timeline - Allow clicking a bar in the overview to select a tight time range around it Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js (242576 => 242577) --- trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js 2019-03-07 00:06:47 UTC (rev 242576) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js 2019-03-07 00:09:23 UTC (rev 242577) @@ -49,6 +49,7 @@ this._excludeRevealElementContextMenu = excludeRevealElementContextMenu; this._rootDOMNode = null; this._selectedDOMNode = null; +this._treeElementsToRemove = null; this._editable = false; this._editing = false; @@ -284,7 +285,7 @@ if (!this._editable) return false; -let selectedTreeElements = this.selectedTreeElements; +this._treeElementsToRemove = this.selectedTreeElements; this._selectionController.removeSelectedItems(); let levelMap = new Map; @@ -303,13 +304,13 @@ // Sort in descending order by node level. This ensures that child nodes // are removed before their ancestors. -selectedTreeElements.sort((a, b) => getLevel(b) - getLevel(a)); +this._treeElementsToRemove.sort((a, b) => getLevel(b) - getLevel(a)); // Track removed elements, since the opening and closing tags for the // same WI.DOMNode can both be selected. let removedTreeElements = new Set; -for (let treeElement of selectedTreeElements) { +for (let treeElement of this._treeElementsToRemove) { if (removedTreeElements.has(treeElement)) continue; removedTreeElements.add(treeElement) @@ -316,11 +317,29 @@ treeElement.remove(); } +this._treeElementsToRemove = null; + return true; } // Protected +canSelectTreeElement(treeElement) +{ +if (!super.canSelectTreeElement(treeElement)) +return false; + +let willRemoveAncestorOrSelf = false; +if (this._treeElementsToRemove) { +while (treeElement && !willRemoveAncestorOrSelf) { +willRemoveAncestorOrSelf = this._treeElementsToRemove.includes(treeElement); +treeElement = treeElement.parent; +} +} + +return !willRemoveAncestorOrSelf; +} + objectForSelection(treeElem
[webkit-changes] [242228] trunk/Source/WebInspectorUI
Title: [242228] trunk/Source/WebInspectorUI Revision 242228 Author mattba...@apple.com Date 2019-02-28 14:32:38 -0800 (Thu, 28 Feb 2019) Log Message Web Inspector: Debugger: disabled breakpoint color is too dark https://bugs.webkit.org/show_bug.cgi?id=195103 Reviewed by Devin Rousso. Increase the disabled breakpoint contrast, as well as the contrast between disabled and auto-continue breakpoints. Disabled breakpoints stand out by being somewhat brighter and less saturated. Using the same strategy for auto-continue breakpoints is too subtle to provide sufficient contrast. We can adopt the technique used by Xcode, and overlay a white triangle marker on the breakpoint arrow to indicate an auto-continue breakpoint. * UserInterface/Views/BreakpointTreeElement.css: (.item.breakpoint .status > .status-image): (.item.breakpoint.selected .status > .status-image.resolved): Add white outline to make selected breakpoint button stand out. (.item.breakpoint .status > .status-image.auto-continue::after): (.item.breakpoint .status > .status-image.disabled): (.item.breakpoint .status > .status-image.auto-continue): Deleted. * UserInterface/Views/DOMTreeContentView.css: (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint): (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled): (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.subtree): (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled,): Deleted. * UserInterface/Views/TextEditor.css: (.text-editor > .CodeMirror .has-breakpoint .CodeMirror-linenumber::before): (.text-editor > .CodeMirror .breakpoint-auto-continue:not(.execution-line.primary) .CodeMirror-linenumber::after): (.text-editor > .CodeMirror .breakpoint-disabled .CodeMirror-linenumber::before): (.text-editor > .CodeMirror .breakpoint-auto-continue:not(.breakpoint-disabled) .CodeMirror-linenumber::before): Deleted. * UserInterface/Views/Variables.css: (:root): Add breakpoint color variables to use across all breakpoint controls. Use system colors if available, otherwise fall back to hard-coded values based on sampling the default (blue) accent color on Mojave. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/BreakpointTreeElement.css trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeContentView.css trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.css trunk/Source/WebInspectorUI/UserInterface/Views/Variables.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (242227 => 242228) --- trunk/Source/WebInspectorUI/ChangeLog 2019-02-28 22:29:48 UTC (rev 242227) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-02-28 22:32:38 UTC (rev 242228) @@ -1,3 +1,46 @@ +2019-02-28 Matt Baker + +Web Inspector: Debugger: disabled breakpoint color is too dark +https://bugs.webkit.org/show_bug.cgi?id=195103 + + +Reviewed by Devin Rousso. + +Increase the disabled breakpoint contrast, as well as the contrast between +disabled and auto-continue breakpoints. Disabled breakpoints stand out by +being somewhat brighter and less saturated. Using the same strategy for +auto-continue breakpoints is too subtle to provide sufficient contrast. + +We can adopt the technique used by Xcode, and overlay a white triangle +marker on the breakpoint arrow to indicate an auto-continue breakpoint. + +* UserInterface/Views/BreakpointTreeElement.css: +(.item.breakpoint .status > .status-image): +(.item.breakpoint.selected .status > .status-image.resolved): +Add white outline to make selected breakpoint button stand out. +(.item.breakpoint .status > .status-image.auto-continue::after): +(.item.breakpoint .status > .status-image.disabled): +(.item.breakpoint .status > .status-image.auto-continue): Deleted. + + +* UserInterface/Views/DOMTreeContentView.css: +(.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint): +(.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled): +(.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.subtree): +(.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled,): Deleted. + +* UserInterface/Views/TextEditor.css: +(.text-editor > .CodeMirror .has-breakpoint .CodeMirror-linenumber::before): +(.text-editor > .CodeMirror .breakpoint-auto-continue:not(.execution-line.primary) .CodeMirror-linenumber::after): +(.text-editor > .CodeMirror .breakpoint-disabled .CodeMirror-linenumber::before): +(.text-editor > .CodeMirror .breakpoint-auto-continue:not(.breakpoint-disabled) .CodeMirror-linenumber::before): Deleted. + +* UserInterface/Views/Variables.css: +(:root): +Add breakpoint color variables to use across all breakpoint controls. +Use
[webkit-changes] [242118] trunk/Source/WebInspectorUI
Title: [242118] trunk/Source/WebInspectorUI Revision 242118 Author mattba...@apple.com Date 2019-02-26 17:28:02 -0800 (Tue, 26 Feb 2019) Log Message Web Inspector: Use system accent color throughout UI https://bugs.webkit.org/show_bug.cgi?id=193507 Reviewed by Timothy Hatcher. * UserInterface/Images/Breakpoint.png: Removed. * UserInterface/Images/Breakpoint.svg: Added. * UserInterface/Images/breakpo...@2x.png: Removed. * UserInterface/Images/BreakpointInactive.png: Removed. * UserInterface/Images/breakpointinact...@2x.png: Removed. Replace breakpoint pixel art with an SVG image that can be styled in CSS. * UserInterface/Images/CSSVariable.svg: * UserInterface/Images/CubicBezier.svg: * UserInterface/Images/UserInputPrompt.svg: Remove fill color since it is now styled in CSS. * UserInterface/Views/BezierEditor.css: (.bezier-editor > .bezier-preview > div): (@media (prefers-color-scheme: dark)): (.bezier-editor > .bezier-container .control-handle): (.bezier-editor > .bezier-container .control-line): Use system accent color for control handles. * UserInterface/Views/BreakpointTreeElement.css: (.item.breakpoint .status > .status-image): (.item.breakpoint .status > .status-image.resolved): Use system accent color for breakpoint fill, with a dark outline to match Xcode and make the button stand out against the selection. * UserInterface/Views/BreakpointTreeElement.js: (WI.BreakpointTreeElement.prototype._updateStatus): * UserInterface/Views/ButtonNavigationItem.css: (.navigation-bar .item.button > .glyph): * UserInterface/Views/ConsolePrompt.js: (WI.ConsolePrompt): * UserInterface/Views/DOMBreakpointTreeElement.js: * UserInterface/Views/DOMTreeContentView.css: (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint): (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled,): (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.subtree): (.content-view.dom-tree .tree-outline.dom li .status-image.breakpoint.disabled): Deleted. (.content-view.dom-tree .tree-outline.dom.breakpoints-disabled li .status-image.breakpoint): Deleted. (.content-view.dom-tree .tree-outline.dom.breakpoints-disabled li .status-image.breakpoint.disabled): Deleted. * UserInterface/Views/DOMTreeOutline.css: (.tree-outline.dom li.selected .selection-area): (.tree-outline.dom li.elements-drag-over .selection-area): (.tree-outline.dom:focus li:matches(.selected, .hovered) .selection-area): (.tree-outline.dom li.hovered:not(.selected) .selection-area): (.tree-outline.dom li.pseudo-class-enabled > .selection-area::before): Use the system accent color for the "pseudo-class enabled" marker. (@media (prefers-color-scheme: dark)): (.tree-outline.dom:focus li.selected .selection-area): Deleted. Use --selected-background-color for selection and hover styles, which is set to the system highlight color if available. * UserInterface/Views/InlineSwatch.css: (.inline-swatch:matches(.bezier, .spring, .variable)): (.inline-swatch:matches(.bezier, .spring)): Deleted. (.inline-swatch.variable): Deleted. * UserInterface/Views/InlineSwatch.js: (WI.InlineSwatch): * UserInterface/Views/NetworkDetailView.css: (.network .network-detail .navigation-bar .item.radio.button.text-only:before): (.network .network-detail .navigation-bar .item.radio.button.text-only.selected): (@media (prefers-color-scheme: dark)): (.network-detail .item.close > .glyph): * UserInterface/Views/QuickConsole.css: (.quick-console > .console-prompt > .glyph): (.quick-console > .console-prompt::before): Deleted. * UserInterface/Views/RadioButtonNavigationItem.css: (.navigation-bar .item.radio.button.text-only): (.navigation-bar .item.radio.button.text-only::before): (.navigation-bar .item.radio.button.text-only:matches(.selected, :hover)): (.navigation-bar .item.radio.button.text-only:matches(.selected, :hover)::before): (.navigation-bar .item.radio.button.text-only:not(.selected):hover::before): (.navigation-bar .item.radio.button.text-only.selected:active::before): (.navigation-bar .item.radio.button.text-only:hover): Deleted. (.navigation-bar .item.radio.button.text-only.selected): Deleted. (.navigation-bar .item.radio.button.text-only:active): Deleted. (.navigation-bar .item.radio.button.text-only.selected:active): Deleted. Use system accent color for selection and hover styles. Since it isn't yet possible to derive new colors from the accent color in CSS, fake it with a ::before pseudo-element that can have have `filter` or `opacity` effects applied to it without altering the button text color. * UserInterface/Views/RenderingFrameTimelineOverviewGraph.css: (.timeline-overview-graph.rendering-frame > .frame-marker): Use system accent color for selected frame marker. * UserInterface/Views/ScopeBar.css: (.scope-bar > li): (.scope-bar > li::before): (.scope-bar.default-item-selected > li.multiple.selected::before): (.scope-bar > li:matches(.selected, :hover)): (.scope-bar > li:matches(.selected, :hover)::before): (.scop
[webkit-changes] [242057] trunk/Source/WebInspectorUI
Title: [242057] trunk/Source/WebInspectorUI Revision 242057 Author mattba...@apple.com Date 2019-02-25 14:22:56 -0800 (Mon, 25 Feb 2019) Log Message Web Inspector: REGRESSION: TreeElement or Table row selected using the keyboard should always be revealed https://bugs.webkit.org/show_bug.cgi?id=194918 Reviewed by Devin Rousso. * UserInterface/Views/Table.js: (WI.Table.prototype.selectionControllerSelectionDidChange): * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._treeKeyDown): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/Table.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (242056 => 242057) --- trunk/Source/WebInspectorUI/ChangeLog 2019-02-25 21:52:56 UTC (rev 242056) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-02-25 22:22:56 UTC (rev 242057) @@ -1,3 +1,17 @@ +2019-02-25 Matt Baker + +Web Inspector: REGRESSION: TreeElement or Table row selected using the keyboard should always be revealed +https://bugs.webkit.org/show_bug.cgi?id=194918 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/Table.js: +(WI.Table.prototype.selectionControllerSelectionDidChange): + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype._treeKeyDown): + 2019-02-25 Devin Rousso Web Inspector: [META] Merge Resources and Debugger into a single Sources tab Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (242056 => 242057) --- trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2019-02-25 21:52:56 UTC (rev 242056) +++ trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2019-02-25 22:22:56 UTC (rev 242057) @@ -619,10 +619,9 @@ row.classList.toggle("selected", true); } -if (selectedItems.size === 1) { -let rowIndex = this._indexForRepresentedObject(selectedItems.firstValue); -if (!this._isRowVisible(rowIndex)) -this.revealRow(rowIndex); +if (this._selectionController.lastSelectedItem) { +let rowIndex = this._indexForRepresentedObject(this._selectionController.lastSelectedItem); +this.revealRow(rowIndex); } if (this._delegate.tableSelectionDidChange) Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (242056 => 242057) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-25 21:52:56 UTC (rev 242056) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-25 22:22:56 UTC (rev 242057) @@ -661,6 +661,9 @@ this._itemWasSelectedByUser = true; handled = this._selectionController.handleKeyDown(event); this._itemWasSelectedByUser = false; + +if (handled) +nextSelectedElement = this.selectedTreeElement; } if (nextSelectedElement) { ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [241652] trunk
Title: [241652] trunk Revision 241652 Author mattba...@apple.com Date 2019-02-17 12:49:38 -0800 (Sun, 17 Feb 2019) Log Message Web Inspector: Frontend performance is very slow reloading theverge.com - 50% of time in TreeOutline _indexOfTreeElement https://bugs.webkit.org/show_bug.cgi?id=193605 Reviewed by Devin Rousso. Source/WebInspectorUI: SelectionController should track an unordered Set of represented objects instead of an ordered set of indexes. This eliminates the costly and error-prone updates needed to keep the selected indexes in sync as items are added and removed from TreeOutline (and Table, to a far lesser extent). The SelectionController interface is largely the same. Class and delegate methods have been renamed to reflect the change from indexes to objects. SelectionController tracks selected items in selection order. For the operations that rely on objects being in insertion order, the controller uses a comparator function provided at construction time. * UserInterface/Base/IndexSet.js: Removed. No longer used. SelectionController now uses a plain Set. * UserInterface/Base/Utilities.js: (value): (get return): Add utilities previously supplied by IndexSet and used by SelectionController. * UserInterface/Controllers/SelectionController.js: (WI.SelectionController): (WI.SelectionController.prototype.get lastSelectedItem): (WI.SelectionController.prototype.get selectedItems): (WI.SelectionController.prototype.set allowsMultipleSelection): (WI.SelectionController.prototype.hasSelectedItem): (WI.SelectionController.prototype.selectItem): (WI.SelectionController.prototype.deselectItem): (WI.SelectionController.prototype.selectAll): (WI.SelectionController.prototype.deselectAll): (WI.SelectionController.prototype.removeSelectedItems): (WI.SelectionController.prototype.reset): (WI.SelectionController.prototype.didRemoveItems): (WI.SelectionController.prototype.handleKeyDown): (WI.SelectionController.prototype.handleItemMouseDown): (WI.SelectionController.prototype._deselectAllAndSelect): (WI.SelectionController.prototype._selectItemsFromArrowKey): (WI.SelectionController.prototype._firstSelectableItem): (WI.SelectionController.prototype._lastSelectableItem): (WI.SelectionController.prototype._previousSelectableItem): (WI.SelectionController.prototype._nextSelectableItem): (WI.SelectionController.prototype._updateSelectedItems): (WI.SelectionController.prototype._addRange): (WI.SelectionController.prototype._deleteRange): (WI.SelectionController.prototype.get numberOfItems): Deleted. (WI.SelectionController.prototype.didInsertItem): Deleted. (WI.SelectionController.prototype.handleItemMouseDown.normalizeRange): Deleted. (WI.SelectionController.prototype._nextSelectableIndex): Deleted. (WI.SelectionController.prototype._previousSelectableIndex): Deleted. * UserInterface/Main.html: * UserInterface/Test.html: Remove IndexSet. * UserInterface/Views/CookieStorageContentView.js: (WI.CookieStorageContentView.prototype.tableIndexForRepresentedObject): (WI.CookieStorageContentView.prototype.tableRepresentedObjectForIndex): * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline.prototype.objectForSelection): * UserInterface/Views/NetworkTableContentView.js: (WI.NetworkTableContentView.prototype.tableIndexForRepresentedObject): (WI.NetworkTableContentView.prototype.tableRepresentedObjectForIndex): * UserInterface/Views/Table.js: (WI.Table): (WI.Table.prototype.get selectedRow): (WI.Table.prototype.get selectedRows): (WI.Table.prototype.isRowSelected): (WI.Table.prototype.selectRow): (WI.Table.prototype.deselectRow): (WI.Table.prototype.removeRow): (WI.Table.prototype.removeSelectedRows): (WI.Table.prototype.selectionControllerSelectionDidChange): (WI.Table.prototype.selectionControllerFirstSelectableItem): (WI.Table.prototype.selectionControllerLastSelectableItem): (WI.Table.prototype.selectionControllerPreviousSelectableItem): (WI.Table.prototype.selectionControllerNextSelectableItem): (WI.Table.prototype._handleMouseDown): (WI.Table.prototype._removeRows): (WI.Table.prototype._indexForRepresentedObject): (WI.Table.prototype._representedObjectForIndex): (WI.Table.prototype.selectionControllerNumberOfItems): Deleted. (WI.Table.prototype.selectionControllerNextSelectableIndex): Deleted. (WI.Table.prototype.selectionControllerPreviousSelectableIndex): Deleted. (WI.Table.prototype._toggleSelectedRowStyle): Deleted. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.compareSiblings): (WI.TreeOutline): (WI.TreeOutline.prototype.get selectedTreeElement): (WI.TreeOutline.prototype.set selectedTreeElement): (WI.TreeOutline.prototype.get selectedTreeElements): (WI.TreeOutline.prototype.removeChildAtIndex): (WI.TreeOutline.prototype.removeChildren): (WI.TreeOutline.prototype._rememberTreeElement): (WI.TreeOutline.prototype.getCachedTreeElement): (WI.TreeOutline.prototype.selectionControllerSelectionDidChange): (WI.TreeOutline.prototype.selectionControllerFirstSelectableItem): (WI.TreeOutlin
[webkit-changes] [241003] trunk/Source/WebInspectorUI
Title: [241003] trunk/Source/WebInspectorUI Revision 241003 Author mattba...@apple.com Date 2019-02-05 16:55:28 -0800 (Tue, 05 Feb 2019) Log Message Web Inspector: Elements tab: selection is broken after deleting the selected node https://bugs.webkit.org/show_bug.cgi?id=194300 Reviewed by Devin Rousso. Deleting a TreeElement can cause an IndexSet including indexes outside the deleted range to be passed to SelectionController, corrupting the internal selection state. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._indexesForSubtree.numberOfElementsInSubtree): Added. (WI.TreeOutline.prototype._indexesForSubtree): Finding the last (rightmost leaf) TreeElement in the subtree used TreeElement.prototype.traverseNextElement to do a depth first traversal. This method did not stay within the subtree rooted at `treeElement`. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (241002 => 241003) --- trunk/Source/WebInspectorUI/ChangeLog 2019-02-06 00:49:48 UTC (rev 241002) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-02-06 00:55:28 UTC (rev 241003) @@ -1,5 +1,24 @@ 2019-02-05 Matt Baker +Web Inspector: Elements tab: selection is broken after deleting the selected node +https://bugs.webkit.org/show_bug.cgi?id=194300 + + +Reviewed by Devin Rousso. + +Deleting a TreeElement can cause an IndexSet including indexes +outside the deleted range to be passed to SelectionController, +corrupting the internal selection state. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype._indexesForSubtree.numberOfElementsInSubtree): Added. +(WI.TreeOutline.prototype._indexesForSubtree): +Finding the last (rightmost leaf) TreeElement in the subtree used +TreeElement.prototype.traverseNextElement to do a depth first traversal. +This method did not stay within the subtree rooted at `treeElement`. + +2019-02-05 Matt Baker + Web Inspector: REGRESSION (r240947): Resources tab: can't select main frame after refreshing page https://bugs.webkit.org/show_bug.cgi?id=194254 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (241002 => 241003) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-06 00:49:48 UTC (rev 241002) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-06 00:55:28 UTC (rev 241003) @@ -1089,26 +1089,25 @@ if (!treeOutline) return null; -let firstChild = treeElement.children[0]; -if (treeElement.root && !firstChild) -return null; +function numberOfElementsInSubtree(treeElement) { +let elements = treeElement.root ? Array.from(treeElement.children) : [treeElement]; +let count = 0; +while (elements.length) { +let child = elements.pop(); +if (child.hidden) +continue; -let current = firstChild || treeElement; -let startIndex = treeOutline._indexOfTreeElement(current); -let endIndex = startIndex; +count++; +elements = elements.concat(child.children); +} +return count; +} -const skipUnrevealed = false; -const stayWithin = treeElement; -const dontPopulate = true; - -while (current = current.traverseNextTreeElement(skipUnrevealed, stayWithin, dontPopulate)) -endIndex++; - -let count = endIndex - startIndex + 1; - +let firstChild = treeElement.root ? treeElement.children[0] : treeElement; +let startIndex = treeOutline._indexOfTreeElement(firstChild); +let count = numberOfElementsInSubtree(treeElement); let indexes = new WI.IndexSet; indexes.addRange(startIndex, count); - return indexes; } }; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [240997] trunk/Source/WebInspectorUI
Title: [240997] trunk/Source/WebInspectorUI Revision 240997 Author mattba...@apple.com Date 2019-02-05 15:33:05 -0800 (Tue, 05 Feb 2019) Log Message Web Inspector: REGRESSION (r240947): Resources tab: can't select main frame after refreshing page https://bugs.webkit.org/show_bug.cgi?id=194254 Reviewed by Devin Rousso. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.selectionControllerSelectionDidChange): TreeOutline should always call the TreeElement `select` and `deselect` methods while processing selection changes. Having notifications suppressed by `this._suppressNextSelectionDidChangeEvent` should only affect the dispatching of TreeOutline events. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (240996 => 240997) --- trunk/Source/WebInspectorUI/ChangeLog 2019-02-05 23:17:14 UTC (rev 240996) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-02-05 23:33:05 UTC (rev 240997) @@ -1,3 +1,18 @@ +2019-02-05 Matt Baker + +Web Inspector: REGRESSION (r240947): Resources tab: can't select main frame after refreshing page +https://bugs.webkit.org/show_bug.cgi?id=194254 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype.selectionControllerSelectionDidChange): +TreeOutline should always call the TreeElement `select` and `deselect` +methods while processing selection changes. Having notifications +suppressed by `this._suppressNextSelectionDidChangeEvent` should only +affect the dispatching of TreeOutline events. + 2019-02-05 Nikita Vasilyev Web Inspector: Styles: remove harmless "property was unlocked" asserts Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (240996 => 240997) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-05 23:17:14 UTC (rev 240996) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-05 23:33:05 UTC (rev 240997) @@ -812,8 +812,7 @@ if (treeElement) { if (treeElement.listItemElement) treeElement.listItemElement.classList.remove("selected"); -if (!this._suppressNextSelectionDidChangeEvent) -treeElement.deselect(); +treeElement.deselect(); } } @@ -823,8 +822,8 @@ if (treeElement) { if (treeElement.listItemElement) treeElement.listItemElement.classList.add("selected"); -if (!this._suppressNextSelectionDidChangeEvent) -treeElement.select(); +const omitFocus = true; +treeElement.select(omitFocus); } } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [240950] trunk/Source/WebInspectorUI
Title: [240950] trunk/Source/WebInspectorUI Revision 240950 Author mattba...@apple.com Date 2019-02-04 17:08:40 -0800 (Mon, 04 Feb 2019) Log Message Web Inspector: REGRESSION: Resources: WI.TreeOutline assertions when refreshing the page https://bugs.webkit.org/show_bug.cgi?id=194242 Reviewed by Joseph Pecoraro. * UserInterface/Views/FolderizedTreeElement.js: (WI.FolderizedTreeElement.prototype.removeChildren): FolderTreeElements are removed by the base class call to removeChildren. Calling `removeChildren` for detached TreeElements is unnecessary. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/FolderizedTreeElement.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (240949 => 240950) --- trunk/Source/WebInspectorUI/ChangeLog 2019-02-05 00:47:17 UTC (rev 240949) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-02-05 01:08:40 UTC (rev 240950) @@ -1,5 +1,18 @@ 2019-02-04 Matt Baker +Web Inspector: REGRESSION: Resources: WI.TreeOutline assertions when refreshing the page +https://bugs.webkit.org/show_bug.cgi?id=194242 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/FolderizedTreeElement.js: +(WI.FolderizedTreeElement.prototype.removeChildren): +FolderTreeElements are removed by the base class call to removeChildren. +Calling `removeChildren` for detached TreeElements is unnecessary. + +2019-02-04 Matt Baker + Web Inspector: REGRESSION: clicking a selected call frame doesn't re-scroll https://bugs.webkit.org/show_bug.cgi?id=194169 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/FolderizedTreeElement.js (240949 => 240950) --- trunk/Source/WebInspectorUI/UserInterface/Views/FolderizedTreeElement.js 2019-02-05 00:47:17 UTC (rev 240949) +++ trunk/Source/WebInspectorUI/UserInterface/Views/FolderizedTreeElement.js 2019-02-05 01:08:40 UTC (rev 240950) @@ -69,8 +69,6 @@ this._folderizeSettingsMap.set(type, settings); } -// Overrides from TreeElement (Private). - removeChildren() { super.removeChildren(); @@ -77,9 +75,6 @@ this._clearNewChildQueue(); -for (var folder of this._folderTypeMap.values()) -folder.removeChildren(); - this._folderExpandedSettingMap.clear(); this._folderTypeMap.clear(); ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [240947] trunk/Source/WebInspectorUI
Title: [240947] trunk/Source/WebInspectorUI Revision 240947 Author mattba...@apple.com Date 2019-02-04 15:32:46 -0800 (Mon, 04 Feb 2019) Log Message Web Inspector: REGRESSION: clicking a selected call frame doesn't re-scroll https://bugs.webkit.org/show_bug.cgi?id=194169 Reviewed by Devin Rousso. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._handleMouseDown): Add a special case for a single-selection TreeOutline with allowsRepeatSelection enabled. Since the element is already selected, bypass the SelectionCongroller and dispatch an event with event.data.selectedByUser set to true. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (240946 => 240947) --- trunk/Source/WebInspectorUI/ChangeLog 2019-02-04 23:30:49 UTC (rev 240946) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-02-04 23:32:46 UTC (rev 240947) @@ -1,3 +1,18 @@ +2019-02-04 Matt Baker + +Web Inspector: REGRESSION: clicking a selected call frame doesn't re-scroll +https://bugs.webkit.org/show_bug.cgi?id=194169 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype._handleMouseDown): +Add a special case for a single-selection TreeOutline with +allowsRepeatSelection enabled. Since the element is already +selected, bypass the SelectionCongroller and dispatch an +event with event.data.selectedByUser set to true. + 2019-02-04 Nikita Vasilyev Web Inspector: Styles: fix race conditions when editing Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (240946 => 240947) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-04 23:30:49 UTC (rev 240946) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-02-04 23:32:46 UTC (rev 240947) @@ -1015,6 +1015,14 @@ if (!treeElement.canSelectOnMouseDown(event)) return; +if (this.allowsRepeatSelection && treeElement.selected && this._selectionController.selectedItems.size === 1) { +// Special case for dispatching a selection event for an already selected +// item in single-selection mode. +this._itemWasSelectedByUser = true; +this._dispatchSelectionDidChangeEvent(); +return; +} + let index = this._indexOfTreeElement(treeElement); if (isNaN(index)) return; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [240819] trunk/Source/WebInspectorUI
Title: [240819] trunk/Source/WebInspectorUI Revision 240819 Author mattba...@apple.com Date 2019-01-31 14:17:49 -0800 (Thu, 31 Jan 2019) Log Message REGRESSION(r?): Web Inspector: Clicking on text doesn't move text caret when editing innerHTML/tagName/attribute https://bugs.webkit.org/show_bug.cgi?id=192652 Reviewed by Devin Rousso. * UserInterface/Views/DOMTreeElement.js: (WI.DOMTreeElement.prototype.canSelectOnMouseDown): Call to Event.preventDefault() should be made here instead of at the TreeOutline level. * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.selectOnMouseDown): Deleted. Remove dead code. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline._handleMouseDown): Do not prevent default event handling when the item cannot be selected. This matches TreeOutline behavior prior to introducing SelectionController. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (240818 => 240819) --- trunk/Source/WebInspectorUI/ChangeLog 2019-01-31 22:14:17 UTC (rev 240818) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-01-31 22:17:49 UTC (rev 240819) @@ -1,3 +1,25 @@ +2019-01-31 Matt Baker + +REGRESSION(r?): Web Inspector: Clicking on text doesn't move text caret when editing innerHTML/tagName/attribute +https://bugs.webkit.org/show_bug.cgi?id=192652 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/DOMTreeElement.js: +(WI.DOMTreeElement.prototype.canSelectOnMouseDown): +Call to Event.preventDefault() should be made here instead of at the +TreeOutline level. + +* UserInterface/Views/TreeElement.js: +(WI.TreeElement.prototype.selectOnMouseDown): Deleted. +Remove dead code. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline._handleMouseDown): +Do not prevent default event handling when the item cannot be selected. +This matches TreeOutline behavior prior to introducing SelectionController. + 2019-01-30 Devin Rousso Web Inspector: Memory Timeline View should be responsive / resizable Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js (240818 => 240819) --- trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js 2019-01-31 22:14:17 UTC (rev 240818) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js 2019-01-31 22:17:49 UTC (rev 240819) @@ -646,8 +646,10 @@ return false; // Prevent selecting the nearest word on double click. -if (event.detail >= 2) +if (event.detail >= 2) { +event.preventDefault(); return false; +} return true; } Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js (240818 => 240819) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2019-01-31 22:14:17 UTC (rev 240818) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2019-01-31 22:17:49 UTC (rev 240819) @@ -490,14 +490,6 @@ return true; } -selectOnMouseDown(event) -{ -if (!this.treeOutline.selectable) -return; - -this.select(false, true); -} - select(omitFocus, selectedByUser, suppressNotification) { if (!this.treeOutline || !this.selectable) Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (240818 => 240819) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-31 22:14:17 UTC (rev 240818) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-31 22:17:49 UTC (rev 240819) @@ -1012,10 +1012,8 @@ return; } -if (!treeElement.canSelectOnMouseDown(event)) { -event.preventDefault(); +if (!treeElement.canSelectOnMouseDown(event)) return; -} let index = this._indexOfTreeElement(treeElement); if (isNaN(index)) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [240639] trunk/Source/WebInspectorUI
Title: [240639] trunk/Source/WebInspectorUI Revision 240639 Author mattba...@apple.com Date 2019-01-28 21:21:41 -0800 (Mon, 28 Jan 2019) Log Message Web Inspector: Elements tab should toggle visibility for all selected nodes https://bugs.webkit.org/show_bug.cgi?id=193089 Reviewed by Devin Rousso. Update "Toggle Visibility" command in DOM tree for multiple selection. When both visible and hidden elements are selected in the DOM tree, the toggle command behaves contextually. If one or more elements are visible, they are hidden, otherwise they are shown. The context menu shows "Hide Elements" or "Show Elements", respectively. When only one element is selected, or the context menu target element is not selected, the command continues to be "Toggle Visibility". * Localizations/en.lproj/localizedStrings.js: * UserInterface/Views/DOMTreeElement.js: (WI.DOMTreeElement.prototype.get isNodeHidden): Added. (WI.DOMTreeElement.prototype.toggleElementVisibility.inspectedPage_node_injectStyleAndToggleClass): (WI.DOMTreeElement.prototype.toggleElementVisibility): (WI.DOMTreeElement.prototype._populateTagContextMenu): * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline): (WI.DOMTreeOutline.prototype.toggleSelectedElementsVisibility): Added. Provide a public method for toggling the visibility of selected DOM nodes. Used by the "H" keyboard shortcut and DOMTreeElement context menu. (WI.DOMTreeOutline.prototype._hideElements): (WI.DOMTreeOutline.prototype._hideElement): Deleted. Rename for multiple selection. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (240638 => 240639) --- trunk/Source/WebInspectorUI/ChangeLog 2019-01-29 04:49:39 UTC (rev 240638) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-01-29 05:21:41 UTC (rev 240639) @@ -1,3 +1,38 @@ +2019-01-28 Matt Baker + +Web Inspector: Elements tab should toggle visibility for all selected nodes +https://bugs.webkit.org/show_bug.cgi?id=193089 + + +Reviewed by Devin Rousso. + +Update "Toggle Visibility" command in DOM tree for multiple selection. +When both visible and hidden elements are selected in the DOM tree, +the toggle command behaves contextually. If one or more elements are +visible, they are hidden, otherwise they are shown. The context menu +shows "Hide Elements" or "Show Elements", respectively. + +When only one element is selected, or the context menu target element +is not selected, the command continues to be "Toggle Visibility". + +* Localizations/en.lproj/localizedStrings.js: + +* UserInterface/Views/DOMTreeElement.js: +(WI.DOMTreeElement.prototype.get isNodeHidden): Added. +(WI.DOMTreeElement.prototype.toggleElementVisibility.inspectedPage_node_injectStyleAndToggleClass): +(WI.DOMTreeElement.prototype.toggleElementVisibility): +(WI.DOMTreeElement.prototype._populateTagContextMenu): + +* UserInterface/Views/DOMTreeOutline.js: +(WI.DOMTreeOutline): +(WI.DOMTreeOutline.prototype.toggleSelectedElementsVisibility): Added. +Provide a public method for toggling the visibility of selected DOM nodes. +Used by the "H" keyboard shortcut and DOMTreeElement context menu. + +(WI.DOMTreeOutline.prototype._hideElements): +(WI.DOMTreeOutline.prototype._hideElement): Deleted. +Rename for multiple selection. + 2019-01-28 Commit Queue Unreviewed, rolling out r240351. Modified: trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js (240638 => 240639) --- trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js 2019-01-29 04:49:39 UTC (rev 240638) +++ trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js 2019-01-29 05:21:41 UTC (rev 240639) @@ -490,6 +490,7 @@ localizedStrings["Height"] = "Height"; localizedStrings["Hide Console"] = "Hide Console"; localizedStrings["Hide Console (%s)"] = "Hide Console (%s)"; +localizedStrings["Hide Elements"] = "Hide Elements"; localizedStrings["Hide Grid"] = "Hide Grid"; localizedStrings["Hide Path"] = "Hide Path"; localizedStrings["Hide Rulers"] = "Hide Rulers"; @@ -858,6 +859,7 @@ localizedStrings["Show All Nodes (%d More)"] = "Show All Nodes (%d More)"; localizedStrings["Show Console"] = "Show Console"; localizedStrings["Show Console tab"] = "Show Console tab"; +localizedStrings["Show Elements"] = "Show Elements"; localizedStrings["Show Grid"] = "Show Grid"; localizedStrings["Show Path"] = "Show Path"; localizedStrings["Show Remaining (%d)"] = "Show Remaining (%d)"; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js (240638 => 240639) --- trunk/Sour
[webkit-changes] [240594] trunk/Source/WebInspectorUI
Title: [240594] trunk/Source/WebInspectorUI Revision 240594 Author mattba...@apple.com Date 2019-01-28 11:53:20 -0800 (Mon, 28 Jan 2019) Log Message REGRESSION(?): Web Inspector: Can have multiple Timelines selected after edit mode https://bugs.webkit.org/show_bug.cgi?id=193808 Reviewed by Devin Rousso. * UserInterface/Controllers/SelectionController.js: (WI.SelectionController.prototype.didRemoveItems): * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._indexesForSubtree): Fix a bug where no IndexSet was returned when passed a TreeElement with no children. This caused the Timelines tree selection to be corrupted when entering and exiting edit mode, as TreeElements are inserted and removed. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (240593 => 240594) --- trunk/Source/WebInspectorUI/ChangeLog 2019-01-28 19:52:17 UTC (rev 240593) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-01-28 19:53:20 UTC (rev 240594) @@ -1,3 +1,20 @@ +2019-01-28 Matt Baker + +REGRESSION(?): Web Inspector: Can have multiple Timelines selected after edit mode +https://bugs.webkit.org/show_bug.cgi?id=193808 + + +Reviewed by Devin Rousso. + +* UserInterface/Controllers/SelectionController.js: +(WI.SelectionController.prototype.didRemoveItems): + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype._indexesForSubtree): +Fix a bug where no IndexSet was returned when passed a TreeElement with +no children. This caused the Timelines tree selection to be corrupted when +entering and exiting edit mode, as TreeElements are inserted and removed. + 2019-01-28 Nikita Vasilyev Web Inspector: Add Changes panel to Elements tab Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js (240593 => 240594) --- trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2019-01-28 19:52:17 UTC (rev 240593) +++ trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2019-01-28 19:53:20 UTC (rev 240594) @@ -221,9 +221,12 @@ didRemoveItems(indexes) { +if (!indexes) +return; + console.assert(indexes instanceof WI.IndexSet); -if (!this._selectedIndexes.size) +if (!indexes.size || !this._selectedIndexes.size) return; let firstRemovedIndex = indexes.firstIndex; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (240593 => 240594) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-28 19:52:17 UTC (rev 240593) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-28 19:53:20 UTC (rev 240594) @@ -1082,13 +1082,14 @@ { let treeOutline = treeElement.treeOutline; if (!treeOutline) -return new WI.IndexSet; +return null; let firstChild = treeElement.children[0]; -if (!firstChild) -return new WI.IndexSet; +if (treeElement.root && !firstChild) +return null; -let startIndex = treeOutline._indexOfTreeElement(firstChild); +let current = firstChild || treeElement; +let startIndex = treeOutline._indexOfTreeElement(current); let endIndex = startIndex; const skipUnrevealed = false; @@ -1095,14 +1096,9 @@ const stayWithin = treeElement; const dontPopulate = true; -let current = firstChild; while (current = current.traverseNextTreeElement(skipUnrevealed, stayWithin, dontPopulate)) endIndex++; -// Include the index of the subtree's root, unless it's the TreeOutline root. -if (!treeElement.root) -startIndex--; - let count = endIndex - startIndex + 1; let indexes = new WI.IndexSet; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [240051] trunk/Source/WebInspectorUI
Title: [240051] trunk/Source/WebInspectorUI Revision 240051 Author mattba...@apple.com Date 2019-01-16 14:04:35 -0800 (Wed, 16 Jan 2019) Log Message Web Inspector: Fix TreeOutline TypeError:​ this._indexesForSubtree is not a function https://bugs.webkit.org/show_bug.cgi?id=193501 Reviewed by Joseph Pecoraro. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.removeChildAtIndex): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (240050 => 240051) --- trunk/Source/WebInspectorUI/ChangeLog 2019-01-16 21:06:45 UTC (rev 240050) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-01-16 22:04:35 UTC (rev 240051) @@ -1,3 +1,14 @@ +2019-01-16 Matt Baker + +Web Inspector: Fix TreeOutline TypeError:​ this._indexesForSubtree is not a function +https://bugs.webkit.org/show_bug.cgi?id=193501 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype.removeChildAtIndex): + 2019-01-15 Devin Rousso Web Inspector: Audit: create new IDL type for exposing special functionality in test context Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (240050 => 240051) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-16 21:06:45 UTC (rev 240050) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-16 22:04:35 UTC (rev 240051) @@ -323,14 +323,15 @@ parent.select(true, false); } +let removedIndexes = null; + let treeOutline = child.treeOutline; if (treeOutline) { treeOutline._forgetTreeElement(child); treeOutline._forgetChildrenRecursive(child); +removedIndexes = treeOutline._indexesForSubtree(child); } -let removedIndexes = this._indexesForSubtree(child); - if (child.previousSibling) child.previousSibling.nextSibling = child.nextSibling; if (child.nextSibling) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [239870] trunk/Source/WebInspectorUI
Title: [239870] trunk/Source/WebInspectorUI Revision 239870 Author mattba...@apple.com Date 2019-01-11 13:02:28 -0800 (Fri, 11 Jan 2019) Log Message Web Inspector: REGRESSION: deleting an audit puts selection in a selected but invisible state https://bugs.webkit.org/show_bug.cgi?id=192917 Reviewed by Devin Rousso. SelectionController should not be notified of removed children until the child items have been removed from the TreeOutline. Doing so at this stage is unsafe, since this method checks `this.selectedTreeElement`, which could return the adjusted index from the SelectionController before anything has actually been removed from the TreeOutline. The number of calls to SelectionController.prototype.didRemoveItems is also reduced somewhat, since we're no longer calling it for every TreeElement. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.removeChildAtIndex): (WI.TreeOutline.prototype.removeChildren): (WI.TreeOutline.prototype._forgetTreeElement): (WI.TreeOutline.prototype._indexesForSubtree): Added. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (239869 => 239870) --- trunk/Source/WebInspectorUI/ChangeLog 2019-01-11 21:01:47 UTC (rev 239869) +++ trunk/Source/WebInspectorUI/ChangeLog 2019-01-11 21:02:28 UTC (rev 239870) @@ -1,3 +1,26 @@ +2019-01-11 Matt Baker + +Web Inspector: REGRESSION: deleting an audit puts selection in a selected but invisible state +https://bugs.webkit.org/show_bug.cgi?id=192917 + + +Reviewed by Devin Rousso. + +SelectionController should not be notified of removed children until the +child items have been removed from the TreeOutline. Doing so at this stage +is unsafe, since this method checks `this.selectedTreeElement`, which could +return the adjusted index from the SelectionController before anything has +actually been removed from the TreeOutline. + +The number of calls to SelectionController.prototype.didRemoveItems is also +reduced somewhat, since we're no longer calling it for every TreeElement. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype.removeChildAtIndex): +(WI.TreeOutline.prototype.removeChildren): +(WI.TreeOutline.prototype._forgetTreeElement): +(WI.TreeOutline.prototype._indexesForSubtree): Added. + 2019-01-10 Devin Rousso Web Inspector: Audit: allow audits to be enabled/disabled Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (239869 => 239870) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-11 21:01:47 UTC (rev 239869) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2019-01-11 21:02:28 UTC (rev 239870) @@ -329,6 +329,8 @@ treeOutline._forgetChildrenRecursive(child); } +let removedIndexes = this._indexesForSubtree(child); + if (child.previousSibling) child.previousSibling.nextSibling = child.nextSibling; if (child.nextSibling) @@ -342,8 +344,10 @@ child.nextSibling = null; child.previousSibling = null; -if (treeOutline) +if (treeOutline) { +treeOutline._selectionController.didRemoveItems(removedIndexes); treeOutline.dispatchEventToListeners(WI.TreeOutline.Event.ElementRemoved, {element: child}); +} } removeChild(child, suppressOnDeselect, suppressSelectSibling) @@ -378,6 +382,8 @@ treeOutline._forgetChildrenRecursive(child); } +let removedIndexes = treeOutline._indexesForSubtree(child); + child._detach(); child.treeOutline = null; child.parent = null; @@ -384,10 +390,12 @@ child.nextSibling = null; child.previousSibling = null; -if (treeOutline) +this.children.shift(); + +if (treeOutline) { +treeOutline._selectionController.didRemoveItems(removedIndexes); treeOutline.dispatchEventToListeners(WI.TreeOutline.Event.ElementRemoved, {element: child}); - -this.children.shift(); +} } } @@ -419,10 +427,6 @@ this.selectedTreeElement = null; } if (this._knownTreeElements[element.identifier]) { -let index = this._indexOfTreeElement(element); -if (index >= 0) -this._selectionController.didRemoveItems(new WI.IndexSet([index])); - this._knownTreeElements[element.identifier].remove(element, true); this._cachedNumberOfDescendents--; } @@ -1072,6 +1076,39 @@ this.dispatchEventToListeners(WI.TreeOutline.Event.SelectionDidChange, {selectedByUser}); } + +_indexesForSubtree(treeElement) +{ +
[webkit-changes] [239405] trunk/Source/WebInspectorUI
Title: [239405] trunk/Source/WebInspectorUI Revision 239405 Author mattba...@apple.com Date 2018-12-19 16:46:10 -0800 (Wed, 19 Dec 2018) Log Message Web Inspector: Elements tab: arrow key after undoing a DOM node delete selects the wrong element https://bugs.webkit.org/show_bug.cgi?id=192871 Reviewed by Devin Rousso. Undoing a DOM node removal reinserts the node into the DOMTreeOutline. When the reinserted node precedes the selected node in the tree, the SelectionController should update `_lastSelectedIndex`. * UserInterface/Controllers/SelectionController.js: (WI.SelectionController.prototype.didInsertItem): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (239404 => 239405) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-20 00:31:27 UTC (rev 239404) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-20 00:46:10 UTC (rev 239405) @@ -1,3 +1,18 @@ +2018-12-19 Matt Baker + +Web Inspector: Elements tab: arrow key after undoing a DOM node delete selects the wrong element +https://bugs.webkit.org/show_bug.cgi?id=192871 + + +Reviewed by Devin Rousso. + +Undoing a DOM node removal reinserts the node into the DOMTreeOutline. +When the reinserted node precedes the selected node in the tree, the +SelectionController should update `_lastSelectedIndex`. + +* UserInterface/Controllers/SelectionController.js: +(WI.SelectionController.prototype.didInsertItem): + 2018-12-19 Devin Rousso Web Inspector: Audit: provide localization support for % pass display Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js (239404 => 239405) --- trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-12-20 00:31:27 UTC (rev 239404) +++ trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-12-20 00:46:10 UTC (rev 239405) @@ -212,6 +212,11 @@ current = this._selectedIndexes.indexLessThan(current); } + +if (this._lastSelectedIndex >= index) +this._lastSelectedIndex += 1; +if (this._shiftAnchorIndex >= index) +this._shiftAnchorIndex += 1; } didRemoveItems(indexes) Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (239404 => 239405) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-20 00:31:27 UTC (rev 239404) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-20 00:46:10 UTC (rev 239405) @@ -406,8 +406,10 @@ this._cachedNumberOfDescendents++; let index = this._indexOfTreeElement(element); -if (index >= 0) +if (index >= 0) { +console.assert(!element.selected, "TreeElement should not be selected before being inserted."); this._selectionController.didInsertItem(index); +} } _forgetTreeElement(element) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [239246] trunk/Source/WebInspectorUI
Title: [239246] trunk/Source/WebInspectorUI Revision 239246 Author mattba...@apple.com Date 2018-12-14 19:34:54 -0800 (Fri, 14 Dec 2018) Log Message Web Inspector: REGRESSION(r238599): Uncaught Exception: TypeError: null is not an object (evaluating 'treeElement.listItemElement.classList') https://bugs.webkit.org/show_bug.cgi?id=192090 Reviewed by Devin Rousso. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.selectionControllerSelectionDidChange): Check that `listItemElement` is valid before accessing it to update class names. The selection can change before the TreeElement has been attached. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (239245 => 239246) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-15 03:05:59 UTC (rev 239245) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-15 03:34:54 UTC (rev 239246) @@ -1,5 +1,18 @@ 2018-12-14 Matt Baker +Web Inspector: REGRESSION(r238599): Uncaught Exception: TypeError: null is not an object (evaluating 'treeElement.listItemElement.classList') +https://bugs.webkit.org/show_bug.cgi?id=192090 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype.selectionControllerSelectionDidChange): +Check that `listItemElement` is valid before accessing it to update class +names. The selection can change before the TreeElement has been attached. + +2018-12-14 Matt Baker + Web Inspector: Cookies view should use model objects instead of raw payload data https://bugs.webkit.org/show_bug.cgi?id=189533 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (239245 => 239246) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-15 03:05:59 UTC (rev 239245) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-15 03:34:54 UTC (rev 239246) @@ -803,7 +803,8 @@ let treeElement = this._treeElementAtIndex(index); console.assert(treeElement, "Missing TreeElement for deselected index " + index); if (treeElement) { -treeElement.listItemElement.classList.remove("selected"); +if (treeElement.listItemElement) +treeElement.listItemElement.classList.remove("selected"); if (!this._suppressNextSelectionDidChangeEvent) treeElement.deselect(); } @@ -813,7 +814,8 @@ let treeElement = this._treeElementAtIndex(index); console.assert(treeElement, "Missing TreeElement for selected index " + index); if (treeElement) { -treeElement.listItemElement.classList.add("selected"); +if (treeElement.listItemElement) +treeElement.listItemElement.classList.add("selected"); if (!this._suppressNextSelectionDidChangeEvent) treeElement.select(); } @@ -821,12 +823,12 @@ let selectedTreeElement = this.selectedTreeElement; if (selectedTreeElement !== this._previousSelectedTreeElement) { -if (this._previousSelectedTreeElement) +if (this._previousSelectedTreeElement && this._previousSelectedTreeElement.listItemElement) this._previousSelectedTreeElement.listItemElement.classList.remove("last-selected"); this._previousSelectedTreeElement = selectedTreeElement; -if (this._previousSelectedTreeElement) +if (this._previousSelectedTreeElement && this._previousSelectedTreeElement.listItemElement) this._previousSelectedTreeElement.listItemElement.classList.add("last-selected"); } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [239226] trunk
Title: [239226] trunk Revision 239226 Author mattba...@apple.com Date 2018-12-14 12:41:31 -0800 (Fri, 14 Dec 2018) Log Message Web Inspector: Cookies view should use model objects instead of raw payload data https://bugs.webkit.org/show_bug.cgi?id=189533 Reviewed by Joseph Pecoraro and Devin Rousso. Source/WebInspectorUI: * UserInterface/Models/Cookie.js: (WI.Cookie): (WI.Cookie.fromPayload): (WI.Cookie.parseSetCookieResponseHeader): (WI.Cookie.prototype.get type): (WI.Cookie.prototype.get name): (WI.Cookie.prototype.get value): (WI.Cookie.prototype.get header): (WI.Cookie.prototype.get expires): (WI.Cookie.prototype.get maxAge): (WI.Cookie.prototype.get path): (WI.Cookie.prototype.get domain): (WI.Cookie.prototype.get secure): (WI.Cookie.prototype.get httpOnly): (WI.Cookie.prototype.get sameSite): (WI.Cookie.prototype.get size): (WI.Cookie.prototype.get url): (WI.Cookie.prototype.expirationDate): Cleanup Cookie object; add pubic getters for data, `url` property, static `fromPayload` method, and calculate `_size` if missing. * UserInterface/Views/CookieStorageContentView.js: (WI.CookieStorageContentView.prototype.tableDidRemoveRows): (WI.CookieStorageContentView.prototype._reloadCookies): Create Cookie objects from the payload instead of using raw payload data. LayoutTests: * inspector/unit-tests/cookie-expected.txt: * inspector/unit-tests/cookie.html: Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/unit-tests/cookie-expected.txt trunk/LayoutTests/inspector/unit-tests/cookie.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Models/Cookie.js trunk/Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/ResourceHeadersContentView.js Diff Modified: trunk/LayoutTests/ChangeLog (239225 => 239226) --- trunk/LayoutTests/ChangeLog 2018-12-14 20:06:38 UTC (rev 239225) +++ trunk/LayoutTests/ChangeLog 2018-12-14 20:41:31 UTC (rev 239226) @@ -1,3 +1,14 @@ +2018-12-14 Matt Baker + +Web Inspector: Cookies view should use model objects instead of raw payload data +https://bugs.webkit.org/show_bug.cgi?id=189533 + + +Reviewed by Joseph Pecoraro and Devin Rousso. + +* inspector/unit-tests/cookie-expected.txt: +* inspector/unit-tests/cookie.html: + 2018-12-14 Simon Fraser REGRESSION (r233268): contents of an animated element inside overflow:hidden disappear Modified: trunk/LayoutTests/inspector/unit-tests/cookie-expected.txt (239225 => 239226) --- trunk/LayoutTests/inspector/unit-tests/cookie-expected.txt 2018-12-14 20:06:38 UTC (rev 239225) +++ trunk/LayoutTests/inspector/unit-tests/cookie-expected.txt 2018-12-14 20:41:31 UTC (rev 239226) @@ -44,7 +44,7 @@ PASS: Empty header should produce null. HEADER: Set-Cookie: name=value PASS: Value should be a WI.Cookie. -PASS: cookie.rawHeader should be the original header text. +PASS: cookie.header should be the original header text. PASS: cookie.type should be WI.Cookie.Type.Response. PASS: cookie.name should be 'name'. PASS: cookie.value should be 'value'. @@ -57,7 +57,7 @@ HEADER: Set-Cookie: name=value; path=/foo PASS: Value should be a WI.Cookie. -PASS: cookie.rawHeader should be the original header text. +PASS: cookie.header should be the original header text. PASS: cookie.type should be WI.Cookie.Type.Response. PASS: cookie.name should be 'name'. PASS: cookie.value should be 'value'. @@ -70,7 +70,7 @@ HEADER: Set-Cookie: name=value; domain=example.com PASS: Value should be a WI.Cookie. -PASS: cookie.rawHeader should be the original header text. +PASS: cookie.header should be the original header text. PASS: cookie.type should be WI.Cookie.Type.Response. PASS: cookie.name should be 'name'. PASS: cookie.value should be 'value'. @@ -83,7 +83,7 @@ HEADER: Set-Cookie: name=value; secure PASS: Value should be a WI.Cookie. -PASS: cookie.rawHeader should be the original header text. +PASS: cookie.header should be the original header text. PASS: cookie.type should be WI.Cookie.Type.Response. PASS: cookie.name should be 'name'. PASS: cookie.value should be 'value'. @@ -96,7 +96,7 @@ HEADER: Set-Cookie: name=value; Secure PASS: Value should be a WI.Cookie. -PASS: cookie.rawHeader should be the original header text. +PASS: cookie.header should be the original header text. PASS: cookie.type should be WI.Cookie.Type.Response. PASS: cookie.name should be 'name'. PASS: cookie.value should be 'value'. @@ -109,7 +109,7 @@ HEADER: Set-Cookie: name=value; HttpOnly PASS: Value should be a WI.Cookie. -PASS: cookie.rawHeader should be the original header text. +PASS: cookie.header should be the original header text. PASS: cookie.type should be WI.Cookie.Type.Response. PASS: cookie.name should be 'name'. PASS: cookie.value should be 'value'. @@ -122,7 +122,7 @@ HEADER: Set-Cookie: name=value; expires=Fri 06-Oct-2017 03:20:27 GMT; Max-Age=3600 PAS
[webkit-changes] [239178] trunk/Source/WebInspectorUI
Title: [239178] trunk/Source/WebInspectorUI Revision 239178 Author mattba...@apple.com Date 2018-12-13 14:29:07 -0800 (Thu, 13 Dec 2018) Log Message Web Inspector: REGRESSION(r238602): Elements: deleting multiple DOM nodes doesn't select the nearest node after deletion https://bugs.webkit.org/show_bug.cgi?id=192116 Reviewed by Devin Rousso. * UserInterface/Controllers/SelectionController.js: (WI.SelectionController.prototype.removeSelectedItems): Finding a new index to select should go through the delegate instead of naively advancing the index. * UserInterface/Views/DOMTreeElement.js: (WI.DOMTreeElement.prototype._populateNodeContextMenu): (WI.DOMTreeElement.prototype.ondelete): Deleted. The menu item for removing the DOM node is now managed by the parent DOMTreeOutline, since its UI and behavior now depend on whether there are multiple elements selected. * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline.prototype.populateContextMenu): (WI.DOMTreeOutline.prototype.ondelete.level): (WI.DOMTreeOutline.prototype.ondelete): Implement `ondelete` to remove selected DOM nodes using the delete and backspace keys. Also used by the DOMTreeOutline's context menu handler. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (239177 => 239178) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-13 20:49:10 UTC (rev 239177) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-13 22:29:07 UTC (rev 239178) @@ -1,5 +1,32 @@ 2018-12-13 Matt Baker +Web Inspector: REGRESSION(r238602): Elements: deleting multiple DOM nodes doesn't select the nearest node after deletion +https://bugs.webkit.org/show_bug.cgi?id=192116 + + +Reviewed by Devin Rousso. + +* UserInterface/Controllers/SelectionController.js: +(WI.SelectionController.prototype.removeSelectedItems): +Finding a new index to select should go through the delegate instead of +naively advancing the index. + +* UserInterface/Views/DOMTreeElement.js: +(WI.DOMTreeElement.prototype._populateNodeContextMenu): +(WI.DOMTreeElement.prototype.ondelete): Deleted. +The menu item for removing the DOM node is now managed by the parent +DOMTreeOutline, since its UI and behavior now depend on whether there +are multiple elements selected. + +* UserInterface/Views/DOMTreeOutline.js: +(WI.DOMTreeOutline.prototype.populateContextMenu): +(WI.DOMTreeOutline.prototype.ondelete.level): +(WI.DOMTreeOutline.prototype.ondelete): +Implement `ondelete` to remove selected DOM nodes using the delete and +backspace keys. Also used by the DOMTreeOutline's context menu handler. + +2018-12-13 Matt Baker + Web Inspector: Table selection becomes corrupted when deleting selected cookies https://bugs.webkit.org/show_bug.cgi?id=192388 Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js (239177 => 239178) --- trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-12-13 20:49:10 UTC (rev 239177) +++ trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-12-13 22:29:07 UTC (rev 239178) @@ -177,19 +177,19 @@ // Try selecting the item following the selection. let lastSelectedIndex = this._selectedIndexes.lastIndex; -let indexToSelect = lastSelectedIndex + 1; -if (indexToSelect === this.numberOfItems) { +let indexToSelect = this._nextSelectableIndex(lastSelectedIndex); +if (isNaN(indexToSelect)) { // If no item exists after the last item in the selection, try selecting // a deselected item (hole) within the selection. let firstSelectedIndex = this._selectedIndexes.firstIndex; if (lastSelectedIndex - firstSelectedIndex > numberOfSelectedItems) { -indexToSelect = this._selectedIndexes.firstIndex + 1; +indexToSelect = this._nextSelectableIndex(firstSelectedIndex); while (this._selectedIndexes.has(indexToSelect)) -indexToSelect++; +indexToSelect = this._nextSelectableIndex(firstSelectedIndex); } else { // If the selection contains no holes, try selecting the item // preceding the selection. -indexToSelect = firstSelectedIndex > 0 ? firstSelectedIndex - 1 : NaN; +indexToSelect = firstSelectedIndex > 0 ? this._previousSelectableIndex(firstSelectedIndex) : NaN; } } Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js (239177 => 239178) ---
[webkit-changes] [239175] trunk
Title: [239175] trunk Revision 239175 Author mattba...@apple.com Date 2018-12-13 12:46:59 -0800 (Thu, 13 Dec 2018) Log Message Web Inspector: Table selection becomes corrupted when deleting selected cookies https://bugs.webkit.org/show_bug.cgi?id=192388 Reviewed by Devin Rousso. Source/WebInspectorUI: * UserInterface/Controllers/SelectionController.js: (WI.SelectionController): (WI.SelectionController.prototype.didRemoveItems): (WI.SelectionController.prototype._updateSelectedItems): (WI.SelectionController.prototype.didRemoveItem): Deleted. Replace `didRemoveItem` with a method taking an IndexSet. Calling the single-index version while iterating over multiple rows in ascending order is unsafe, a detail best left to the SelectionController. * UserInterface/Views/Table.js: (WI.Table.prototype.removeRow): (WI.Table.prototype._removeRows): Notify SelectionController of removed rows. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.insertChild): (WI.TreeOutline.prototype.removeChildAtIndex): Remove the child from the element's `children` after calling `_forgetTreeElement`, which needs to calculate the child's index to pass to the SelectionController. (WI.TreeOutline.prototype.removeChildren): Remove child items during iteration so that `children` doesn't contain detached TreeElements while calling `_forgetTreeElement`. (WI.TreeOutline.prototype._rememberTreeElement): (WI.TreeOutline.prototype._forgetTreeElement): LayoutTests: * inspector/table/table-remove-rows-expected.txt: * inspector/table/table-remove-rows.html: Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/table/table-remove-rows-expected.txt trunk/LayoutTests/inspector/table/table-remove-rows.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/LayoutTests/ChangeLog (239174 => 239175) --- trunk/LayoutTests/ChangeLog 2018-12-13 20:30:01 UTC (rev 239174) +++ trunk/LayoutTests/ChangeLog 2018-12-13 20:46:59 UTC (rev 239175) @@ -1,3 +1,14 @@ +2018-12-13 Matt Baker + +Web Inspector: Table selection becomes corrupted when deleting selected cookies +https://bugs.webkit.org/show_bug.cgi?id=192388 + + +Reviewed by Devin Rousso. + +* inspector/table/table-remove-rows-expected.txt: +* inspector/table/table-remove-rows.html: + 2018-12-13 Brent Fulgham Don't attempt to animate invalid CSS properties Modified: trunk/LayoutTests/inspector/table/table-remove-rows-expected.txt (239174 => 239175) --- trunk/LayoutTests/inspector/table/table-remove-rows-expected.txt 2018-12-13 20:30:01 UTC (rev 239174) +++ trunk/LayoutTests/inspector/table/table-remove-rows-expected.txt 2018-12-13 20:46:59 UTC (rev 239175) @@ -13,6 +13,11 @@ Selection changed to [] before removing row 0. PASS: Should remove row 0. +-- Running test case: Table.RemoveRow.PrecedingSelected +Given a Table with selected rows [1,3], remove row 0. +PASS: Should remove row 0. +PASS: Selected row indexes should be adjusted. + -- Running test case: Table.RemoveSelectedRows.Single.SelectFollowing Given a Table with selected rows [0]: * Row 0 Modified: trunk/LayoutTests/inspector/table/table-remove-rows.html (239174 => 239175) --- trunk/LayoutTests/inspector/table/table-remove-rows.html 2018-12-13 20:30:01 UTC (rev 239174) +++ trunk/LayoutTests/inspector/table/table-remove-rows.html 2018-12-13 20:46:59 UTC (rev 239175) @@ -134,6 +134,24 @@ } }); +suite.addTestCase({ +name: "Table.RemoveRow.PrecedingSelected", +description: "Remove a row preceding the selection, causing the selection to shift up.", +test() { +let testDelegate = new RemoveRowTestDelegate; +let table = InspectorTest.createTableWithDelegate(testDelegate, numberOfRows); +table.allowsMultipleSelection = true; + +table.selectRow(1); +table.selectRow(3, true); +testDelegate.triggerRemoveRow(table, 0); + +InspectorTest.expectShallowEqual(table.selectedRows, [0, 2], "Selected row indexes should be adjusted."); + +return true; +} +}); + function addTestCase({name, description, rowIndexes}) { suite.addTestCase({ name, description, Modified: trunk/Source/WebInspectorUI/ChangeLog (239174 => 239175) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-13 20:30:01 UTC (rev 239174) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-13 20:46:59 UTC (rev 239175) @@ -1,3 +1,38 @@ +2018-12-13 Matt Baker + +Web Inspector: Table selection becomes corrupted when deleting selected cookies +https://bugs.webkit.org/show_bug.cgi?id=192388 + + +Reviewed by Devin Rousso. + +* UserInterface/Controllers/SelectionContro
[webkit-changes] [239066] trunk/Source/WebInspectorUI
Title: [239066] trunk/Source/WebInspectorUI Revision 239066 Author mattba...@apple.com Date 2018-12-10 19:50:25 -0800 (Mon, 10 Dec 2018) Log Message Web Inspector: REGRESSION (r238599): unable to select specific timeline https://bugs.webkit.org/show_bug.cgi?id=192443 Reviewed by Joseph Pecoraro. When determining the trailing horizontal edge for TreeElement mouse events, TreeOutline should not assume that its containing DOM element is only as wide as its element. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.treeElementFromEvent): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (239065 => 239066) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-11 03:46:19 UTC (rev 239065) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-11 03:50:25 UTC (rev 239066) @@ -1,5 +1,20 @@ 2018-12-10 Matt Baker +Web Inspector: REGRESSION (r238599): unable to select specific timeline +https://bugs.webkit.org/show_bug.cgi?id=192443 + + +Reviewed by Joseph Pecoraro. + +When determining the trailing horizontal edge for TreeElement mouse +events, TreeOutline should not assume that its containing DOM element +is only as wide as its element. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype.treeElementFromEvent): + +2018-12-10 Matt Baker + Web Inspector: Move TreeOutlineGroup coordination out of TreeElement https://bugs.webkit.org/show_bug.cgi?id=192487 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (239065 => 239066) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-11 03:46:19 UTC (rev 239065) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-11 03:50:25 UTC (rev 239066) @@ -888,12 +888,18 @@ treeElementFromEvent(event) { -let scrollContainer = this.element.parentElement; - +// We can't take event.pageX to be our X coordinate, since the TreeElement +// could be indented, in which case we can't rely on its DOM element to be +// under the mouse. // We choose this X coordinate based on the knowledge that our list // items extend at least to the trailing edge of the outer container. // In the no-word-wrap mode the outer may be wider than the tree container -// (and partially hidden), in which case we are left to use only its trailing boundary. +// (and partially hidden), in which case we use the edge of its container. + +let scrollContainer = this.element.parentElement; +if (scrollContainer.offsetWidth > this.element.offsetWidth) +scrollContainer = this.element; + // This adjustment is useful in order to find the inner-most tree element that // lines up horizontally with the location of the event. If the mouse event // happened in the space preceding a nested tree element (in the leading indentated ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [239051] trunk/Source/WebInspectorUI
Title: [239051] trunk/Source/WebInspectorUI Revision 239051 Author mattba...@apple.com Date 2018-12-10 14:03:13 -0800 (Mon, 10 Dec 2018) Log Message Web Inspector: Move TreeOutlineGroup coordination out of TreeElement https://bugs.webkit.org/show_bug.cgi?id=192487 Reviewed by Devin Rousso. * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.select): (WI.TreeElement.prototype.deselect): * UserInterface/Views/TreeOutlineGroup.js: (WI.TreeOutlineGroup): (WI.TreeOutlineGroup.prototype.itemAdded): (WI.TreeOutlineGroup.prototype.itemRemoved): (WI.TreeOutlineGroup.prototype._removeConflictingTreeSelections): (WI.TreeOutlineGroup.prototype._treeOutlineSelectionDidChange): (WI.TreeOutlineGroup.groupForTreeOutline): Deleted. (WI.TreeOutlineGroup.prototype.didSelectTreeElement): Deleted. make the group responsible for listening to selection changes from the TreeOutlines it manages, and synchronizing the selection between them. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutlineGroup.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (239050 => 239051) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-10 21:55:56 UTC (rev 239050) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-10 22:03:13 UTC (rev 239051) @@ -1,3 +1,26 @@ +2018-12-10 Matt Baker + +Web Inspector: Move TreeOutlineGroup coordination out of TreeElement +https://bugs.webkit.org/show_bug.cgi?id=192487 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeElement.js: +(WI.TreeElement.prototype.select): +(WI.TreeElement.prototype.deselect): + +* UserInterface/Views/TreeOutlineGroup.js: +(WI.TreeOutlineGroup): +(WI.TreeOutlineGroup.prototype.itemAdded): +(WI.TreeOutlineGroup.prototype.itemRemoved): +(WI.TreeOutlineGroup.prototype._removeConflictingTreeSelections): +(WI.TreeOutlineGroup.prototype._treeOutlineSelectionDidChange): +(WI.TreeOutlineGroup.groupForTreeOutline): Deleted. +(WI.TreeOutlineGroup.prototype.didSelectTreeElement): Deleted. +make the group responsible for listening to selection changes from the +TreeOutlines it manages, and synchronizing the selection between them. + 2018-12-10 Dean Jackson Use text/_javascript_ as recommended by the HTML specification Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js (239050 => 239051) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2018-12-10 21:55:56 UTC (rev 239050) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2018-12-10 22:03:13 UTC (rev 239051) @@ -516,12 +516,6 @@ this.selected = true; treeOutline.selectTreeElementInternal(this, suppressNotification, selectedByUser); - -let treeOutlineGroup = WI.TreeOutlineGroup.groupForTreeOutline(treeOutline); -if (!treeOutlineGroup) -return; - -treeOutlineGroup.didSelectTreeElement(this); } revealAndSelect(omitFocus, selectedByUser, suppressNotification) @@ -535,8 +529,6 @@ if (!this.treeOutline || !this.selected) return false; -console.assert(this.treeOutline.selectedTreeElements.includes(this)); - this.selected = false; this.treeOutline.selectTreeElementInternal(null, suppressNotification); Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutlineGroup.js (239050 => 239051) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutlineGroup.js 2018-12-10 21:55:56 UTC (rev 239050) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutlineGroup.js 2018-12-10 22:03:13 UTC (rev 239051) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2017 Apple Inc. All rights reserved. + * Copyright (C) 2017, 2018 Apple Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -25,13 +25,6 @@ WI.TreeOutlineGroup = class TreeOutlineGroup extends WI.Collection { -// Static - -static groupForTreeOutline(treeOutline) -{ -return treeOutline[WI.TreeOutlineGroup.GroupForTreeOutlineSymbol] || null; -} - // Public objectIsRequiredType(object) @@ -53,36 +46,21 @@ itemAdded(treeOutline) { -console.assert(!treeOutline[WI.TreeOutlineGroup.GroupForTreeOutlineSymbol]); -treeOutline[WI.TreeOutlineGroup.GroupForTreeOutlineSymbol] = this; +if (treeOutline.selectedTreeElement) +this._removeConflictingTreeSelections(treeOutline); -if (treeOutline.selectedTreeElement) -this._removeConflictingTreeSelections(treeOutline.selectedTreeElement); +treeOutline.addEventListener(WI.TreeOutline.Event.SelectionDidChange, this._treeOutlineSelectionDidChange, this); }
[webkit-changes] [238938] trunk/Source/WebInspectorUI
Title: [238938] trunk/Source/WebInspectorUI Revision 238938 Author mattba...@apple.com Date 2018-12-06 12:37:55 -0800 (Thu, 06 Dec 2018) Log Message Web Inspector: REGRESSION(r238602): Elements: collapsing a DOM node with the left arrow doesn't work https://bugs.webkit.org/show_bug.cgi?id=192353 Reviewed by Devin Rousso. * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.deselect): Don't early return when the element is not the selected tree element. This condition no longer holds now that TreeOutline supports multiple selection. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238937 => 238938) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-06 20:07:38 UTC (rev 238937) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-06 20:37:55 UTC (rev 238938) @@ -1,3 +1,16 @@ +2018-12-06 Matt Baker + +Web Inspector: REGRESSION(r238602): Elements: collapsing a DOM node with the left arrow doesn't work +https://bugs.webkit.org/show_bug.cgi?id=192353 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeElement.js: +(WI.TreeElement.prototype.deselect): +Don't early return when the element is not the selected tree element. +This condition no longer holds now that TreeOutline supports multiple selection. + 2018-12-05 Matt Baker Web Inspector: SelectionController should not extend the selection when allowsMultipleSelection is false Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js (238937 => 238938) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2018-12-06 20:07:38 UTC (rev 238937) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2018-12-06 20:37:55 UTC (rev 238938) @@ -532,9 +532,11 @@ deselect(suppressNotification) { -if (!this.treeOutline || this.treeOutline.selectedTreeElement !== this || !this.selected) +if (!this.treeOutline || !this.selected) return false; +console.assert(this.treeOutline.selectedTreeElements.includes(this)); + this.selected = false; this.treeOutline.selectTreeElementInternal(null, suppressNotification); ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [238914] trunk
Title: [238914] trunk Revision 238914 Author mattba...@apple.com Date 2018-12-05 15:50:08 -0800 (Wed, 05 Dec 2018) Log Message Web Inspector: SelectionController should not extend the selection when allowsMultipleSelection is false https://bugs.webkit.org/show_bug.cgi?id=192390 Reviewed by Devin Rousso. Source/WebInspectorUI: * UserInterface/Controllers/SelectionController.js: (WI.SelectionController.prototype.selectItem): LayoutTests: * inspector/table/table-selection-expected.txt: * inspector/table/table-selection.html: Drive-by fix: removed `allowsMultipleSelection` check from test case Table.SelectMultipleRows.ExtendSelection since it is tested in Table.AllowsMultipleSelection. Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/table/table-selection-expected.txt trunk/LayoutTests/inspector/table/table-selection.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js Diff Modified: trunk/LayoutTests/ChangeLog (238913 => 238914) --- trunk/LayoutTests/ChangeLog 2018-12-05 23:25:47 UTC (rev 238913) +++ trunk/LayoutTests/ChangeLog 2018-12-05 23:50:08 UTC (rev 238914) @@ -1,3 +1,16 @@ +2018-12-05 Matt Baker + +Web Inspector: SelectionController should not extend the selection when allowsMultipleSelection is false +https://bugs.webkit.org/show_bug.cgi?id=192390 + + +Reviewed by Devin Rousso. + +* inspector/table/table-selection-expected.txt: +* inspector/table/table-selection.html: +Drive-by fix: removed `allowsMultipleSelection` check from test case +Table.SelectMultipleRows.ExtendSelection since it is tested in Table.AllowsMultipleSelection. + 2018-12-05 Ryosuke Niwa Null pointer crash in DocumentOrderedMap::getElementById via FormAssociatedElement::findAssociatedForm Modified: trunk/LayoutTests/inspector/table/table-selection-expected.txt (238913 => 238914) --- trunk/LayoutTests/inspector/table/table-selection-expected.txt 2018-12-05 23:25:47 UTC (rev 238913) +++ trunk/LayoutTests/inspector/table/table-selection-expected.txt 2018-12-05 23:50:08 UTC (rev 238914) @@ -31,7 +31,6 @@ PASS: allowsMultipleSelection disabled. -- Running test case: Table.SelectMultipleRows.ExtendSelection -PASS: allowsMultipleSelection enabled. Selecting row 0. PASS: Table selection changed. PASS: selectedRow should be 0. @@ -43,6 +42,15 @@ PASS: selectedRow should be 9. PASS: selectedRows should be [0, 1, 9]. +-- Running test case: Table.SelectMultipleRows.ExtendSelection.MultipleSelectionDisabled +Selecting row 0. +PASS: Table selection changed. +PASS: selectedRow should be 0. +Selecting row 1. +PASS: Table selection changed. +PASS: selectedRow should be 1. +PASS: selectedRows should be [1]. + -- Running test case: Table.SelectMultipleRows.SelectTheSameRowTwice.ExtendSelection Selecting row 0. PASS: Table selection changed. Modified: trunk/LayoutTests/inspector/table/table-selection.html (238913 => 238914) --- trunk/LayoutTests/inspector/table/table-selection.html 2018-12-05 23:25:47 UTC (rev 238913) +++ trunk/LayoutTests/inspector/table/table-selection.html 2018-12-05 23:50:08 UTC (rev 238914) @@ -78,6 +78,7 @@ return true; } }); + suite.addTestCase({ name: "Table.SelectMultipleRows.ExtendSelection", description: "Select multiple rows, extending the selection.", @@ -84,7 +85,6 @@ test() { let table = InspectorTest.createTable(); table.allowsMultipleSelection = true; -InspectorTest.expectThat(table.allowsMultipleSelection, "allowsMultipleSelection enabled."); const extendSelection = true; @@ -98,6 +98,23 @@ }); suite.addTestCase({ +name: "Table.SelectMultipleRows.ExtendSelection.MultipleSelectionDisabled", +description: "Attempt to extend the selection when multiple selection is disabled.", +test() { +let table = InspectorTest.createTable(); +table.allowsMultipleSelection = false; + +const extendSelection = true; + +triggerSelectRow(table, 0, extendSelection); +triggerSelectRow(table, 1, extendSelection); +InspectorTest.expectShallowEqual(table.selectedRows, [1], "selectedRows should be [1]."); + +return true; +} +}); + +suite.addTestCase({ name: "Table.SelectMultipleRows.SelectTheSameRowTwice.ExtendSelection", description: "Select an already selected row, and extend the selection.", test() { Modified: trunk/Source/WebInspectorUI/ChangeLog (238913 => 238914) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-05 23:25:47 UTC (rev 238913) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-05 23:50:08 UTC (rev 238914) @@ -1,3 +1,14 @@ +2018-12-05 Matt Baker + +Web Inspector: SelectionController should not extend the selection when allowsMultip
[webkit-changes] [238871] trunk/Source/WebInspectorUI
Title: [238871] trunk/Source/WebInspectorUI Revision 238871 Author mattba...@apple.com Date 2018-12-04 12:07:09 -0800 (Tue, 04 Dec 2018) Log Message Web Inspector: REGRESSION(r238602): Elements: changing selection no longer highlights the selected node https://bugs.webkit.org/show_bug.cgi?id=192354 Reviewed by Joseph Pecoraro. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._treeKeyDown): (WI.TreeOutline.prototype._handleMouseDown): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238870 => 238871) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-04 20:01:00 UTC (rev 238870) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-04 20:07:09 UTC (rev 238871) @@ -1,3 +1,15 @@ +2018-12-04 Matt Baker + +Web Inspector: REGRESSION(r238602): Elements: changing selection no longer highlights the selected node +https://bugs.webkit.org/show_bug.cgi?id=192354 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype._treeKeyDown): +(WI.TreeOutline.prototype._handleMouseDown): + 2018-12-04 Joseph Pecoraro Web Inspector: REGRESSION(r238330): Timeline auto-capture does not work after page transition Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (238870 => 238871) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-04 20:01:00 UTC (rev 238870) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-04 20:07:09 UTC (rev 238871) @@ -609,8 +609,11 @@ } } -if (!handled) +if (!handled) { +this._itemWasSelectedByUser = true; handled = this._selectionController.handleKeyDown(event); +this._itemWasSelectedByUser = false; +} if (nextSelectedElement) { nextSelectedElement.reveal(); @@ -1000,7 +1003,9 @@ if (isNaN(index)) return; +this._itemWasSelectedByUser = true; this._selectionController.handleItemMouseDown(index, event); +this._itemWasSelectedByUser = false; } _indexOfTreeElement(treeElement) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [238859] trunk/Source/WebInspectorUI
Title: [238859] trunk/Source/WebInspectorUI Revision 238859 Author mattba...@apple.com Date 2018-12-04 10:17:16 -0800 (Tue, 04 Dec 2018) Log Message Web Inspector: Elements: $0 is shown for all selected elements https://bugs.webkit.org/show_bug.cgi?id=192119 Reviewed by Devin Rousso. * UserInterface/Views/ContentBrowserTabContentView.js: (WI.ContentBrowserTabContentView.prototype._revealAndSelectRepresentedObject): * UserInterface/Views/DOMTreeContentView.js: (WI.DOMTreeContentView): (WI.DOMTreeContentView.prototype.layout): (WI.DOMTreeContentView.prototype._domTreeSelectionDidChange): Update the selected DOM node using the TreeOutline's selection change event, instead of in `onselect`, which wasn't always called. * UserInterface/Views/DOMTreeElement.js: (WI.DOMTreeElement.prototype.onselect): Deleted. (WI.DOMTreeElement.prototype.ondeselect): Deleted. Eliminate `onselect` and `ondeselect`. TreeOutline clients should use the TreeOutline.Event.SelectedDidChange event instead. * UserInterface/Views/DOMTreeOutline.css: (.tree-outline.dom li.last-selected > span::after): (.tree-outline.dom:focus li.last-selected > span::after): (.tree-outline.dom li.selected > span::after): Deleted. (.tree-outline.dom:focus li.selected > span::after): Deleted. * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline.prototype.updateSelection): Deleted. * UserInterface/Views/DebuggerSidebarPanel.js: (WI.DebuggerSidebarPanel.prototype._handleDebuggerObjectDisplayLocationDidChange): * UserInterface/Views/FolderizedTreeElement.js: (WI.FolderizedTreeElement.prototype._addTreeElement): * UserInterface/Views/NavigationSidebarPanel.js: (WI.NavigationSidebarPanel.prototype.showDefaultContentViewForTreeElement): (WI.NavigationSidebarPanel.prototype._treeElementWasFiltered): (WI.NavigationSidebarPanel): * UserInterface/Views/OpenResourceDialog.js: (WI.OpenResourceDialog.prototype._populateResourceTreeOutline): (WI.OpenResourceDialog.prototype._handleKeydownEvent): * UserInterface/Views/SourceCodeTreeElement.js: (WI.SourceCodeTreeElement.prototype.descendantResourceTreeElementTypeDidChange): * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.select): (WI.TreeElement.prototype.revealAndSelect): (WI.TreeElement.prototype.deselect): Remove `suppressOnDeselect` and rename `suppressOnSelect` to `suppressNotification`. Now that `ondeselect` has been removed `suppressOnDeselect` is no longer meaningful, as TreeOutline generates a single `SelectedDidChange` event when the selected item changes. In the case of `revealAndSelect`, both arguments had the same value. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline): (WI.TreeOutline.prototype.selectionControllerSelectionDidChange): Add a unique class name to the last selected TreeElement to distinguish it from other selected elements. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/ContentBrowserTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/FolderizedTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/NavigationSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/OpenResourceDialog.js trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238858 => 238859) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-04 18:14:28 UTC (rev 238858) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-04 18:17:16 UTC (rev 238859) @@ -1,5 +1,65 @@ 2018-12-04 Matt Baker +Web Inspector: Elements: $0 is shown for all selected elements +https://bugs.webkit.org/show_bug.cgi?id=192119 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/ContentBrowserTabContentView.js: +(WI.ContentBrowserTabContentView.prototype._revealAndSelectRepresentedObject): +* UserInterface/Views/DOMTreeContentView.js: +(WI.DOMTreeContentView): +(WI.DOMTreeContentView.prototype.layout): +(WI.DOMTreeContentView.prototype._domTreeSelectionDidChange): +Update the selected DOM node using the TreeOutline's selection change +event, instead of in `onselect`, which wasn't always called. + +* UserInterface/Views/DOMTreeElement.js: +(WI.DOMTreeElement.prototype.onselect): Deleted. +(WI.DOMTreeElement.prototype.ondeselect): Deleted. +Eliminate `onselect` and `ondeselect`. TreeOutline clients should use +the TreeOutline.Event.SelectedDidChange event instea
[webkit-changes] [238858] trunk/Source/WebInspectorUI
Title: [238858] trunk/Source/WebInspectorUI Revision 238858 Author mattba...@apple.com Date 2018-12-04 10:14:28 -0800 (Tue, 04 Dec 2018) Log Message Web Inspector: Elements: ⌘-A should select all visible nodes https://bugs.webkit.org/show_bug.cgi?id=192120 Reviewed by Devin Rousso. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._treeKeyDown): Remove an early return, allowing `WI.SelectionController` to handle ⌘-A and select all items. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238857 => 238858) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-04 18:12:10 UTC (rev 238857) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-04 18:14:28 UTC (rev 238858) @@ -1,3 +1,16 @@ +2018-12-04 Matt Baker + +Web Inspector: Elements: ⌘-A should select all visible nodes +https://bugs.webkit.org/show_bug.cgi?id=192120 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype._treeKeyDown): +Remove an early return, allowing `WI.SelectionController` to handle ⌘-A +and select all items. + 2018-12-04 Devin Rousso Web Inspector: Audit: tests should support async operations Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (238857 => 238858) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-04 18:12:10 UTC (rev 238857) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-04 18:14:28 UTC (rev 238858) @@ -545,66 +545,67 @@ if (event.target !== this._childrenListNode) return; -if (!this.selectedTreeElement || event.commandOrControlKey) -return; - let isRTL = WI.resolvedLayoutDirection() === WI.LayoutDirection.RTL; +let expandKeyIdentifier = isRTL ? "Left" : "Right"; +let collapseKeyIdentifier = isRTL ? "Right" : "Left"; var handled = false; var nextSelectedElement; -if ((!isRTL && event.keyIdentifier === "Left") || (isRTL && event.keyIdentifier === "Right")) { -if (this.selectedTreeElement.expanded) { -if (event.altKey) -this.selectedTreeElement.collapseRecursively(); -else -this.selectedTreeElement.collapse(); -handled = true; -} else if (this.selectedTreeElement.parent && !this.selectedTreeElement.parent.root) { -handled = true; -if (this.selectedTreeElement.parent.selectable) { -nextSelectedElement = this.selectedTreeElement.parent; -while (nextSelectedElement && !nextSelectedElement.selectable) -nextSelectedElement = nextSelectedElement.parent; -handled = nextSelectedElement ? true : false; -} else if (this.selectedTreeElement.parent) -this.selectedTreeElement.parent.collapse(); -} -} else if ((!isRTL && event.keyIdentifier === "Right") || (isRTL && event.keyIdentifier === "Left")) { -if (!this.selectedTreeElement.revealed()) { -this.selectedTreeElement.reveal(); -handled = true; -} else if (this.selectedTreeElement.hasChildren) { -handled = true; +if (this.selectedTreeElement) { +if (event.keyIdentifier === collapseKeyIdentifier) { if (this.selectedTreeElement.expanded) { -nextSelectedElement = this.selectedTreeElement.children[0]; -while (nextSelectedElement && !nextSelectedElement.selectable) -nextSelectedElement = nextSelectedElement.nextSibling; -handled = nextSelectedElement ? true : false; -} else { if (event.altKey) -this.selectedTreeElement.expandRecursively(); +this.selectedTreeElement.collapseRecursively(); else -this.selectedTreeElement.expand(); +this.selectedTreeElement.collapse(); +handled = true; +} else if (this.selectedTreeElement.parent && !this.selectedTreeElement.parent.root) { +handled = true; +if (this.selectedTreeElement.parent.selectable) { +nextSelectedElement = this.selectedTreeElement.parent; +while (nextSelectedElement && !nextSelectedElement.selectable) +nextSelectedElement = nextSelectedElement.parent; +handled = nextSelectedElement ? true : false; +} else if (this.selectedTreeElement.parent) +this.selectedTreeElem
[webkit-changes] [238825] trunk/Source/WebInspectorUI
Title: [238825] trunk/Source/WebInspectorUI Revision 238825 Author mattba...@apple.com Date 2018-12-03 15:16:25 -0800 (Mon, 03 Dec 2018) Log Message Web Inspector: REGRESSION(r238599): Multiple Selection: restoring selection when opening WebInspector puts the TreeElement into a permanent selected state https://bugs.webkit.org/show_bug.cgi?id=192091 Reviewed by Devin Rousso. * UserInterface/Controllers/SelectionController.js: (WI.SelectionController.prototype.didInsertItem): Fix a bug where selected indexes were overwritten by the inserted index. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline): (WI.TreeOutline.prototype.insertChild): Update the SelectionController with the newly inserted index before attaching the TreeElement. Attaching the TreeElement can cause it to become selected, which would add the index to the SelectionController, only to have it immediately incremented by the call to `didInsertItem`. Additionally, change `insertionIndex` to be the index of the inserted item instead of the inserted item's previous sibling. (WI.TreeOutline.prototype._rememberTreeElement): (WI.TreeOutline.prototype._forgetTreeElement): (WI.TreeOutline.prototype._indexOfTreeElement.previousElement): Deleted. Eliminate TreeElement index caching, which could become stale and cause the wrong index to be calculated. Additionally, instead of walking up the parent chain to determine the index, start at the root and use existing method `traverseNextTreeElement`. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238824 => 238825) --- trunk/Source/WebInspectorUI/ChangeLog 2018-12-03 22:52:14 UTC (rev 238824) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-12-03 23:16:25 UTC (rev 238825) @@ -1,3 +1,33 @@ +2018-12-03 Matt Baker + +Web Inspector: REGRESSION(r238599): Multiple Selection: restoring selection when opening WebInspector puts the TreeElement into a permanent selected state +https://bugs.webkit.org/show_bug.cgi?id=192091 + + +Reviewed by Devin Rousso. + +* UserInterface/Controllers/SelectionController.js: +(WI.SelectionController.prototype.didInsertItem): +Fix a bug where selected indexes were overwritten by the inserted index. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline): +(WI.TreeOutline.prototype.insertChild): +Update the SelectionController with the newly inserted index before +attaching the TreeElement. Attaching the TreeElement can cause it to +become selected, which would add the index to the SelectionController, +only to have it immediately incremented by the call to `didInsertItem`. +Additionally, change `insertionIndex` to be the index of the inserted +item instead of the inserted item's previous sibling. + +(WI.TreeOutline.prototype._rememberTreeElement): +(WI.TreeOutline.prototype._forgetTreeElement): +(WI.TreeOutline.prototype._indexOfTreeElement.previousElement): Deleted. +Eliminate TreeElement index caching, which could become stale and cause +the wrong index to be calculated. Additionally, instead of walking up the +parent chain to determine the index, start at the root and use existing +method `traverseNextTreeElement`. + 2018-12-03 Devin Rousso Web Inspector: Audit: test tree elements should start out collapsed Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js (238824 => 238825) --- trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-12-03 22:52:14 UTC (rev 238824) +++ trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-12-03 23:16:25 UTC (rev 238825) @@ -203,8 +203,8 @@ { let current = this._selectedIndexes.lastIndex; while (current >= index) { -this._selectedIndexes.delete(index); -this._selectedIndexes.add(index + 1); +this._selectedIndexes.delete(current); +this._selectedIndexes.add(current + 1); current = this._selectedIndexes.indexLessThan(current); } Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (238824 => 238825) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-03 22:52:14 UTC (rev 238824) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-12-03 23:16:25 UTC (rev 238825) @@ -56,7 +56,6 @@ this._cachedNumberOfDescendents = 0; this._selectionController = new WI.SelectionController(this); -this._treeElementIndexCache = new Map; this._itemWasSelectedByUser = false; this._processingSelectionChange = false; @@ -295,6 +294,12 @@ if (child.hasChild
[webkit-changes] [238757] trunk/Source/WebInspectorUI
Title: [238757] trunk/Source/WebInspectorUI Revision 238757 Author mattba...@apple.com Date 2018-11-30 14:40:52 -0800 (Fri, 30 Nov 2018) Log Message Web Inspector: REGRESSION(r238599): Multiple Selection: selecting a breakpoint will change the selection to it's parent on the first click https://bugs.webkit.org/show_bug.cgi?id=192093 Reviewed by Devin Rousso. * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.select): TreeElement shouldn't manage the TreeOutline's selection barrier. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline): (WI.TreeOutline.prototype.get processingSelectionChange): (WI.TreeOutline.prototype.selectionControllerSelectionDidChange): (WI.TreeOutline.prototype.selectTreeElementInternal): The selection re-entry barrier `processingSelectionChange` should be managed internally by TreeOutline, and exposed as a read-only property. Fix a bug where the barrier was cleared before dispatching the change notification, which can cause re-entry as a side effect. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238756 => 238757) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-30 22:37:22 UTC (rev 238756) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-30 22:40:52 UTC (rev 238757) @@ -1,3 +1,25 @@ +2018-11-30 Matt Baker + +Web Inspector: REGRESSION(r238599): Multiple Selection: selecting a breakpoint will change the selection to it's parent on the first click +https://bugs.webkit.org/show_bug.cgi?id=192093 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeElement.js: +(WI.TreeElement.prototype.select): +TreeElement shouldn't manage the TreeOutline's selection barrier. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline): +(WI.TreeOutline.prototype.get processingSelectionChange): +(WI.TreeOutline.prototype.selectionControllerSelectionDidChange): +(WI.TreeOutline.prototype.selectTreeElementInternal): +The selection re-entry barrier `processingSelectionChange` should be +managed internally by TreeOutline, and exposed as a read-only property. +Fix a bug where the barrier was cleared before dispatching the change +notification, which can cause re-entry as a side effect. + 2018-11-30 Devin Rousso Web Inspector: Settings: reload button needs horizontal spacing Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js (238756 => 238757) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2018-11-30 22:37:22 UTC (rev 238756) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js 2018-11-30 22:40:52 UTC (rev 238757) @@ -514,8 +514,6 @@ if (!treeOutline) return; -treeOutline.processingSelectionChange = true; - this.selected = true; treeOutline.selectTreeElementInternal(this, suppressOnSelect, selectedByUser); @@ -522,8 +520,6 @@ if (!suppressOnSelect && this.onselect) this.onselect(this, selectedByUser); -treeOutline.processingSelectionChange = false; - let treeOutlineGroup = WI.TreeOutlineGroup.groupForTreeOutline(treeOutline); if (!treeOutlineGroup) return; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (238756 => 238757) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-11-30 22:37:22 UTC (rev 238756) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-11-30 22:40:52 UTC (rev 238757) @@ -59,7 +59,7 @@ this._treeElementIndexCache = new Map; this._itemWasSelectedByUser = false; -this._processingSelectionControllerSelectionDidChange = false; +this._processingSelectionChange = false; this._suppressNextSelectionDidChangeEvent = false; this._virtualizedVisibleTreeElements = null; @@ -132,6 +132,8 @@ return []; } +get processingSelectionChange() { return this._processingSelectionChange; } + get hidden() { return this._hidden; @@ -788,7 +790,7 @@ selectionControllerSelectionDidChange(controller, deselectedItems, selectedItems) { -this._processingSelectionControllerSelectionDidChange = true; +this._processingSelectionChange = true; for (let index of deselectedItems) { let treeElement = this._treeElementAtIndex(index); @@ -810,9 +812,9 @@ } } -this._processingSelectionControllerSelectionDidChange = false; +this._dispatchSelectionDidChangeEvent(); -this._dispatchSelectionDidChangeEvent(); +this._processingSelectionChange = false; } selectionControllerNextSelectableIndex(controller, index) @@ -855,7
[webkit-changes] [238711] trunk/Source/WebInspectorUI
Title: [238711] trunk/Source/WebInspectorUI Revision 238711 Author mattba...@apple.com Date 2018-11-29 16:39:02 -0800 (Thu, 29 Nov 2018) Log Message Web Inspector: RTL: disclosure triangles should be flipped and aligned right https://bugs.webkit.org/show_bug.cgi?id=192089 Reviewed by Devin Rousso. * UserInterface/Views/ComputedStyleSection.css: (.computed-style-section .computed-property-item .disclosure-button): (body[dir=rtl] .computed-style-section .computed-property-item .disclosure-button): * UserInterface/Views/ConsoleMessageView.css: (.console-message.expandable .console-top-level-message::before): (body[dir=rtl] .console-message.expandable .console-top-level-message::before): * UserInterface/Views/ErrorObjectView.css: (.error-object > .formatted-error::before): (body[dir=rtl] .error-object > .formatted-error::before): (.error-object .content): * UserInterface/Views/LogContentView.css: (.console-group-title::before): (body[dir=ltr] .console-group-title::before): (body[dir=rtl] .console-group-title::before): * UserInterface/Views/ObjectTreeView.css: (body[dir=rtl] .object-tree > :matches(.title, .object-preview)::before): * UserInterface/Views/TypeTreeElement.css: (body[dir=rtl] .item.type-tree-element.parent > .disclosure-button): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/ComputedStyleSection.css trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.css trunk/Source/WebInspectorUI/UserInterface/Views/ErrorObjectView.css trunk/Source/WebInspectorUI/UserInterface/Views/LogContentView.css trunk/Source/WebInspectorUI/UserInterface/Views/ObjectTreeView.css trunk/Source/WebInspectorUI/UserInterface/Views/TypeTreeElement.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238710 => 238711) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-30 00:38:29 UTC (rev 238710) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-30 00:39:02 UTC (rev 238711) @@ -1,3 +1,35 @@ +2018-11-29 Matt Baker + +Web Inspector: RTL: disclosure triangles should be flipped and aligned right +https://bugs.webkit.org/show_bug.cgi?id=192089 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/ComputedStyleSection.css: +(.computed-style-section .computed-property-item .disclosure-button): +(body[dir=rtl] .computed-style-section .computed-property-item .disclosure-button): + +* UserInterface/Views/ConsoleMessageView.css: +(.console-message.expandable .console-top-level-message::before): +(body[dir=rtl] .console-message.expandable .console-top-level-message::before): + +* UserInterface/Views/ErrorObjectView.css: +(.error-object > .formatted-error::before): +(body[dir=rtl] .error-object > .formatted-error::before): +(.error-object .content): + +* UserInterface/Views/LogContentView.css: +(.console-group-title::before): +(body[dir=ltr] .console-group-title::before): +(body[dir=rtl] .console-group-title::before): + +* UserInterface/Views/ObjectTreeView.css: +(body[dir=rtl] .object-tree > :matches(.title, .object-preview)::before): + +* UserInterface/Views/TypeTreeElement.css: +(body[dir=rtl] .item.type-tree-element.parent > .disclosure-button): + 2018-11-28 Dean Jackson [ES Modules] Allow .mjs content when loaded from file:// Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ComputedStyleSection.css (238710 => 238711) --- trunk/Source/WebInspectorUI/UserInterface/Views/ComputedStyleSection.css 2018-11-30 00:38:29 UTC (rev 238710) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ComputedStyleSection.css 2018-11-30 00:39:02 UTC (rev 238711) @@ -54,7 +54,7 @@ display: inline-block; width: var(--disclosure-button-size); height: var(--disclosure-button-size); -margin-left: calc(-1 * var(--disclosure-button-size)); +-webkit-margin-start: calc(-1 * var(--disclosure-button-size)); border: 0; background-color: transparent; background-image: url(../Images/DisclosureTriangles.svg#closed-normal); @@ -64,6 +64,10 @@ -webkit-appearance: none; } +body[dir=rtl] .computed-style-section .computed-property-item .disclosure-button { +transform: scaleX(-1); +} + .computed-style-section .computed-property-item .property-traces { display: none; width: 100%; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.css (238710 => 238711) --- trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.css 2018-11-30 00:38:29 UTC (rev 238710) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleMessageView.css 2018-11-30 00:39:02 UTC (rev 238711) @@ -76,7 +76,7 @@ vertical-align: baseline; margin-bottom: -2px; -margin-right: 2px; +-webkit-margin-end: 2px; width: 13px; height: 13px; @@ -89,6 +89,10 @@ content: ""; } +body[dir=rt
[webkit-changes] [238671] trunk/Source/WebInspectorUI
Title: [238671] trunk/Source/WebInspectorUI Revision 238671 Author mattba...@apple.com Date 2018-11-29 09:50:21 -0800 (Thu, 29 Nov 2018) Log Message Web Inspector: Elements: selecting more than one DOM node causes the scope highlight to contrast https://bugs.webkit.org/show_bug.cgi?id=192118 Reviewed by Devin Rousso. Use an alpha blended border for the "selected" DOM scope highlight, matching the "hovered" scope highlight. * UserInterface/Views/DOMTreeOutline.css: (.tree-outline.dom li.selected + ol.children.expanded): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238670 => 238671) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-29 16:41:23 UTC (rev 238670) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-29 17:50:21 UTC (rev 238671) @@ -1,3 +1,17 @@ +2018-11-29 Matt Baker + +Web Inspector: Elements: selecting more than one DOM node causes the scope highlight to contrast +https://bugs.webkit.org/show_bug.cgi?id=192118 + + +Reviewed by Devin Rousso. + +Use an alpha blended border for the "selected" DOM scope highlight, +matching the "hovered" scope highlight. + +* UserInterface/Views/DOMTreeOutline.css: +(.tree-outline.dom li.selected + ol.children.expanded): + 2018-11-28 Joseph Pecoraro Web Inspector: REGRESSION(?): all "Show *" develop menu items cause the page to crash Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css (238670 => 238671) --- trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css 2018-11-29 16:41:23 UTC (rev 238670) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.css 2018-11-29 17:50:21 UTC (rev 238671) @@ -127,7 +127,7 @@ } .tree-outline.dom li.selected + ol.children.expanded { -border-color: hsl(0, 0%, 83%); +border-color: hsl(0, 0%, 65%, 0.5); } .tree-outline.dom li { @@ -325,10 +325,6 @@ background-color: var(--selected-background-color); } -.tree-outline.dom li.selected + ol.children.expanded { -border-color: hsl(0, 0%, 27%); -} - .tree-outline.dom .shadow { color: var(--text-color); } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [238626] trunk/Source/WebInspectorUI
Title: [238626] trunk/Source/WebInspectorUI Revision 238626 Author mattba...@apple.com Date 2018-11-28 11:47:01 -0800 (Wed, 28 Nov 2018) Log Message Web Inspector: Remove unused DataGrid and TreeOutline code https://bugs.webkit.org/show_bug.cgi?id=191622 Reviewed by Devin Rousso. * UserInterface/Views/CanvasDetailsSidebarPanel.js: (WI.CanvasDetailsSidebarPanel.prototype.initialLayout): * UserInterface/Views/DOMTreeElement.js: (WI.DOMTreeElement.prototype.insertChildElement): * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline): (WI.DOMTreeOutline.prototype.update): * UserInterface/Views/DataGrid.js: (WI.DataGrid.prototype.removeChildrenRecursive): Deleted. * UserInterface/Views/DataGridNode.js: (WI.DataGridNode.prototype.removeChildren): (WI.DataGridNode.prototype.removeChildrenRecursive): Deleted. * UserInterface/Views/ErrorObjectView.css: (.error-object:not(.expanded) .content): (.error-object .content): (.error-object:not(.expanded) .tree-outline): Deleted. (.error-object .tree-outline): Deleted. * UserInterface/Views/ErrorObjectView.js: (WI.ErrorObjectView): (WI.ErrorObjectView.prototype.get treeOutline): Deleted. Use a simple container since TreeOutline features aren't used, and remove unused property `treeOutline`. * UserInterface/Views/RecordingTraceDetailsSidebarPanel.js: (WI.RecordingTraceDetailsSidebarPanel): * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.removeChildren): (WI.TreeElement.prototype.removeChildrenRecursive): Deleted. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline): (WI.TreeOutline.prototype.removeChildrenRecursive): Deleted. (WI.TreeOutline.prototype.reattachIfIndexChanged): Deleted. Removed `element` parameter now that the only use case has been removed. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CanvasDetailsSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js trunk/Source/WebInspectorUI/UserInterface/Views/DataGrid.js trunk/Source/WebInspectorUI/UserInterface/Views/DataGridNode.js trunk/Source/WebInspectorUI/UserInterface/Views/ErrorObjectView.css trunk/Source/WebInspectorUI/UserInterface/Views/ErrorObjectView.js trunk/Source/WebInspectorUI/UserInterface/Views/RecordingTraceDetailsSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238625 => 238626) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-28 19:05:21 UTC (rev 238625) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-28 19:47:01 UTC (rev 238626) @@ -1,3 +1,53 @@ +2018-11-28 Matt Baker + +Web Inspector: Remove unused DataGrid and TreeOutline code +https://bugs.webkit.org/show_bug.cgi?id=191622 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/CanvasDetailsSidebarPanel.js: +(WI.CanvasDetailsSidebarPanel.prototype.initialLayout): + +* UserInterface/Views/DOMTreeElement.js: +(WI.DOMTreeElement.prototype.insertChildElement): + +* UserInterface/Views/DOMTreeOutline.js: +(WI.DOMTreeOutline): +(WI.DOMTreeOutline.prototype.update): + +* UserInterface/Views/DataGrid.js: +(WI.DataGrid.prototype.removeChildrenRecursive): Deleted. + +* UserInterface/Views/DataGridNode.js: +(WI.DataGridNode.prototype.removeChildren): +(WI.DataGridNode.prototype.removeChildrenRecursive): Deleted. + +* UserInterface/Views/ErrorObjectView.css: +(.error-object:not(.expanded) .content): +(.error-object .content): +(.error-object:not(.expanded) .tree-outline): Deleted. +(.error-object .tree-outline): Deleted. + +* UserInterface/Views/ErrorObjectView.js: +(WI.ErrorObjectView): +(WI.ErrorObjectView.prototype.get treeOutline): Deleted. +Use a simple container since TreeOutline features aren't used, +and remove unused property `treeOutline`. + +* UserInterface/Views/RecordingTraceDetailsSidebarPanel.js: +(WI.RecordingTraceDetailsSidebarPanel): + +* UserInterface/Views/TreeElement.js: +(WI.TreeElement.prototype.removeChildren): +(WI.TreeElement.prototype.removeChildrenRecursive): Deleted. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline): +(WI.TreeOutline.prototype.removeChildrenRecursive): Deleted. +(WI.TreeOutline.prototype.reattachIfIndexChanged): Deleted. +Removed `element` parameter now that the only use case has been removed. + 2018-11-27 Matt Baker Web Inspector: Elements tab should allow selecting/deleting multiple DOM nodes Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CanvasDetailsSidebarPanel.js (238625 => 238626) --- trunk/Source/WebInspectorUI/UserInterface/Views/Can
[webkit-changes] [238602] trunk/Source/WebInspectorUI
Title: [238602] trunk/Source/WebInspectorUI Revision 238602 Author mattba...@apple.com Date 2018-11-27 22:49:34 -0800 (Tue, 27 Nov 2018) Log Message Web Inspector: Elements tab should allow selecting/deleting multiple DOM nodes https://bugs.webkit.org/show_bug.cgi?id=192059 Reviewed by Devin Rousso. Enable multiple DOM node selection in the DOMTreeContentView. * UserInterface/Controllers/SelectionController.js: (WI.SelectionController): (WI.SelectionController.prototype.get allowsEmptySelection): (WI.SelectionController.prototype.set allowsEmptySelection): Allow clients to control whether the last selected item can be deselected. (WI.SelectionController.prototype.deselectItem): (WI.SelectionController.prototype.didInsertItem): Rewritten to prevent infinite loop. (WI.SelectionController.prototype.didRemoveItem): (WI.SelectionController.prototype._updateSelectedItems): (WI.SelectionController.prototype._adjustIndexesAfter): Deleted. * UserInterface/Views/DOMTreeContentView.js: (WI.DOMTreeContentView): * UserInterface/Views/DOMTreeElement.js: (WI.DOMTreeElement.prototype.updateSelectionArea): * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline.prototype.updateSelection): Updating the selection area DOM element should not assume that only one TreeElement is selected at a time. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype.get allowsEmptySelection): (WI.TreeOutline.prototype.set allowsEmptySelection): (WI.TreeOutline.prototype.set selectedTreeElement): (WI.TreeOutline.prototype.get selectedTreeElements): (WI.TreeOutline.prototype._treeKeyDown): * UserInterface/Views/TreeOutlineGroup.js: (WI.TreeOutlineGroup): (WI.TreeOutlineGroup.prototype._removeConflictingTreeSelections): Eliminate use of `TreeElement.prototype.deselect`. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutlineGroup.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238601 => 238602) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-28 04:48:30 UTC (rev 238601) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-28 06:49:34 UTC (rev 238602) @@ -1,5 +1,49 @@ 2018-11-27 Matt Baker +Web Inspector: Elements tab should allow selecting/deleting multiple DOM nodes +https://bugs.webkit.org/show_bug.cgi?id=192059 + + +Reviewed by Devin Rousso. + +Enable multiple DOM node selection in the DOMTreeContentView. + +* UserInterface/Controllers/SelectionController.js: +(WI.SelectionController): +(WI.SelectionController.prototype.get allowsEmptySelection): +(WI.SelectionController.prototype.set allowsEmptySelection): +Allow clients to control whether the last selected item can be deselected. +(WI.SelectionController.prototype.deselectItem): +(WI.SelectionController.prototype.didInsertItem): +Rewritten to prevent infinite loop. +(WI.SelectionController.prototype.didRemoveItem): +(WI.SelectionController.prototype._updateSelectedItems): +(WI.SelectionController.prototype._adjustIndexesAfter): Deleted. + +* UserInterface/Views/DOMTreeContentView.js: +(WI.DOMTreeContentView): + +* UserInterface/Views/DOMTreeElement.js: +(WI.DOMTreeElement.prototype.updateSelectionArea): +* UserInterface/Views/DOMTreeOutline.js: +(WI.DOMTreeOutline.prototype.updateSelection): +Updating the selection area DOM element should not assume that only one +TreeElement is selected at a time. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype.get allowsEmptySelection): +(WI.TreeOutline.prototype.set allowsEmptySelection): +(WI.TreeOutline.prototype.set selectedTreeElement): +(WI.TreeOutline.prototype.get selectedTreeElements): +(WI.TreeOutline.prototype._treeKeyDown): + +* UserInterface/Views/TreeOutlineGroup.js: +(WI.TreeOutlineGroup): +(WI.TreeOutlineGroup.prototype._removeConflictingTreeSelections): +Eliminate use of `TreeElement.prototype.deselect`. + +2018-11-27 Matt Baker + Web Inspector: TreeOutline should re-use multiple-selection logic from Table https://bugs.webkit.org/show_bug.cgi?id=191483 Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js (238601 => 238602) --- trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-11-28 04:48:30 UTC (rev 238601) +++ trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js 2018-11-28 06:49:34 UTC
[webkit-changes] [238599] trunk/Source/WebInspectorUI
Title: [238599] trunk/Source/WebInspectorUI Revision 238599 Author mattba...@apple.com Date 2018-11-27 18:55:42 -0800 (Tue, 27 Nov 2018) Log Message Web Inspector: TreeOutline should re-use multiple-selection logic from Table https://bugs.webkit.org/show_bug.cgi?id=191483 Reviewed by Devin Rousso. Update TreeOutline to use SelectionController. Adopting SelectionController in TreeOutline is not as straightforward as it was in Table. Selected items are tracked by index, and TreeElement lacks an explicit index. As a consequence TreeElement indexes are calcualted as needed and cached. The cache is cleared whenever an element is added or removed. * UserInterface/Controllers/SelectionController.js: (WI.SelectionController.prototype.didInsertItem): (WI.SelectionController.prototype.didRemoveItem): (WI.SelectionController.prototype.handleKeyDown): Drive-by syntax error fix. (WI.SelectionController.prototype._adjustIndexesAfter): (WI.SelectionController): * UserInterface/Views/DOMTreeElement.js: (WI.DOMTreeElement.prototype.canSelectOnMouseDown): (WI.DOMTreeElement.prototype.selectOnMouseDown): Deleted. * UserInterface/Views/DOMTreeOutline.js: (WI.DOMTreeOutline.prototype._onmousedown): Item selection is now handled by SelectionController. * UserInterface/Views/ShaderProgramTreeElement.js: (WI.ShaderProgramTreeElement.prototype.canSelectOnMouseDown): (WI.ShaderProgramTreeElement.prototype.selectOnMouseDown): Deleted. * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.canSelectOnMouseDown): (WI.TreeElement.prototype._attach): (WI.TreeElement.prototype.select): (WI.TreeElement.prototype.deselect): Route item selection through the parent TreeOutline, in order to go though the TreeOutline's SelectionController. (WI.TreeElement.treeElementMouseDown): Deleted. Moved handler to TreeOutline, which owns the SelectionController that needs to respond to mouse events. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline): (WI.TreeOutline.prototype.get allowsMultipleSelection): (WI.TreeOutline.prototype.set allowsMultipleSelection): (WI.TreeOutline.prototype.get selectedTreeElement): (WI.TreeOutline.prototype.set selectedTreeElement): (WI.TreeOutline.prototype.insertChild): (WI.TreeOutline.prototype.removeChildAtIndex): (WI.TreeOutline.prototype._rememberTreeElement): (WI.TreeOutline.prototype._forgetTreeElement): (WI.TreeOutline.prototype._treeKeyDown): (WI.TreeOutline.prototype.selectionControllerNumberOfItems): (WI.TreeOutline.prototype.selectionControllerSelectionDidChange): (WI.TreeOutline.prototype.selectionControllerNextSelectableIndex): (WI.TreeOutline.prototype.selectionControllerPreviousSelectableIndex): (WI.TreeOutline.prototype.selectTreeElementInternal): (WI.TreeOutline._generateStyleRulesIfNeeded._indexOfTreeElement.previousElement): (WI.TreeOutline._generateStyleRulesIfNeeded): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/DOMTreeOutline.js trunk/Source/WebInspectorUI/UserInterface/Views/ShaderProgramTreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238598 => 238599) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-28 02:16:25 UTC (rev 238598) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-28 02:55:42 UTC (rev 238599) @@ -1,3 +1,68 @@ +2018-11-27 Matt Baker + +Web Inspector: TreeOutline should re-use multiple-selection logic from Table +https://bugs.webkit.org/show_bug.cgi?id=191483 + + +Reviewed by Devin Rousso. + +Update TreeOutline to use SelectionController. Adopting SelectionController +in TreeOutline is not as straightforward as it was in Table. Selected items +are tracked by index, and TreeElement lacks an explicit index. As a consequence +TreeElement indexes are calcualted as needed and cached. The cache is cleared +whenever an element is added or removed. + +* UserInterface/Controllers/SelectionController.js: +(WI.SelectionController.prototype.didInsertItem): +(WI.SelectionController.prototype.didRemoveItem): +(WI.SelectionController.prototype.handleKeyDown): +Drive-by syntax error fix. +(WI.SelectionController.prototype._adjustIndexesAfter): +(WI.SelectionController): + +* UserInterface/Views/DOMTreeElement.js: +(WI.DOMTreeElement.prototype.canSelectOnMouseDown): +(WI.DOMTreeElement.prototype.selectOnMouseDown): Deleted. + +* UserInterface/Views/DOMTreeOutline.js: +(WI.DOMTreeOutline.prototype._onmousedown): +Item selection is now handled by SelectionController. + +* UserInterface/Views/ShaderProgramTreeElement.js: +(WI.ShaderProg
[webkit-changes] [238569] trunk/Source/WebInspectorUI
Title: [238569] trunk/Source/WebInspectorUI Revision 238569 Author mattba...@apple.com Date 2018-11-27 13:06:52 -0800 (Tue, 27 Nov 2018) Log Message Web Inspector: Cookies table needs copy keyboard shortcut and context menu support https://bugs.webkit.org/show_bug.cgi?id=191482 Reviewed by Joseph Pecoraro. * UserInterface/Views/CookieStorageContentView.js: (WI.CookieStorageContentView.prototype.handleCopyEvent): (WI.CookieStorageContentView.prototype.tableCellContextMenuClicked): As with Delete, if the target row is selected, all selected rows are copied. Otherwise only the target row is copied. This distinction will be surfaced in the UI in https://webkit.org/b/191095. (WI.CookieStorageContentView.prototype.tablePopulateCell): (WI.CookieStorageContentView.prototype._cookiesAtIndexes): (WI.CookieStorageContentView.prototype._formatCookiesAsText): (WI.CookieStorageContentView.prototype._formatCookiePropertyForColumn): (WI.CookieStorageContentView): Break Cookie property formatting into a helper method, which is used for formatting Table cells and creating plain text for the clipboard. * UserInterface/Views/Table.js: (WI.Table.prototype.get columns): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238568 => 238569) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-27 21:03:29 UTC (rev 238568) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-27 21:06:52 UTC (rev 238569) @@ -1,5 +1,31 @@ 2018-11-27 Matt Baker +Web Inspector: Cookies table needs copy keyboard shortcut and context menu support +https://bugs.webkit.org/show_bug.cgi?id=191482 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/CookieStorageContentView.js: +(WI.CookieStorageContentView.prototype.handleCopyEvent): +(WI.CookieStorageContentView.prototype.tableCellContextMenuClicked): +As with Delete, if the target row is selected, all selected rows are copied. +Otherwise only the target row is copied. This distinction will be surfaced +in the UI in https://webkit.org/b/191095. + +(WI.CookieStorageContentView.prototype.tablePopulateCell): +(WI.CookieStorageContentView.prototype._cookiesAtIndexes): +(WI.CookieStorageContentView.prototype._formatCookiesAsText): +(WI.CookieStorageContentView.prototype._formatCookiePropertyForColumn): +(WI.CookieStorageContentView): +Break Cookie property formatting into a helper method, which is used for +formatting Table cells and creating plain text for the clipboard. + +* UserInterface/Views/Table.js: +(WI.Table.prototype.get columns): + +2018-11-27 Matt Baker + Web Inspector: Table selection should be handled by a SelectionController https://bugs.webkit.org/show_bug.cgi?id=191977 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js (238568 => 238569) --- trunk/Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js 2018-11-27 21:03:29 UTC (rev 238568) +++ trunk/Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js 2018-11-27 21:06:52 UTC (rev 238569) @@ -59,6 +59,20 @@ return [this._table.scrollContainer]; } +handleCopyEvent(event) +{ +if (!this._table || !this._table.selectedRows.length) +return; + +let cookies = this._cookiesAtIndexes(this._table.selectedRows); +if (!cookies.length) +return; + +event.clipboardData.setData("text/plain", this._formatCookiesAsText(cookies)); +event.stopPropagation(); +event.preventDefault(); +} + // Table dataSource tableNumberOfRows(table) @@ -84,6 +98,17 @@ let contextMenu = WI.ContextMenu.createFromEvent(event); contextMenu.appendSeparator(); +contextMenu.appendItem(WI.UIString("Copy"), () => { +let rowIndexes; +if (table.isRowSelected(rowIndex)) +rowIndexes = table.selectedRows; +else +rowIndexes = [rowIndex]; + +let cookies = this._cookiesAtIndexes(rowIndexes); +InspectorFrontendHost.copyText(this._formatCookiesAsText(cookies)); +}); + contextMenu.appendItem(WI.UIString("Delete"), () => { if (table.isRowSelected(rowIndex)) table.removeSelectedRows(); @@ -117,39 +142,7 @@ tablePopulateCell(table, cell, column, rowIndex) { let cookie = this._cookies[rowIndex]; - -const checkmark = "\u2713"; - -switch (column.identifier) { -case "name": -cell.textContent = cookie.name; -break; -case "value": -cell.textContent = cookie.value; -break; -c
[webkit-changes] [238563] trunk/Source/WebInspectorUI
Title: [238563] trunk/Source/WebInspectorUI Revision 238563 Author mattba...@apple.com Date 2018-11-27 11:41:17 -0800 (Tue, 27 Nov 2018) Log Message Web Inspector: Table selection should be handled by a SelectionController https://bugs.webkit.org/show_bug.cgi?id=191977 Reviewed by Devin Rousso. Add a SelectionController class, which manages an IndexSet of selected items, and provides operations for adding and removing items from the selection. Complex behaviors such as shift-clicking to select a range of items, and updating the selection using the keyboard, are forwarded to the controller using special-purpose methods that accept DOM Event objects. * UserInterface/Base/Utilities.js: * UserInterface/Controllers/SelectionController.js: Added. (WI.SelectionController): (WI.SelectionController.prototype.get delegate): (WI.SelectionController.prototype.get lastSelectedItem): (WI.SelectionController.prototype.get selectedItems): (WI.SelectionController.prototype.get allowsMultipleSelection): (WI.SelectionController.prototype.set allowsMultipleSelection): (WI.SelectionController.prototype.get numberOfItems): (WI.SelectionController.prototype.hasSelectedItem): (WI.SelectionController.prototype.selectItem): (WI.SelectionController.prototype.deselectItem): (WI.SelectionController.prototype.selectAll): (WI.SelectionController.prototype.deselectAll): (WI.SelectionController.prototype.removeSelectedItems): (WI.SelectionController.prototype.reset): (WI.SelectionController.prototype.didRemoveItem): (WI.SelectionController.prototype.handleKeyDown): (WI.SelectionController.prototype.handleItemMouseDown.normalizeRange): (WI.SelectionController.prototype.handleItemMouseDown): (WI.SelectionController.prototype._deselectAllAndSelect): (WI.SelectionController.prototype._selectItemsFromArrowKey): (WI.SelectionController.prototype._nextSelectableIndex): (WI.SelectionController.prototype._previousSelectableIndex): (WI.SelectionController.prototype._updateSelectedItems): * UserInterface/Main.html: * UserInterface/Test.html: * UserInterface/Views/Table.js: (WI.Table): (WI.Table.prototype.get selectedRow): (WI.Table.prototype.get selectedRows): (WI.Table.prototype.get allowsMultipleSelection): (WI.Table.prototype.set allowsMultipleSelection): (WI.Table.prototype.isRowSelected): (WI.Table.prototype.reloadData): (WI.Table.prototype.selectRow): (WI.Table.prototype.deselectRow): (WI.Table.prototype.selectAll): (WI.Table.prototype.deselectAll): (WI.Table.prototype.removeRow): (WI.Table.prototype.removeSelectedRows): (WI.Table.prototype.selectionControllerSelectionDidChange): (WI.Table.prototype.selectionControllerNumberOfItems): (WI.Table.prototype.selectionControllerNextSelectableIndex): (WI.Table.prototype.selectionControllerPreviousSelectableIndex): (WI.Table.prototype._handleKeyDown): (WI.Table.prototype._handleMouseDown): (WI.Table.prototype._removeRows): (WI.Table.prototype._toggleSelectedRowStyle): (WI.Table.prototype._selectRowsFromArrowKey): Deleted. (WI.Table.prototype._handleMouseDown.normalizeRange): Deleted. (WI.Table.prototype._deselectAllAndSelect): Deleted. (WI.Table.prototype._notifySelectionDidChange): Deleted. (WI.Table.prototype._updateSelectedRows): Deleted. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/Utilities.js trunk/Source/WebInspectorUI/UserInterface/Main.html trunk/Source/WebInspectorUI/UserInterface/Test.html trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Added Paths trunk/Source/WebInspectorUI/UserInterface/Controllers/SelectionController.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238562 => 238563) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-27 19:38:18 UTC (rev 238562) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-27 19:41:17 UTC (rev 238563) @@ -1,3 +1,75 @@ +2018-11-27 Matt Baker + +Web Inspector: Table selection should be handled by a SelectionController +https://bugs.webkit.org/show_bug.cgi?id=191977 + + +Reviewed by Devin Rousso. + +Add a SelectionController class, which manages an IndexSet of selected +items, and provides operations for adding and removing items from the +selection. Complex behaviors such as shift-clicking to select a range of +items, and updating the selection using the keyboard, are forwarded to +the controller using special-purpose methods that accept DOM Event objects. + +* UserInterface/Base/Utilities.js: + +* UserInterface/Controllers/SelectionController.js: Added. +(WI.SelectionController): +(WI.SelectionController.prototype.get delegate): +(WI.SelectionController.prototype.get lastSelectedItem): +(WI.SelectionController.prototype.get selectedItems): +(WI.SelectionController.prototype.get allowsMultipleSelection): +(WI.SelectionController.prototype.set allowsMultipleSelection): +(WI.SelectionController.prototype.get num
[webkit-changes] [238483] trunk/Source/WebInspectorUI
Title: [238483] trunk/Source/WebInspectorUI Revision 238483 Author mattba...@apple.com Date 2018-11-25 13:44:43 -0800 (Sun, 25 Nov 2018) Log Message Web Inspector: Remove parameters from TreeOutline SelectionDidChange event https://bugs.webkit.org/show_bug.cgi?id=191770 Reviewed by Devin Rousso. * UserInterface/Controllers/CallFrameTreeController.js: (WI.CallFrameTreeController.prototype._treeSelectionDidChange): * UserInterface/Views/AuditNavigationSidebarPanel.js: (WI.AuditNavigationSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/CanvasSidebarPanel.js: (WI.CanvasSidebarPanel): (WI.CanvasSidebarPanel.prototype._treeSelectionDidChange): (WI.CanvasSidebarPanel.prototype._treeOutlineSelectionDidChange): Deleted. * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype._canvasTreeOutlineSelectionDidChange): * UserInterface/Views/DebuggerSidebarPanel.js: (WI.DebuggerSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/OpenResourceDialog.js: (WI.OpenResourceDialog.prototype._treeSelectionDidChange): * UserInterface/Views/ResourceSidebarPanel.js: (WI.ResourceSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/SearchSidebarPanel.js: (WI.SearchSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/StorageSidebarPanel.js: (WI.StorageSidebarPanel._treeSelectionDidChange): * UserInterface/Views/TimelineDataGrid.js: (WI.TimelineDataGrid.prototype._popoverCallStackTreeSelectionDidChange): (WI.TimelineDataGrid): * UserInterface/Views/TimelineTabContentView.js: (WI.TimelineTabContentView.prototype._recordingsTreeSelectionDidChange): Use `event.target.selectedTreeElement` instead of `event.data.selectedElement`. * UserInterface/Views/TimelineOverview.js: (WI.TimelineOverview.prototype._timelinesTreeSelectionDidChange): (WI.TimelineOverview.prototype._timelinesTreeSelectionDidChange.updateGraphSelectedState): Deleted. Refactor away the single place `event.data.deselectedElement` was used. * UserInterface/Views/TreeElement.js: (WI.TreeElement.prototype.select): (WI.TreeElement.prototype.deselect): Remove `selectedElement` and `deselectedElement` from event data. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/CallFrameTreeController.js trunk/Source/WebInspectorUI/UserInterface/Views/AuditNavigationSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/CanvasSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/CanvasTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/OpenResourceDialog.js trunk/Source/WebInspectorUI/UserInterface/Views/ResourceSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/SearchSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/StorageSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/TimelineDataGrid.js trunk/Source/WebInspectorUI/UserInterface/Views/TimelineOverview.js trunk/Source/WebInspectorUI/UserInterface/Views/TimelineTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeElement.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238482 => 238483) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-25 21:35:18 UTC (rev 238482) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-25 21:44:43 UTC (rev 238483) @@ -1,3 +1,47 @@ +2018-11-25 Matt Baker + +Web Inspector: Remove parameters from TreeOutline SelectionDidChange event +https://bugs.webkit.org/show_bug.cgi?id=191770 + +Reviewed by Devin Rousso. + +* UserInterface/Controllers/CallFrameTreeController.js: +(WI.CallFrameTreeController.prototype._treeSelectionDidChange): +* UserInterface/Views/AuditNavigationSidebarPanel.js: +(WI.AuditNavigationSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/CanvasSidebarPanel.js: +(WI.CanvasSidebarPanel): +(WI.CanvasSidebarPanel.prototype._treeSelectionDidChange): +(WI.CanvasSidebarPanel.prototype._treeOutlineSelectionDidChange): Deleted. +* UserInterface/Views/CanvasTabContentView.js: +(WI.CanvasTabContentView.prototype._canvasTreeOutlineSelectionDidChange): +* UserInterface/Views/DebuggerSidebarPanel.js: +(WI.DebuggerSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/OpenResourceDialog.js: +(WI.OpenResourceDialog.prototype._treeSelectionDidChange): +* UserInterface/Views/ResourceSidebarPanel.js: +(WI.ResourceSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/SearchSidebarPanel.js: +(WI.SearchSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/StorageSidebarPanel.js: +(WI.StorageSidebarPanel._treeSelectionDidChange): +* UserInterface/Views/TimelineDataGrid.js: +(WI.TimelineDataGrid.prototype
[webkit-changes] [238305] trunk/Source/WebInspectorUI
Title: [238305] trunk/Source/WebInspectorUI Revision 238305 Author mattba...@apple.com Date 2018-11-16 14:45:13 -0800 (Fri, 16 Nov 2018) Log Message Web Inspector: TreeOutline shouldn't select first child of an expanded element on right arrow key https://bugs.webkit.org/show_bug.cgi?id=191766 Reviewed by Devin Rousso. * UserInterface/Views/TreeOutline.js: (WI.TreeOutline.prototype._treeKeyDown): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238304 => 238305) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-16 22:16:34 UTC (rev 238304) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-16 22:45:13 UTC (rev 238305) @@ -1,3 +1,13 @@ +2018-11-16 Matt Baker + +Web Inspector: TreeOutline shouldn't select first child of an expanded element on right arrow key +https://bugs.webkit.org/show_bug.cgi?id=191766 + +Reviewed by Devin Rousso. + +* UserInterface/Views/TreeOutline.js: +(WI.TreeOutline.prototype._treeKeyDown): + 2018-11-14 Matt Baker Web Inspector: Table should recalculate scrollable height when resized Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js (238304 => 238305) --- trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-11-16 22:16:34 UTC (rev 238304) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.js 2018-11-16 22:45:13 UTC (rev 238305) @@ -563,12 +563,7 @@ handled = true; } else if (this.selectedTreeElement.hasChildren) { handled = true; -if (this.selectedTreeElement.expanded) { -nextSelectedElement = this.selectedTreeElement.children[0]; -while (nextSelectedElement && !nextSelectedElement.selectable) -nextSelectedElement = nextSelectedElement.nextSibling; -handled = nextSelectedElement ? true : false; -} else { +if (!this.selectedTreeElement.expanded) { if (event.altKey) this.selectedTreeElement.expandRecursively(); else ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [238203] trunk/Source/WebInspectorUI
Title: [238203] trunk/Source/WebInspectorUI Revision 238203 Author mattba...@apple.com Date 2018-11-14 14:54:18 -0800 (Wed, 14 Nov 2018) Log Message Web Inspector: Table should recalculate scrollable height when resized https://bugs.webkit.org/show_bug.cgi?id=191328 Reviewed by Devin Rousso. * UserInterface/Views/NetworkTableContentView.js: (WI.NetworkTableContentView.prototype._hideDetailView): Force table columns to layout after hiding the detail view. * UserInterface/Views/Table.js: (WI.Table): (WI.Table.prototype.showColumn): Call `_resizeColumnsAndFiller` instead of `resize`. The latter also cleared `_cachedWidth`, which isn't unnecessary since the width hasn't changed. (WI.Table.prototype.layout): previously `_resizeColumnsAndFiller` always occurred after `_updateVisibleRows`, it was just a matter of whether the cached width and height were cleared first. That now happens in `sizeDidChange`. (WI.Table.prototype.sizeDidChange): (WI.Table.prototype._updateVisibleRows): (WI.Table.prototype.resize): Deleted. Internally this cleared the cached width and height, which moved to `sizeDidChange`. Externally this was used by NetworkTableContentView to force columns to layout after hiding the details view. Calling `updateLayout` on the table accomplishes the same thing using the standard View API. (WI.Table.prototype._resizeColumnsAndFiller): Only update the cached width, since the height will already have been updated. The number of rows doesn't change during this method, so that check was removed. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238202 => 238203) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-14 22:39:25 UTC (rev 238202) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-14 22:54:18 UTC (rev 238203) @@ -1,3 +1,39 @@ +2018-11-14 Matt Baker + +Web Inspector: Table should recalculate scrollable height when resized +https://bugs.webkit.org/show_bug.cgi?id=191328 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/NetworkTableContentView.js: +(WI.NetworkTableContentView.prototype._hideDetailView): +Force table columns to layout after hiding the detail view. + +* UserInterface/Views/Table.js: +(WI.Table): +(WI.Table.prototype.showColumn): +Call `_resizeColumnsAndFiller` instead of `resize`. The latter also cleared +`_cachedWidth`, which isn't unnecessary since the width hasn't changed. + +(WI.Table.prototype.layout): +previously `_resizeColumnsAndFiller` always occurred after `_updateVisibleRows`, +it was just a matter of whether the cached width and height were cleared first. +That now happens in `sizeDidChange`. + +(WI.Table.prototype.sizeDidChange): +(WI.Table.prototype._updateVisibleRows): +(WI.Table.prototype.resize): Deleted. +Internally this cleared the cached width and height, which moved to `sizeDidChange`. +Externally this was used by NetworkTableContentView to force columns to +layout after hiding the details view. Calling `updateLayout` on the table +accomplishes the same thing using the standard View API. + +(WI.Table.prototype._resizeColumnsAndFiller): +Only update the cached width, since the height will already have been +updated. The number of rows doesn't change during this method, so that +check was removed. + 2018-11-14 Devin Rousso Web Inspector: REGRESSION(r236540): Debugger: breakpoints are sorted alphabetically instead of numerically Modified: trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js (238202 => 238203) --- trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js 2018-11-14 22:39:25 UTC (rev 238202) +++ trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js 2018-11-14 22:54:18 UTC (rev 238203) @@ -1297,7 +1297,7 @@ this._detailView.hidden(); this._detailView = null; -this._table.resize(); +this._table.updateLayout(WI.View.LayoutReason.Resize); this._table.reloadVisibleColumnCells(this._waterfallColumn); } Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (238202 => 238203) --- trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-11-14 22:39:25 UTC (rev 238202) +++ trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-11-14 22:54:18 UTC (rev 238203) @@ -109,7 +109,7 @@ this._cachedWidth = NaN; this._cachedHeight = NaN; this._cachedScrollTop = NaN; -this._cachedScrollableHeight = NaN; +this._previousCachedWidth = NaN; this._previousRevealedRowCount = NaN; this._topSpacerHeight = NaN; this._bottomSpacerH
[webkit-changes] [238140] trunk
Title: [238140] trunk Revision 238140 Author mattba...@apple.com Date 2018-11-13 12:44:36 -0800 (Tue, 13 Nov 2018) Log Message Web Inspector: Table should support select all (Cmd-A) https://bugs.webkit.org/show_bug.cgi?id=190299 Reviewed by Devin Rousso. Source/WebInspectorUI: * UserInterface/Views/Table.js: (WI.Table.prototype.selectAll): (WI.Table.prototype._handleKeyDown): LayoutTests: * inspector/table/table-selection-expected.txt: * inspector/table/table-selection.html: Add tests that `selectAll` works when multiple selection is enabled, and does nothing when multiple selection is disabled. Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/table/table-selection-expected.txt trunk/LayoutTests/inspector/table/table-selection.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/LayoutTests/ChangeLog (238139 => 238140) --- trunk/LayoutTests/ChangeLog 2018-11-13 19:41:39 UTC (rev 238139) +++ trunk/LayoutTests/ChangeLog 2018-11-13 20:44:36 UTC (rev 238140) @@ -1,3 +1,16 @@ +2018-11-13 Matt Baker + +Web Inspector: Table should support select all (Cmd-A) +https://bugs.webkit.org/show_bug.cgi?id=190299 + + +Reviewed by Devin Rousso. + +* inspector/table/table-selection-expected.txt: +* inspector/table/table-selection.html: +Add tests that `selectAll` works when multiple selection is enabled, +and does nothing when multiple selection is disabled. + 2018-11-13 Timothy Hatcher Treat supported-color-schemes as the second highest priority property. Modified: trunk/LayoutTests/inspector/table/table-selection-expected.txt (238139 => 238140) --- trunk/LayoutTests/inspector/table/table-selection-expected.txt 2018-11-13 19:41:39 UTC (rev 238139) +++ trunk/LayoutTests/inspector/table/table-selection-expected.txt 2018-11-13 20:44:36 UTC (rev 238140) @@ -74,3 +74,19 @@ PASS: Table selection changed. PASS: selectedRows should not include 999. +-- Running test case: Table.SelectAll.MultipleSelectionDisabled +Selecting row 0. +PASS: Table selection changed. +PASS: selectedRow should be 0. +Select all. +PASS: Should not have selected additional rows. +PASS: Row 0 should still be selected. + +-- Running test case: Table.SelectAll.MultipleSelectionEnabled +Selecting row 0. +PASS: Table selection changed. +PASS: selectedRow should be 0. +Select all. +PASS: Table selection changed. +PASS: Should have selected all rows. + Modified: trunk/LayoutTests/inspector/table/table-selection.html (238139 => 238140) --- trunk/LayoutTests/inspector/table/table-selection.html 2018-11-13 19:41:39 UTC (rev 238139) +++ trunk/LayoutTests/inspector/table/table-selection.html 2018-11-13 20:44:36 UTC (rev 238140) @@ -146,6 +146,38 @@ } }); +suite.addTestCase({ +name: "Table.SelectAll.MultipleSelectionDisabled", +description: "Select all table rows when multiple selection is disabled.", +test() { +let table = InspectorTest.createTable(); + +triggerSelectRow(table, 0); +InspectorTest.log("Select all."); +table.selectAll(); +InspectorTest.expectEqual(table.selectedRows.length, 1, "Should not have selected additional rows."); +InspectorTest.expectThat(table.isRowSelected(0), "Row 0 should still be selected."); + +return true; +} +}); + +suite.addTestCase({ +name: "Table.SelectAll.MultipleSelectionEnabled", +description: "Select all table rows when multiple selection is enabled.", +test() { +let table = InspectorTest.createTable(); +table.allowsMultipleSelection = true; + +triggerSelectRow(table, 0); +InspectorTest.log("Select all."); +table.selectAll(); +InspectorTest.expectEqual(table.selectedRows.length, table.numberOfRows, "Should have selected all rows."); + +return true; +} +}); + suite.runTestCasesAndFinish(); } Modified: trunk/Source/WebInspectorUI/ChangeLog (238139 => 238140) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-13 19:41:39 UTC (rev 238139) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-13 20:44:36 UTC (rev 238140) @@ -1,5 +1,17 @@ 2018-11-13 Matt Baker +Web Inspector: Table should support select all (Cmd-A) +https://bugs.webkit.org/show_bug.cgi?id=190299 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/Table.js: +(WI.Table.prototype.selectAll): +(WI.Table.prototype._handleKeyDown): + +2018-11-13 Matt Baker + Web Inspector: Table with no selection should select the first/last row on down/up arrow key https://bugs.webkit.org/show_bug.cgi?id=190100 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (238139 => 238140) --- trunk/Source/WebInspectorU
[webkit-changes] [238139] trunk/Source/WebInspectorUI
Title: [238139] trunk/Source/WebInspectorUI Revision 238139 Author mattba...@apple.com Date 2018-11-13 11:41:39 -0800 (Tue, 13 Nov 2018) Log Message Web Inspector: Table with no selection should select the first/last row on down/up arrow key https://bugs.webkit.org/show_bug.cgi?id=190100 Reviewed by Devin Rousso. Pressing the up or down arrow key when nothing is selected should select the last or first row, respectively. After selecting the row make sure it is visible by calling the new Table method `revealRow`. * UserInterface/Views/Table.js: (WI.Table.prototype.revealRow): (WI.Table.prototype._handleKeyDown): (WI.Table.prototype._selectRowsFromArrowKey): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238138 => 238139) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-13 18:44:25 UTC (rev 238138) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-13 19:41:39 UTC (rev 238139) @@ -1,3 +1,20 @@ +2018-11-13 Matt Baker + +Web Inspector: Table with no selection should select the first/last row on down/up arrow key +https://bugs.webkit.org/show_bug.cgi?id=190100 + + +Reviewed by Devin Rousso. + +Pressing the up or down arrow key when nothing is selected should select +the last or first row, respectively. After selecting the row make sure +it is visible by calling the new Table method `revealRow`. + +* UserInterface/Views/Table.js: +(WI.Table.prototype.revealRow): +(WI.Table.prototype._handleKeyDown): +(WI.Table.prototype._selectRowsFromArrowKey): + 2018-11-13 Nikita Vasilyev Web Inspector: Styles: Command-A should select all properties Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (238138 => 238139) --- trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-11-13 18:44:25 UTC (rev 238138) +++ trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-11-13 19:41:39 UTC (rev 238139) @@ -435,6 +435,27 @@ this._removeRows(oldSelectedRows); } +revealRow(rowIndex) +{ +console.assert(rowIndex >= 0 && rowIndex < this.numberOfRows); +if (rowIndex < 0 || rowIndex >= this.numberOfRows) +return; + +// Force our own scroll update because we may have scrolled. +this._cachedScrollTop = NaN; + +if (this._isRowVisible(rowIndex)) { +let row = this._cachedRows.get(rowIndex); +console.assert(row, "Visible rows should always be in the cache."); +if (row) +row.scrollIntoViewIfNeeded(false); +this.needsLayout(); +} else { +this._scrollContainerElement.scrollTop = rowIndex * this._rowHeight; +this.updateLayout(); +} +} + columnWithIdentifier(identifier) { return this._columnSpecs.get(identifier); @@ -1281,9 +1302,6 @@ if (!this.numberOfRows) return; -if (!this._isRowVisible(this._selectedRowIndex)) -return; - if (event.metaKey || event.ctrlKey) return; @@ -1290,14 +1308,8 @@ if (event.keyIdentifier === "Up" || event.keyIdentifier === "Down") { this._selectRowsFromArrowKey(event.keyIdentifier === "Up", event.shiftKey); -let row = this._cachedRows.get(this._selectedRowIndex); -console.assert(row, "Moving up or down by one should always find a cached row since it is within the overflow bounds."); -row.scrollIntoViewIfNeeded(false); +this.revealRow(this._selectedRowIndex); -// Force our own scroll update because we may have scrolled. -this._cachedScrollTop = NaN; -this.needsLayout(); - event.preventDefault(); event.stopPropagation(); } @@ -1305,6 +1317,12 @@ _selectRowsFromArrowKey(goingUp, shiftKey) { +if (!this._selectedRows.size) { +let rowIndex = goingUp ? this.numberOfRows - 1 : 0; +this.selectRow(rowIndex); +return; +} + let rowIncrement = goingUp ? -1 : 1; let rowIndex = this._selectedRowIndex + rowIncrement; if (rowIndex < 0 || rowIndex >= this.numberOfRows) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [238121] trunk
Title: [238121] trunk Revision 238121 Author mattba...@apple.com Date 2018-11-12 21:13:02 -0800 (Mon, 12 Nov 2018) Log Message Web Inspector: Table should support shift-extending the row selection https://bugs.webkit.org/show_bug.cgi?id=189718 Reviewed by Devin Rousso. Source/WebInspectorUI: Allow the table selection to be extended by shift-clicking a row, or by holding shift and pressing either the up or down arrow key. If both command and shift are pressed, shift is ignored. The selection behavior is modeled after AppKit's NSTableView. * UserInterface/Base/IndexSet.js: (WI.IndexSet.prototype.addRange): (WI.IndexSet.prototype.deleteRange): (WI.IndexSet.prototype.equals): (WI.IndexSet.prototype.difference): * UserInterface/Views/Table.js: (WI.Table): (WI.Table.prototype.set allowsMultipleSelection): (WI.Table.prototype.reloadData): (WI.Table.prototype.selectRow): (WI.Table.prototype.deselectRow): (WI.Table.prototype._handleKeyDown): Holding shift and pressing either the up or down arrow key extends the selection to the next unselected row adjacent to the anchor row, or causes the anchor row to be deselected, decreasing the selection. The table chooses the action to take based on the direction of movement (up or down), and the currently selected rows. (WI.Table.prototype._selectRowsFromArrowKey): (WI.Table.prototype._handleMouseDown.normalizeRange): (WI.Table.prototype._handleMouseDown): Clicking a row while holding down shift extends the selection to include the rows between the anchor row (exclusive) and clicked row (inclusive). The anchor row is equal to the value of `_selectedRowIndex` prior to clicking a new row. (WI.Table.prototype._deselectAllAndSelect): (WI.Table.prototype._removeRows): (WI.Table.prototype._toggleSelectedRowStyle): (WI.Table.prototype._updateSelectedRows): Helper method for updating the selection to the specified rows, and updating DOM styles for rows that are added to or removed from the selection. LayoutTests: * inspector/unit-tests/index-set-expected.txt: * inspector/unit-tests/index-set.html: Add tests for new IndexSet methods `addRange`, `deleteRange`, `equals`, and `difference`. Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/unit-tests/index-set-expected.txt trunk/LayoutTests/inspector/unit-tests/index-set.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/IndexSet.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/LayoutTests/ChangeLog (238120 => 238121) --- trunk/LayoutTests/ChangeLog 2018-11-13 04:43:41 UTC (rev 238120) +++ trunk/LayoutTests/ChangeLog 2018-11-13 05:13:02 UTC (rev 238121) @@ -1,3 +1,15 @@ +2018-11-12 Matt Baker + +Web Inspector: Table should support shift-extending the row selection +https://bugs.webkit.org/show_bug.cgi?id=189718 + + +Reviewed by Devin Rousso. + +* inspector/unit-tests/index-set-expected.txt: +* inspector/unit-tests/index-set.html: +Add tests for new IndexSet methods `addRange`, `deleteRange`, `equals`, and `difference`. + 2018-11-12 Zalan Bujtas Do not collapse the soon-to-be-parent anon block when we shuffle around the marker item renderer. Modified: trunk/LayoutTests/inspector/unit-tests/index-set-expected.txt (238120 => 238121) --- trunk/LayoutTests/inspector/unit-tests/index-set-expected.txt 2018-11-13 04:43:41 UTC (rev 238120) +++ trunk/LayoutTests/inspector/unit-tests/index-set-expected.txt 2018-11-13 05:13:02 UTC (rev 238121) @@ -72,3 +72,82 @@ PASS: Copy and original should be different objects. PASS: Copy and original should have the same values. +-- Running test case: IndexSet.prototype.addRange +Given an IndexSet with values []: +Add range to an empty IndexSet. +PASS: Should be [1,2,3] after adding [1,2,3]. + +Given an IndexSet with values [10,11,12]: +Add range before the beginning. +PASS: Should be [0,1,2,10,11,12] after adding [0,1,2]. + +Given an IndexSet with values [1,2,3]: +Add range after the end. +PASS: Should be [1,2,3,10,11,12] after adding [10,11,12]. + +Given an IndexSet with values [1,5]: +Add range in the middle. +PASS: Should be [1,2,3,4,5] after adding [2,3,4]. + +Given an IndexSet with values [1,3,5]: +Add range overlapping the middle. +PASS: Should be [1,2,3,4,5] after adding [2,3,4]. + +Given an IndexSet with values [3,4,5]: +Add range overlapping the beginning. +PASS: Should be [1,2,3,4,5] after adding [1,2,3]. + +Given an IndexSet with values [1,2,3]: +Add range overlapping the end. +PASS: Should be [1,2,3,4,5] after adding [3,4,5]. + + +-- Running test case: IndexSet.prototype.deleteRange +Given an IndexSet with values []: +Remove range from an empty IndexSet. +PASS: Should be [] after removing [1,2,3]. + +Given an IndexSet with values [10,11,12]: +Remove range before the beginning. +PASS: Should be [10,11,12] after removing [0,1,2]. + +Given an IndexSet with values [0,1,2]: +Remove range after the end. +PASS
[webkit-changes] [238023] trunk/Source/WebInspectorUI
Title: [238023] trunk/Source/WebInspectorUI Revision 238023 Author mattba...@apple.com Date 2018-11-08 23:13:25 -0800 (Thu, 08 Nov 2018) Log Message Web Inspector: ResourceQueryController should early return when query is longer than search string https://bugs.webkit.org/show_bug.cgi?id=191436 Reviewed by Devin Rousso. * UserInterface/Controllers/ResourceQueryController.js: * UserInterface/Models/ResourceQueryMatch.js: (WI.ResourceQueryMatch): Drive-by fixes. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/ResourceQueryController.js trunk/Source/WebInspectorUI/UserInterface/Models/ResourceQueryMatch.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (238022 => 238023) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-09 06:52:24 UTC (rev 238022) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-09 07:13:25 UTC (rev 238023) @@ -1,3 +1,16 @@ +2018-11-08 Matt Baker + +Web Inspector: ResourceQueryController should early return when query is longer than search string +https://bugs.webkit.org/show_bug.cgi?id=191436 + +Reviewed by Devin Rousso. + +* UserInterface/Controllers/ResourceQueryController.js: + +* UserInterface/Models/ResourceQueryMatch.js: +(WI.ResourceQueryMatch): +Drive-by fixes. + 2018-11-08 Joseph Pecoraro Uncaught Exception: undefined is not an object (evaluating 'treeElement.parent.removeChild') Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/ResourceQueryController.js (238022 => 238023) --- trunk/Source/WebInspectorUI/UserInterface/Controllers/ResourceQueryController.js 2018-11-09 06:52:24 UTC (rev 238022) +++ trunk/Source/WebInspectorUI/UserInterface/Controllers/ResourceQueryController.js 2018-11-09 07:13:25 UTC (rev 238023) @@ -91,6 +91,9 @@ _findQueryMatches(query, searchString, specialCharacterIndices) { +if (query.length > searchString.length) +return []; + let matches = []; let queryIndex = 0; let searchIndex = 0; Modified: trunk/Source/WebInspectorUI/UserInterface/Models/ResourceQueryMatch.js (238022 => 238023) --- trunk/Source/WebInspectorUI/UserInterface/Models/ResourceQueryMatch.js 2018-11-09 06:52:24 UTC (rev 238022) +++ trunk/Source/WebInspectorUI/UserInterface/Models/ResourceQueryMatch.js 2018-11-09 07:13:25 UTC (rev 238023) @@ -23,7 +23,7 @@ * THE POSSIBILITY OF SUCH DAMAGE. */ -WI.ResourceQueryMatch = class QueryMatch +WI.ResourceQueryMatch = class ResourceQueryMatch { constructor(type, index, queryIndex) { @@ -30,7 +30,6 @@ this._type = type; this._index = index; this._queryIndex = queryIndex; -this._rank = undefined; } // Public ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [237817] trunk
Title: [237817] trunk Revision 237817 Author mattba...@apple.com Date 2018-11-05 11:01:30 -0800 (Mon, 05 Nov 2018) Log Message Web Inspector: Table selection should not require that rows be in the cache https://bugs.webkit.org/show_bug.cgi?id=190993 Reviewed by Devin Rousso. Source/WebInspectorUI: Deselecting a table row shouldn't depend on it being in the cache. This allows us to implement select all, and other kinds of bulk selection actions that affect rows that haven't been revealed. * UserInterface/Views/Table.js: (WI.Table.prototype.deselectRow): LayoutTests: Add a test that a table row that is not in the cache can be selected/deselected. * inspector/table/table-selection-expected.txt: * inspector/table/table-selection.html: Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/table/table-selection-expected.txt trunk/LayoutTests/inspector/table/table-selection.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/LayoutTests/ChangeLog (237816 => 237817) --- trunk/LayoutTests/ChangeLog 2018-11-05 18:37:43 UTC (rev 237816) +++ trunk/LayoutTests/ChangeLog 2018-11-05 19:01:30 UTC (rev 237817) @@ -1,3 +1,16 @@ +2018-11-05 Matt Baker + +Web Inspector: Table selection should not require that rows be in the cache +https://bugs.webkit.org/show_bug.cgi?id=190993 + + +Reviewed by Devin Rousso. + +Add a test that a table row that is not in the cache can be selected/deselected. + +* inspector/table/table-selection-expected.txt: +* inspector/table/table-selection.html: + 2018-11-05 Devin Rousso Web Inspector: show save/restore stack for recorded 2D Canvases Modified: trunk/LayoutTests/inspector/table/table-selection-expected.txt (237816 => 237817) --- trunk/LayoutTests/inspector/table/table-selection-expected.txt 2018-11-05 18:37:43 UTC (rev 237816) +++ trunk/LayoutTests/inspector/table/table-selection-expected.txt 2018-11-05 19:01:30 UTC (rev 237817) @@ -1,4 +1,4 @@ -Tests for WI.Table. +Tests for WI.Table selection. == Running test suite: Table.RowSelection @@ -66,3 +66,11 @@ PASS: selectedRow should be 1. PASS: selectedRows should be [1]. +-- Running test case: Table.SelectAndDeselectRow.NotCached +Selecting row 999. +PASS: Table selection changed. +PASS: selectedRow should be 999. +Deselecting row 999. +PASS: Table selection changed. +PASS: selectedRows should not include 999. + Modified: trunk/LayoutTests/inspector/table/table-selection.html (237816 => 237817) --- trunk/LayoutTests/inspector/table/table-selection.html 2018-11-05 18:37:43 UTC (rev 237816) +++ trunk/LayoutTests/inspector/table/table-selection.html 2018-11-05 19:01:30 UTC (rev 237817) @@ -133,11 +133,24 @@ } }); +suite.addTestCase({ +name: "Table.SelectAndDeselectRow.NotCached", +description: "Select and deselect a row that is not in the table cache.", +test() { +let table = InspectorTest.createTable(1000); + +triggerSelectRow(table, 999); +triggerDeselectRow(table, 999); + +return true; +} +}); + suite.runTestCasesAndFinish(); } -Tests for WI.Table. +Tests for WI.Table selection. Modified: trunk/Source/WebInspectorUI/ChangeLog (237816 => 237817) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-05 18:37:43 UTC (rev 237816) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-05 19:01:30 UTC (rev 237817) @@ -1,3 +1,18 @@ +2018-11-05 Matt Baker + +Web Inspector: Table selection should not require that rows be in the cache +https://bugs.webkit.org/show_bug.cgi?id=190993 + + +Reviewed by Devin Rousso. + +Deselecting a table row shouldn't depend on it being in the cache. This +allows us to implement select all, and other kinds of bulk selection +actions that affect rows that haven't been revealed. + +* UserInterface/Views/Table.js: +(WI.Table.prototype.deselectRow): + 2018-11-05 Devin Rousso Web Inspector: show save/restore stack for recorded 2D Canvases Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (237816 => 237817) --- trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-11-05 18:37:43 UTC (rev 237816) +++ trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-11-05 19:01:30 UTC (rev 237817) @@ -355,11 +355,9 @@ return; let oldSelectedRow = this._cachedRows.get(rowIndex); -if (!oldSelectedRow) -return; +if (oldSelectedRow) +oldSelectedRow.classList.remove("selected"); -oldSelectedRow.classList.remove("selected"); - this._selectedRows.delete(rowIndex); if (this._selectedRowIndex === rowIndex) { ___ webkit-changes mailing list webkit-changes@lists.webkit.org
[webkit-changes] [237746] trunk/Source/WebInspectorUI
Title: [237746] trunk/Source/WebInspectorUI Revision 237746 Author mattba...@apple.com Date 2018-11-02 12:39:01 -0700 (Fri, 02 Nov 2018) Log Message Web Inspector: support multiple selection/deletion of cookie records https://bugs.webkit.org/show_bug.cgi?id=66381 Reviewed by Devin Rousso. * Localizations/en.lproj/localizedStrings.js: * UserInterface/Views/CookieStorageContentView.js: (WI.CookieStorageContentView): (WI.CookieStorageContentView.prototype.get scrollableElements): (WI.CookieStorageContentView.prototype.tableNumberOfRows): (WI.CookieStorageContentView.prototype.tableSortChanged): (WI.CookieStorageContentView.prototype.tableCellContextMenuClicked): (WI.CookieStorageContentView.prototype.tableDidRemoveRows): (WI.CookieStorageContentView.prototype.tablePopulateCell): (WI.CookieStorageContentView.prototype.initialLayout): (WI.CookieStorageContentView.prototype._generateSortComparator): (WI.CookieStorageContentView.prototype._refreshButtonClicked): (WI.CookieStorageContentView.prototype._reloadCookies): (WI.CookieStorageContentView.prototype._updateSort): (WI.CookieStorageContentView.prototype._handleTableKeyDown): (WI.CookieStorageContentView.prototype.update): Deleted. (WI.CookieStorageContentView.prototype._rebuildTable): Deleted. (WI.CookieStorageContentView.prototype._sortDataGrid.localeCompare): Deleted. (WI.CookieStorageContentView.prototype._sortDataGrid.numberCompare): Deleted. (WI.CookieStorageContentView.prototype._sortDataGrid.expiresCompare): Deleted. (WI.CookieStorageContentView.prototype._sortDataGrid): Deleted. (WI.CookieStorageContentView.prototype._deleteCallback): Deleted. Replace DataGrid with Table. The content view serves as the table delegate and data source, and handles delete and backspace key events to allow deleting the selected cookies. Cookies may also be deleted from the table context menu and a new button in the navigation bar. * UserInterface/Views/Table.js: (WI.Table.prototype.isRowSelected): (WI.Table.prototype.selectRow): (WI.Table.prototype.deselectRow): (WI.Table.prototype.removeRow): (WI.Table.prototype._getOrCreateRow): (WI.Table.prototype._handleMouseDown): (WI.Table.prototype._removeRows): (WI.Table.prototype._isRowSelected): Deleted. Make `isSelectedRow` public. It is more convenient and efficient than calling `Table.prototype.selectedRows.includes(rowIndex)`. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js trunk/Source/WebInspectorUI/UserInterface/Views/CookieStorageContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (237745 => 237746) --- trunk/Source/WebInspectorUI/ChangeLog 2018-11-02 19:03:44 UTC (rev 237745) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-11-02 19:39:01 UTC (rev 237746) @@ -1,3 +1,51 @@ +2018-11-02 Matt Baker + +Web Inspector: support multiple selection/deletion of cookie records +https://bugs.webkit.org/show_bug.cgi?id=66381 + + +Reviewed by Devin Rousso. + +* Localizations/en.lproj/localizedStrings.js: + +* UserInterface/Views/CookieStorageContentView.js: +(WI.CookieStorageContentView): +(WI.CookieStorageContentView.prototype.get scrollableElements): +(WI.CookieStorageContentView.prototype.tableNumberOfRows): +(WI.CookieStorageContentView.prototype.tableSortChanged): +(WI.CookieStorageContentView.prototype.tableCellContextMenuClicked): +(WI.CookieStorageContentView.prototype.tableDidRemoveRows): +(WI.CookieStorageContentView.prototype.tablePopulateCell): +(WI.CookieStorageContentView.prototype.initialLayout): +(WI.CookieStorageContentView.prototype._generateSortComparator): +(WI.CookieStorageContentView.prototype._refreshButtonClicked): +(WI.CookieStorageContentView.prototype._reloadCookies): +(WI.CookieStorageContentView.prototype._updateSort): +(WI.CookieStorageContentView.prototype._handleTableKeyDown): +(WI.CookieStorageContentView.prototype.update): Deleted. +(WI.CookieStorageContentView.prototype._rebuildTable): Deleted. +(WI.CookieStorageContentView.prototype._sortDataGrid.localeCompare): Deleted. +(WI.CookieStorageContentView.prototype._sortDataGrid.numberCompare): Deleted. +(WI.CookieStorageContentView.prototype._sortDataGrid.expiresCompare): Deleted. +(WI.CookieStorageContentView.prototype._sortDataGrid): Deleted. +(WI.CookieStorageContentView.prototype._deleteCallback): Deleted. +Replace DataGrid with Table. The content view serves as the table +delegate and data source, and handles delete and backspace key events +to allow deleting the selected cookies. Cookies may also be deleted from +the table context menu and a new button in the navigation bar. + +* UserInterface/Views/Table.js: +(WI.Table.protot
[webkit-changes] [237495] trunk
Title: [237495] trunk Revision 237495 Author mattba...@apple.com Date 2018-10-27 16:30:03 -0700 (Sat, 27 Oct 2018) Log Message Web Inspector: Table should support deleting rows https://bugs.webkit.org/show_bug.cgi?id=189803 Reviewed by Devin Rousso. Source/WebInspectorUI: Add methods for removing rows from a Table without reloading the data source. This patch adds Table.prototype.removeRow for removing a single row, and Table.prototype.removeSelectedRows for removing the entire selection. The latter also attempts to select a new row, if possible, before removing the selection. * UserInterface/Base/IndexSet.js: (WI.IndexSet.prototype.copy): * UserInterface/Views/Table.js: (WI.Table): (WI.Table.prototype.get numberOfRows): Cache the number of rows in the table data source. Invalidate cached value whenever table data is reloaded. Removing rows immediately updates cached value, without incurring a potentially expensive reload. (WI.Table.prototype.reloadData): (WI.Table.prototype.selectRow): (WI.Table.prototype.deselectRow): (WI.Table.prototype.removeRow): (WI.Table.prototype.removeSelectedRows): Remove the selected rows and select a new row, if possible. (WI.Table.prototype._updateVisibleRows): (WI.Table.prototype._handleKeyDown): (WI.Table.prototype._deselectAllAndSelect): Drive-by fix: should work when `rowToSelect` isn't already selected. (WI.Table.prototype._removeRows): Remove rows and adjust the indexes of rows that are shifted up as a result of preceding rows being removed. LayoutTests: * inspector/table/resources/table-utilities.js: (TestPage.registerInitializer.InspectorTest.TableDelegate.prototype.tableDidRemoveRows): (TestPage.registerInitializer.createDataSource): (TestPage.registerInitializer.InspectorTest.createTable): (TestPage.registerInitializer.InspectorTest.createTableWithDelegate): (TestPage.registerInitializer): Update table test utilities to keep TableDataSource backing array in sync when rows are removed. Also allow the number of table rows to be specified when creating a table for testing. * inspector/table/table-remove-rows-expected.txt: Added. * inspector/table/table-remove-rows.html: Added. Add tests for new Table methods `removeRow(rowIndex)` and `removeSelectedRows()`. * inspector/unit-tests/index-set-expected.txt: * inspector/unit-tests/index-set.html: Add tests for new IndexSet method `copy()`. Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/table/resources/table-utilities.js trunk/LayoutTests/inspector/unit-tests/index-set-expected.txt trunk/LayoutTests/inspector/unit-tests/index-set.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/IndexSet.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Added Paths trunk/LayoutTests/inspector/table/table-remove-rows-expected.txt trunk/LayoutTests/inspector/table/table-remove-rows.html Diff Modified: trunk/LayoutTests/ChangeLog (237494 => 237495) --- trunk/LayoutTests/ChangeLog 2018-10-27 21:17:21 UTC (rev 237494) +++ trunk/LayoutTests/ChangeLog 2018-10-27 23:30:03 UTC (rev 237495) @@ -1,3 +1,29 @@ +2018-10-27 Matt Baker + +Web Inspector: Table should support deleting rows +https://bugs.webkit.org/show_bug.cgi?id=189803 + + +Reviewed by Devin Rousso. + +* inspector/table/resources/table-utilities.js: +(TestPage.registerInitializer.InspectorTest.TableDelegate.prototype.tableDidRemoveRows): +(TestPage.registerInitializer.createDataSource): +(TestPage.registerInitializer.InspectorTest.createTable): +(TestPage.registerInitializer.InspectorTest.createTableWithDelegate): +(TestPage.registerInitializer): +Update table test utilities to keep TableDataSource backing array in +sync when rows are removed. Also allow the number of table rows to be +specified when creating a table for testing. + +* inspector/table/table-remove-rows-expected.txt: Added. +* inspector/table/table-remove-rows.html: Added. +Add tests for new Table methods `removeRow(rowIndex)` and `removeSelectedRows()`. + +* inspector/unit-tests/index-set-expected.txt: +* inspector/unit-tests/index-set.html: +Add tests for new IndexSet method `copy()`. + 2018-10-26 Commit Queue Unreviewed, rolling out r237479 and r237484. Modified: trunk/LayoutTests/inspector/table/resources/table-utilities.js (237494 => 237495) --- trunk/LayoutTests/inspector/table/resources/table-utilities.js 2018-10-27 21:17:21 UTC (rev 237494) +++ trunk/LayoutTests/inspector/table/resources/table-utilities.js 2018-10-27 23:30:03 UTC (rev 237495) @@ -21,6 +21,13 @@ this.items = items || []; } +tableDidRemoveRows(table, rowIndexes) +{ +// Prevent data source from getting out of sync. +for (let index = rowIndexes.length - 1; index >= 0; --index) +this.items.splice(index, 1)
[webkit-changes] [237155] trunk/LayoutTests
Title: [237155] trunk/LayoutTests Revision 237155 Author mattba...@apple.com Date 2018-10-15 16:29:28 -0700 (Mon, 15 Oct 2018) Log Message Web Inspector: Cleanup Table test utilities https://bugs.webkit.org/show_bug.cgi?id=190538 Reviewed by Joseph Pecoraro. Cleanup Table test utilities by exposing removing the artificial dependency between TableDelegate and TableDataSource, and exposing a cleaner set of utility methods to InspectorTest. This patch changes `InspectorTest.createTable` to take no parameters, and adds `InspectorTest.createTableWithDelegate` for tests that need to supply a custom delegate. * inspector/table/resources/table-utilities.js: (TestPage.registerInitializer.InspectorTest.TableDataSource): (TestPage.registerInitializer.InspectorTest.TableDelegate): (TestPage.registerInitializer.InspectorTest.TableDelegate.prototype.tablePopulateCell): (TestPage.registerInitializer.createDataSource): (TestPage.registerInitializer.createTableInternal): (TestPage.registerInitializer.InspectorTest.createTable): (TestPage.registerInitializer.InspectorTest.createTableWithDelegate): (TestPage.registerInitializer): * inspector/table/table-selection-expected.txt: Update with new test suite name. * inspector/table/table-selection.html: Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/table/resources/table-utilities.js trunk/LayoutTests/inspector/table/table-selection-expected.txt trunk/LayoutTests/inspector/table/table-selection.html Diff Modified: trunk/LayoutTests/ChangeLog (237154 => 237155) --- trunk/LayoutTests/ChangeLog 2018-10-15 23:18:52 UTC (rev 237154) +++ trunk/LayoutTests/ChangeLog 2018-10-15 23:29:28 UTC (rev 237155) @@ -1,3 +1,32 @@ +2018-10-15 Matt Baker + +Web Inspector: Cleanup Table test utilities +https://bugs.webkit.org/show_bug.cgi?id=190538 + + +Reviewed by Joseph Pecoraro. + +Cleanup Table test utilities by exposing removing the artificial dependency +between TableDelegate and TableDataSource, and exposing a cleaner set of +utility methods to InspectorTest. This patch changes `InspectorTest.createTable` +to take no parameters, and adds `InspectorTest.createTableWithDelegate` for +tests that need to supply a custom delegate. + +* inspector/table/resources/table-utilities.js: +(TestPage.registerInitializer.InspectorTest.TableDataSource): +(TestPage.registerInitializer.InspectorTest.TableDelegate): +(TestPage.registerInitializer.InspectorTest.TableDelegate.prototype.tablePopulateCell): +(TestPage.registerInitializer.createDataSource): +(TestPage.registerInitializer.createTableInternal): +(TestPage.registerInitializer.InspectorTest.createTable): +(TestPage.registerInitializer.InspectorTest.createTableWithDelegate): +(TestPage.registerInitializer): + +* inspector/table/table-selection-expected.txt: +Update with new test suite name. + +* inspector/table/table-selection.html: + 2018-10-15 Charles Vazac Web Inspector: Expose Server Timing Response Headers in Network Tab Modified: trunk/LayoutTests/inspector/table/resources/table-utilities.js (237154 => 237155) --- trunk/LayoutTests/inspector/table/resources/table-utilities.js 2018-10-15 23:18:52 UTC (rev 237154) +++ trunk/LayoutTests/inspector/table/resources/table-utilities.js 2018-10-15 23:29:28 UTC (rev 237155) @@ -3,24 +3,22 @@ { constructor(items) { -this._items = items; +this._items = items || []; } get items() { return this._items; } -// Table DataSource - tableNumberOfRows(table) { return this._items.length; } -} +}; InspectorTest.TableDelegate = class TableDelegate { constructor(items) { -this._items = items; +this.items = items || []; } tableSelectionDidChange(table) @@ -30,35 +28,47 @@ tablePopulateCell(table, cell, column, rowIndex) { -let item = this._items[rowIndex]; +let item = this.items[rowIndex]; InspectorTest.assert(item, "Should have an item for row " + rowIndex); InspectorTest.assert(item[column.identifier], "Should have data for column " + column.identifier); cell.textContent = item[column.identifier]; return cell; } +}; + +function createDataSource() { +let items = []; +for (let i = 0; i < 10; ++i) +items.push({index: i, name: `Row ${i}`}); + +return new InspectorTest.TableDataSource(items); } -InspectorTest.createTable = function(delegate, dataSource) { -if (!dataSource) { -let items = []; -for (let i = 0; i < 10; ++i) { -items.push({ -index: i, -name: "R
[webkit-changes] [237145] trunk/Source/WebInspectorUI
Title: [237145] trunk/Source/WebInspectorUI Revision 237145 Author mattba...@apple.com Date 2018-10-15 14:21:16 -0700 (Mon, 15 Oct 2018) Log Message Web Inspector: REGRESSION (r233824): execution highlight range missing/incorrect in pretty printed code https://bugs.webkit.org/show_bug.cgi?id=188082 Reviewed by Joseph Pecoraro. * UserInterface/Views/SourceCodeTextEditor.js: (WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange): TextEditor expects positions returned by the delegate to be relative to the editor's text content, not the original source code content. * UserInterface/Views/TextEditor.js: (WI.TextEditor.prototype._updateExecutionRangeHighlight): Convert positions to CodeMirror format here rather than in the delegate method, which is a layer removed from CodeMirror. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (237144 => 237145) --- trunk/Source/WebInspectorUI/ChangeLog 2018-10-15 21:21:07 UTC (rev 237144) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-10-15 21:21:16 UTC (rev 237145) @@ -1,3 +1,21 @@ +2018-10-15 Matt Baker + +Web Inspector: REGRESSION (r233824): execution highlight range missing/incorrect in pretty printed code +https://bugs.webkit.org/show_bug.cgi?id=188082 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/SourceCodeTextEditor.js: +(WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange): +TextEditor expects positions returned by the delegate to be relative to +the editor's text content, not the original source code content. + +* UserInterface/Views/TextEditor.js: +(WI.TextEditor.prototype._updateExecutionRangeHighlight): +Convert positions to CodeMirror format here rather than in the delegate +method, which is a layer removed from CodeMirror. + 2018-10-15 Nikita Vasilyev Web Inspector: Dark Mode: unreadable text when hovering CSS properties while holding Command Modified: trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js (237144 => 237145) --- trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js 2018-10-15 21:21:07 UTC (rev 237144) +++ trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js 2018-10-15 21:21:16 UTC (rev 237145) @@ -1426,10 +1426,10 @@ return new WI.SourceCodePosition(position.lineNumber + startLine, columnNumber); } -// When returning offsets, convert to offsets within the SourceCode being viewed. +// When returning positions, convert to positions relative to the TextEditor content. let highlightSourceCodeRange = (startPosition, endPosition) => { -startPosition = fromInlineScriptPosition(startPosition).toCodeMirror(); -endPosition = fromInlineScriptPosition(endPosition).toCodeMirror(); +startPosition = this.originalPositionToCurrentPosition(fromInlineScriptPosition(startPosition)); +endPosition = this.originalPositionToCurrentPosition(fromInlineScriptPosition(endPosition)); callback({startPosition, endPosition}); }; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js (237144 => 237145) --- trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js 2018-10-15 21:21:07 UTC (rev 237144) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js 2018-10-15 21:21:16 UTC (rev 237145) @@ -1345,8 +1345,8 @@ end = {line: this._executionLineNumber}; } else { // Highlight the range. -start = range.startPosition; -end = range.endPosition; +start = range.startPosition.toCodeMirror(); +end = range.endPosition.toCodeMirror(); } // Ensure the marker is cleared in case there were multiple updates very quickly. ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [237050] trunk/Source/WebInspectorUI
Title: [237050] trunk/Source/WebInspectorUI Revision 237050 Author mattba...@apple.com Date 2018-10-11 14:46:43 -0700 (Thu, 11 Oct 2018) Log Message Web Inspector: remove unused TreeOutline style .force-focus https://bugs.webkit.org/show_bug.cgi?id=190480 Reviewed by Joseph Pecoraro. * UserInterface/Views/CallFrameTreeElement.css: (.tree-outline:focus .item.call-frame.selected .status > .status-image): (.tree-outline:matches(:focus, .force-focus) .item.call-frame.selected .status > .status-image): Deleted. * UserInterface/Views/CanvasSidebarPanel.css: (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline:focus .item.processing.selected .subtitle > progress): (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline:matches(:focus, .force-focus) .item.processing.selected .subtitle > progress): Deleted. * UserInterface/Views/DataGrid.css: (body[dir=ltr] .data-grid:focus tr.selected td:not(:last-child)): (body[dir=rtl] .data-grid:focus tr.selected td:not(:last-child)): (.data-grid:focus tr.parent.selected td.disclosure::before): (.data-grid:focus tr.parent.expanded.selected td.disclosure::before): (.data-grid:focus tr.selected): (.data-grid:focus tr.selected td .subtitle): (body:not(.window-inactive, .window-docked-inactive) .data-grid:focus tr.editable.selected .cell-content > input): (@media (prefers-dark-interface)): (body[dir=ltr] .data-grid:matches(:focus, .force-focus) tr.selected td:not(:last-child)): Deleted. (body[dir=rtl] .data-grid:matches(:focus, .force-focus) tr.selected td:not(:last-child)): Deleted. (.data-grid:matches(:focus, .force-focus) tr.parent.selected td.disclosure::before): Deleted. (.data-grid:matches(:focus, .force-focus) tr.parent.expanded.selected td.disclosure::before): Deleted. (.data-grid:matches(:focus, .force-focus) tr.selected): Deleted. (.data-grid:matches(:focus, .force-focus) tr.selected td .subtitle): Deleted. (body:not(.window-inactive, .window-docked-inactive) .data-grid:matches(:focus, .force-focus) tr.editable.selected .cell-content > input): Deleted. * UserInterface/Views/Main.css: (:focus .selected .go-to-arrow): (:focus .selected .go-to-arrow:active): (:matches(:focus, .force-focus) .selected .go-to-arrow): Deleted. (:matches(:focus, .force-focus) .selected .go-to-arrow:active): Deleted. * UserInterface/Views/ProfileView.css: (.profile > .data-grid:focus tr.selected td .location): (.profile > .data-grid:matches(:focus, .force-focus) tr.selected td .location): Deleted. * UserInterface/Views/RecordingActionTreeElement.css: (.tree-outline:focus .item.action.selected:not(.initial-state, .invalid) > .icon): (body:not(.window-inactive, .window-docked-inactive) .tree-outline:focus .item.action.selected > .titles .parameter.swizzled,): (.tree-outline:matches(:focus, .force-focus) .item.action.selected:not(.initial-state, .invalid) > .icon): Deleted. (body:not(.window-inactive, .window-docked-inactive) .tree-outline:matches(:focus, .force-focus) .item.action.selected > .titles .parameter.swizzled,): Deleted. * UserInterface/Views/ScriptDetailsTimelineView.css: (.tree-outline:focus .item.selected .alternate-subtitle): (.tree-outline:matches(:focus, .force-focus) .item.selected .alternate-subtitle): Deleted. * UserInterface/Views/ShaderProgramTreeElement.css: (.tree-outline:focus .item.shader-program.selected .status > img): (.tree-outline:matches(:focus, .force-focus) .item.shader-program.selected .status > img): Deleted. * UserInterface/Views/ThreadTreeElement.css: (.tree-outline:focus > .item.thread.selected .status-button.resume): (.tree-outline:matches(:focus, .force-focus) > .item.thread.selected .status-button.resume): Deleted. * UserInterface/Views/TimelineRecordBar.css: (:focus .selected .timeline-record-bar > .segment): (:focus .selected .timeline-record-bar > .segment.inactive): (body[dir=ltr] :focus .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)): (body[dir=rtl] :focus .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)): (:matches(:focus, .force-focus) .selected .timeline-record-bar > .segment): Deleted. (:matches(:focus, .force-focus) .selected .timeline-record-bar > .segment.inactive): Deleted. (body[dir=ltr] :matches(:focus, .force-focus) .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)): Deleted. (body[dir=rtl] :matches(:focus, .force-focus) .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)): Deleted. * UserInterface/Views/TreeElementStatusButton.css: (:focus .item.selected > .status > .status-button): (:matches(:focus, .force-focus) .item.selected > .status > .status-button): Deleted. * UserInterface/Views/TreeOutline.css: (.tree-outline:focus .item.selected .disclosure-button): (.tree-outline:focus .item.selected.expanded .disclosure-button): (.tree-outline:focus .item.selected): (.tree-outline:focus .item.selected .subtitle): (.tree-outline:not(.large):focus .ite
[webkit-changes] [236868] trunk/Source/WebInspectorUI
Title: [236868] trunk/Source/WebInspectorUI Revision 236868 Author mattba...@apple.com Date 2018-10-04 21:04:10 -0700 (Thu, 04 Oct 2018) Log Message Web Inspector: REGRESSION (r236766): Storage tab no longer updates after main frame navigation https://bugs.webkit.org/show_bug.cgi?id=190298 Reviewed by Joseph Pecoraro. Handle Cleared events from storage managers separately, so that successive events during page load does not cause the Storage tab to destroy newly created tree elements. * UserInterface/Views/StorageSidebarPanel.js: (WI.StorageSidebarPanel): (WI.StorageSidebarPanel.prototype._closeContentViewForTreeElement): (WI.StorageSidebarPanel.prototype._domStorageCleared): (WI.StorageSidebarPanel.prototype._applicationCacheCleared): (WI.StorageSidebarPanel.prototype._indexedDatabaseCleared): (WI.StorageSidebarPanel.prototype._databaseCleared): (WI.StorageSidebarPanel.prototype._storageCleared): Deleted. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/StorageSidebarPanel.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (236867 => 236868) --- trunk/Source/WebInspectorUI/ChangeLog 2018-10-05 03:03:21 UTC (rev 236867) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-10-05 04:04:10 UTC (rev 236868) @@ -1,5 +1,25 @@ 2018-10-04 Matt Baker +Web Inspector: REGRESSION (r236766): Storage tab no longer updates after main frame navigation +https://bugs.webkit.org/show_bug.cgi?id=190298 + +Reviewed by Joseph Pecoraro. + +Handle Cleared events from storage managers separately, so that successive +events during page load does not cause the Storage tab to destroy newly +created tree elements. + +* UserInterface/Views/StorageSidebarPanel.js: +(WI.StorageSidebarPanel): +(WI.StorageSidebarPanel.prototype._closeContentViewForTreeElement): +(WI.StorageSidebarPanel.prototype._domStorageCleared): +(WI.StorageSidebarPanel.prototype._applicationCacheCleared): +(WI.StorageSidebarPanel.prototype._indexedDatabaseCleared): +(WI.StorageSidebarPanel.prototype._databaseCleared): +(WI.StorageSidebarPanel.prototype._storageCleared): Deleted. + +2018-10-04 Matt Baker + Web Inspector: Table should support multiple selection and Cmd-click behavior https://bugs.webkit.org/show_bug.cgi?id=189705 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/StorageSidebarPanel.js (236867 => 236868) --- trunk/Source/WebInspectorUI/UserInterface/Views/StorageSidebarPanel.js 2018-10-05 03:03:21 UTC (rev 236867) +++ trunk/Source/WebInspectorUI/UserInterface/Views/StorageSidebarPanel.js 2018-10-05 04:04:10 UTC (rev 236868) @@ -76,15 +76,15 @@ WI.domStorageManager.addEventListener(WI.DOMStorageManager.Event.CookieStorageObjectWasAdded, this._cookieStorageObjectWasAdded, this); WI.domStorageManager.addEventListener(WI.DOMStorageManager.Event.DOMStorageObjectWasAdded, this._domStorageObjectWasAdded, this); WI.domStorageManager.addEventListener(WI.DOMStorageManager.Event.DOMStorageObjectWasInspected, this._domStorageObjectWasInspected, this); -WI.domStorageManager.addEventListener(WI.DOMStorageManager.Event.Cleared, this._storageCleared, this); +WI.domStorageManager.addEventListener(WI.DOMStorageManager.Event.Cleared, this._domStorageCleared, this); WI.databaseManager.addEventListener(WI.DatabaseManager.Event.DatabaseWasAdded, this._databaseWasAdded, this); WI.databaseManager.addEventListener(WI.DatabaseManager.Event.DatabaseWasInspected, this._databaseWasInspected, this); -WI.databaseManager.addEventListener(WI.DatabaseManager.Event.Cleared, this._storageCleared, this); +WI.databaseManager.addEventListener(WI.DatabaseManager.Event.Cleared, this._databaseCleared, this); WI.indexedDBManager.addEventListener(WI.IndexedDBManager.Event.IndexedDatabaseWasAdded, this._indexedDatabaseWasAdded, this); -WI.indexedDBManager.addEventListener(WI.IndexedDBManager.Event.Cleared, this._storageCleared, this); +WI.indexedDBManager.addEventListener(WI.IndexedDBManager.Event.Cleared, this._indexedDatabaseCleared, this); WI.applicationCacheManager.addEventListener(WI.ApplicationCacheManager.Event.FrameManifestAdded, this._frameManifestAdded, this); WI.applicationCacheManager.addEventListener(WI.ApplicationCacheManager.Event.FrameManifestRemoved, this._frameManifestRemoved, this); -WI.applicationCacheManager.addEventListener(WI.ApplicationCacheManager.Event.Cleared, this._storageCleared, this); +WI.applicationCacheManager.addEventListener(WI.ApplicationCacheManager.Event.Cleared, this._applicationCacheCleared, this); this.contentTreeOutline.addEventListener(WI.TreeOutline.Event.SelectionDidChange, this._treeSelectionDidChange, this); @@ -340,39 +340,69 @@ return parentElement; } -_sto
[webkit-changes] [236853] trunk
Title: [236853] trunk Revision 236853 Author mattba...@apple.com Date 2018-10-04 14:54:14 -0700 (Thu, 04 Oct 2018) Log Message Web Inspector: Table should support multiple selection and Cmd-click behavior https://bugs.webkit.org/show_bug.cgi?id=189705 Reviewed by Devin Rousso. Source/WebInspectorUI: Add multiple row selection to Table, with new methods for programmatic selection (deselectRow, deselectAll), and Command-click support for selecting/deselecting Table rows. * UserInterface/Base/IndexSet.js: Added. (WI.IndexSet): (WI.IndexSet.prototype.get size): (WI.IndexSet.prototype.get firstIndex): (WI.IndexSet.prototype.get lastIndex): (WI.IndexSet.prototype.add): (WI.IndexSet.prototype.delete): (WI.IndexSet.prototype.has): (WI.IndexSet.prototype.clear): (WI.IndexSet.prototype.indexGreaterThan): (WI.IndexSet.prototype.indexLessThan): (WI.IndexSet.prototype.Symbol.iterator): (WI.IndexSet.prototype._indexClosestTo): (WI.IndexSet.prototype._validateIndex): Helper container for managing an ordered sequence of unique positive integers, with set semantics, backed by a sorted array. Used by Table, and eventually by TreeOutline. * UserInterface/Main.html: * UserInterface/Test.html: * UserInterface/Test/Test.js: New files and stubs to make Table layout tests possible. * UserInterface/Views/NetworkTableContentView.js: (WI.NetworkTableContentView.prototype.reset): (WI.NetworkTableContentView.prototype.showRepresentedObject): (WI.NetworkTableContentView.prototype.networkResourceDetailViewClose): (WI.NetworkTableContentView.prototype.tableSelectionDidChange): (WI.NetworkTableContentView.prototype._restoreSelectedRow): (WI.NetworkTableContentView.prototype.tableSelectedRowChanged): Deleted. Replace uses of `clearSelectedRow` with `deselectAll`, and updated selection changed delegate. * UserInterface/Views/Table.css: (.table > .data-container > .data-list > li): (.table > .data-container > .data-list > li.selected): (@media (prefers-dark-interface)): (.table,): Deleted. Removed styles that are no longer needed after https://webkit.org/b/189766, and provide a visual separation between adjacent selected rows. * UserInterface/Views/Table.js: (WI.Table): (WI.Table.prototype.get selectedRows): (WI.Table.prototype.get allowsMultipleSelection): (WI.Table.prototype.set allowsMultipleSelection): (WI.Table.prototype.reloadData): (WI.Table.prototype.selectRow): (WI.Table.prototype.deselectRow): (WI.Table.prototype.deselectAll): (WI.Table.prototype._getOrCreateRow): (WI.Table.prototype._handleMouseDown): (WI.Table.prototype._deselectAllAndSelect): (WI.Table.prototype._isRowSelected): (WI.Table.prototype._notifySelectionDidChange): (WI.Table.prototype.clearSelectedRow): Deleted. Table now tracks selected rows using an IndexSet. selectRow accepts an optional parameter, `extendSelection`, for adding rows to the selection. _selectedRowIndex is now used to track the most recently selected row. This will be the only selected row unless multiple selection is enabled, in which case it is the row that has the "focus", for purposes of selecting a new row using the up or down arrow keys. LayoutTests: * inspector/table/resources/table-utilities.js: Added. (TestPage.registerInitializer.InspectorTest.TableDataSource): (TestPage.registerInitializer.InspectorTest.TableDataSource.prototype.get items): (TestPage.registerInitializer.InspectorTest.TableDataSource.prototype.tableNumberOfRows): (TestPage.registerInitializer.InspectorTest.TableDelegate): (TestPage.registerInitializer.InspectorTest.TableDelegate.prototype.tableSelectionDidChange): (TestPage.registerInitializer.InspectorTest.TableDelegate.prototype.tablePopulateCell): (TestPage.registerInitializer.InspectorTest.createTable): (TestPage.registerInitializer): * inspector/table/table-selection-expected.txt: Added. * inspector/table/table-selection.html: Added. * inspector/unit-tests/index-set-expected.txt: Added. * inspector/unit-tests/index-set.html: Added. Modified Paths trunk/LayoutTests/ChangeLog trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Main.html trunk/Source/WebInspectorUI/UserInterface/Test/Test.js trunk/Source/WebInspectorUI/UserInterface/Test.html trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.css trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Added Paths trunk/LayoutTests/inspector/table/ trunk/LayoutTests/inspector/table/resources/ trunk/LayoutTests/inspector/table/resources/table-utilities.js trunk/LayoutTests/inspector/table/table-selection-expected.txt trunk/LayoutTests/inspector/table/table-selection.html trunk/LayoutTests/inspector/unit-tests/index-set-expected.txt trunk/LayoutTests/inspector/unit-tests/index-set.html trunk/Source/WebInspectorUI/UserInterface/Base/IndexSet.js Diff Modified: trunk/LayoutTests/ChangeLog (236852 => 236853) --- trunk/LayoutTests/ChangeLog 2018-10-04 21:47:13 UTC (rev 236852) +++ trunk/Layou
[webkit-changes] [235997] trunk/Source/WebInspectorUI
Title: [235997] trunk/Source/WebInspectorUI Revision 235997 Author mattba...@apple.com Date 2018-09-13 17:03:05 -0700 (Thu, 13 Sep 2018) Log Message Web Inspector: Timelines: clicking a row in Script > Events grid triggers Location popover when column is hidden https://bugs.webkit.org/show_bug.cgi?id=189603 Reviewed by Joseph Pecoraro. TimelineDataGrid controls showing/hiding the call frame popover, with subclasses overriding callFramePopoverAnchorElement to position it. This patch adds another overridable base class method, shouldShowCallFramePopover, which subclasses can use to block the popover when the Location column is hidden. * UserInterface/Views/DataGrid.js: (WI.DataGrid.prototype.layout): (WI.DataGrid.prototype._positionResizerElements): (WI.DataGrid.prototype._isColumnVisible): Deleted. * UserInterface/Views/LayoutTimelineDataGrid.js: (WI.LayoutTimelineDataGrid.prototype.shouldShowCallFramePopover): (WI.LayoutTimelineDataGrid): * UserInterface/Views/ScriptTimelineDataGrid.js: (WI.ScriptTimelineDataGrid.prototype.shouldShowCallFramePopover): (WI.ScriptTimelineDataGrid): * UserInterface/Views/TimelineDataGrid.js: (WI.TimelineDataGrid.prototype.shouldShowCallFramePopover): (WI.TimelineDataGrid.prototype._dataGridSelectedNodeChanged): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DataGrid.js trunk/Source/WebInspectorUI/UserInterface/Views/LayoutTimelineDataGrid.js trunk/Source/WebInspectorUI/UserInterface/Views/ScriptTimelineDataGrid.js trunk/Source/WebInspectorUI/UserInterface/Views/TimelineDataGrid.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (235996 => 235997) --- trunk/Source/WebInspectorUI/ChangeLog 2018-09-13 23:58:41 UTC (rev 235996) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-09-14 00:03:05 UTC (rev 235997) @@ -1,3 +1,33 @@ +2018-09-13 Matt Baker + +Web Inspector: Timelines: clicking a row in Script > Events grid triggers Location popover when column is hidden +https://bugs.webkit.org/show_bug.cgi?id=189603 + + +Reviewed by Joseph Pecoraro. + +TimelineDataGrid controls showing/hiding the call frame popover, with subclasses +overriding callFramePopoverAnchorElement to position it. This patch adds +another overridable base class method, shouldShowCallFramePopover, which subclasses +can use to block the popover when the Location column is hidden. + +* UserInterface/Views/DataGrid.js: +(WI.DataGrid.prototype.layout): +(WI.DataGrid.prototype._positionResizerElements): +(WI.DataGrid.prototype._isColumnVisible): Deleted. + +* UserInterface/Views/LayoutTimelineDataGrid.js: +(WI.LayoutTimelineDataGrid.prototype.shouldShowCallFramePopover): +(WI.LayoutTimelineDataGrid): + +* UserInterface/Views/ScriptTimelineDataGrid.js: +(WI.ScriptTimelineDataGrid.prototype.shouldShowCallFramePopover): +(WI.ScriptTimelineDataGrid): + +* UserInterface/Views/TimelineDataGrid.js: +(WI.TimelineDataGrid.prototype.shouldShowCallFramePopover): +(WI.TimelineDataGrid.prototype._dataGridSelectedNodeChanged): + 2018-09-13 Joseph Pecoraro Web Inspector: Opening inspector with a selected element might immediately scroll that element off screen in the DOM Tree outline Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DataGrid.js (235996 => 235997) --- trunk/Source/WebInspectorUI/UserInterface/Views/DataGrid.js 2018-09-13 23:58:41 UTC (rev 235996) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DataGrid.js 2018-09-14 00:03:05 UTC (rev 235997) @@ -857,7 +857,7 @@ let columnWidths = []; for (let i = 0; i < numColumns; ++i) { let headerCellElement = cells[i]; -if (this._isColumnVisible(headerCellElement.columnIdentifier)) { +if (this.isColumnVisible(headerCellElement.columnIdentifier)) { let columnWidth = headerCellElement.offsetWidth; let percentWidth = ((columnWidth / tableWidth) * 100) + "%"; columnWidths.push(percentWidth); @@ -894,7 +894,7 @@ this._cachedScrollableOffsetHeight = NaN; } -_isColumnVisible(columnIdentifier) +isColumnVisible(columnIdentifier) { return !this.columns.get(columnIdentifier)["hidden"]; } @@ -969,7 +969,7 @@ leadingOffset = columnWidths[i]; -if (this._isColumnVisible(this.orderedColumns[i])) { +if (this.isColumnVisible(this.orderedColumns[i])) { resizer.element.style.removeProperty("display"); resizer.element.style.setProperty(WI.resolvedLayoutDirection() === WI.LayoutDirection.RTL ? "right" : "left", `${leadingOffset}px`); resizer[WI.DataGrid.PreviousColumnOrdinalSymbol] = i; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/LayoutTimelin
[webkit-changes] [235151] trunk/Source/WebInspectorUI
Title: [235151] trunk/Source/WebInspectorUI Revision 235151 Author mattba...@apple.com Date 2018-08-21 18:08:47 -0700 (Tue, 21 Aug 2018) Log Message Web Inspector: Remove TreeOutlineDataGridSynchronizer https://bugs.webkit.org/show_bug.cgi?id=188449 Reviewed by Devin Rousso. * UserInterface/Views/HeapAllocationsTimelineView.js: (WI.HeapAllocationsTimelineView.prototype.layout): * UserInterface/Views/LayoutTimelineView.js: (WI.LayoutTimelineView.prototype._processPendingRecords): * UserInterface/Views/NetworkTimelineView.js: (WI.NetworkTimelineView.prototype._processPendingRecords): * UserInterface/Views/RenderingFrameTimelineView.js: (WI.RenderingFrameTimelineView.prototype._processPendingRecords): (WI.RenderingFrameTimelineView.prototype.dataGridNodeForTreeElement): Deleted. * UserInterface/Views/ScriptDetailsTimelineView.js: (WI.ScriptDetailsTimelineView.prototype._processPendingRecords): * UserInterface/Views/TimelineDataGrid.js: (WI.TimelineDataGrid): (WI.TimelineDataGrid.prototype.reset): (WI.TimelineDataGrid.prototype.shown): (WI.TimelineDataGrid.prototype.addRowInSortOrder): (WI.TimelineDataGrid.prototype._refreshDirtyDataGridNodes): (WI.TimelineDataGrid.prototype._sort): (WI.TimelineDataGrid.prototype.treeElementForDataGridNode): Deleted. (WI.TimelineDataGrid.prototype.dataGridNodeForTreeElement): Deleted. * UserInterface/Views/TreeOutlineDataGridSynchronizer.js: Removed. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.js trunk/Source/WebInspectorUI/UserInterface/Views/LayoutTimelineView.js trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTimelineView.js trunk/Source/WebInspectorUI/UserInterface/Views/RenderingFrameTimelineView.js trunk/Source/WebInspectorUI/UserInterface/Views/ScriptDetailsTimelineView.js trunk/Source/WebInspectorUI/UserInterface/Views/TimelineDataGrid.js Removed Paths trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutlineDataGridSynchronizer.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (235150 => 235151) --- trunk/Source/WebInspectorUI/ChangeLog 2018-08-22 00:49:32 UTC (rev 235150) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-08-22 01:08:47 UTC (rev 235151) @@ -1,3 +1,33 @@ +2018-08-21 Matt Baker + +Web Inspector: Remove TreeOutlineDataGridSynchronizer +https://bugs.webkit.org/show_bug.cgi?id=188449 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/HeapAllocationsTimelineView.js: +(WI.HeapAllocationsTimelineView.prototype.layout): +* UserInterface/Views/LayoutTimelineView.js: +(WI.LayoutTimelineView.prototype._processPendingRecords): +* UserInterface/Views/NetworkTimelineView.js: +(WI.NetworkTimelineView.prototype._processPendingRecords): +* UserInterface/Views/RenderingFrameTimelineView.js: +(WI.RenderingFrameTimelineView.prototype._processPendingRecords): +(WI.RenderingFrameTimelineView.prototype.dataGridNodeForTreeElement): Deleted. +* UserInterface/Views/ScriptDetailsTimelineView.js: +(WI.ScriptDetailsTimelineView.prototype._processPendingRecords): +* UserInterface/Views/TimelineDataGrid.js: +(WI.TimelineDataGrid): +(WI.TimelineDataGrid.prototype.reset): +(WI.TimelineDataGrid.prototype.shown): +(WI.TimelineDataGrid.prototype.addRowInSortOrder): +(WI.TimelineDataGrid.prototype._refreshDirtyDataGridNodes): +(WI.TimelineDataGrid.prototype._sort): +(WI.TimelineDataGrid.prototype.treeElementForDataGridNode): Deleted. +(WI.TimelineDataGrid.prototype.dataGridNodeForTreeElement): Deleted. +* UserInterface/Views/TreeOutlineDataGridSynchronizer.js: Removed. + 2018-08-21 Joseph Pecoraro Web Inspector: ⌘G does not while find banner is focused Modified: trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.js (235150 => 235151) --- trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.js 2018-08-22 00:49:32 UTC (rev 235150) +++ trunk/Source/WebInspectorUI/UserInterface/Views/HeapAllocationsTimelineView.js 2018-08-22 01:08:47 UTC (rev 235151) @@ -268,7 +268,7 @@ if (this._pendingRecords.length) { for (let heapAllocationsTimelineRecord of this._pendingRecords) { let dataGridNode = new WI.HeapAllocationsTimelineDataGridNode(heapAllocationsTimelineRecord, this.zeroTime, this); -this._dataGrid.addRowInSortOrder(null, dataGridNode); +this._dataGrid.addRowInSortOrder(dataGridNode); if (!this.zeroTime) this._pendingZeroTimeDataGridNodes.push(dataGridNode); } Modified: trunk/Source/WebInspectorUI/UserInterface/Views/LayoutTimelineView.js (235150 => 235151) --- trunk/Source/WebInspectorUI/UserInterface/Views/LayoutTimelineView.js 2018-08-22 00:49:32 UTC (rev 235150) +++ trunk/Source/
[webkit-changes] [234882] trunk/Source/WebInspectorUI
Title: [234882] trunk/Source/WebInspectorUI Revision 234882 Author mattba...@apple.com Date 2018-08-14 23:10:34 -0700 (Tue, 14 Aug 2018) Log Message Web Inspector: Table should not center rows when scrolling them into view https://bugs.webkit.org/show_bug.cgi?id=188593 Reviewed by Devin Rousso. * UserInterface/Views/Table.js: (WI.Table.prototype._handleKeyDown): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (234881 => 234882) --- trunk/Source/WebInspectorUI/ChangeLog 2018-08-15 04:47:16 UTC (rev 234881) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-08-15 06:10:34 UTC (rev 234882) @@ -1,3 +1,14 @@ +2018-08-14 Matt Baker + +Web Inspector: Table should not center rows when scrolling them into view +https://bugs.webkit.org/show_bug.cgi?id=188593 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/Table.js: +(WI.Table.prototype._handleKeyDown): + 2018-08-13 Matt Baker Web Inspector: Table should handle row selection instead of the table delegate Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (234881 => 234882) --- trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-08-15 04:47:16 UTC (rev 234881) +++ trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-08-15 06:10:34 UTC (rev 234882) @@ -1173,7 +1173,7 @@ let row = this._cachedRows.get(this._selectedRowIndex); console.assert(row, "Moving up or down by one should always find a cached row since it is within the overflow bounds."); -row.scrollIntoViewIfNeeded(); +row.scrollIntoViewIfNeeded(false); // Force our own scroll update because we may have scrolled. this._cachedScrollTop = NaN; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [234822] trunk/Source/WebInspectorUI
Title: [234822] trunk/Source/WebInspectorUI Revision 234822 Author mattba...@apple.com Date 2018-08-13 15:44:18 -0700 (Mon, 13 Aug 2018) Log Message Web Inspector: Table should handle row selection instead of the table delegate https://bugs.webkit.org/show_bug.cgi?id=188534 Reviewed by Joseph Pecoraro. Row selection should be implemented by Table, rather than its delegate. * UserInterface/Views/NetworkTableContentView.js: (WI.NetworkTableContentView.prototype.tableShouldSelectRow): (WI.NetworkTableContentView.prototype.tableCellMouseDown): Deleted. Prevent selection unless the clicked cell belongs to the name column. * UserInterface/Views/ResourceCookiesContentView.js: (WI.ResourceCookiesContentView.prototype.tableShouldSelectRow): Always prevent selection. * UserInterface/Views/Table.js: (WI.Table): (WI.Table.prototype._handleMouseDown): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/ResourceCookiesContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/Table.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (234821 => 234822) --- trunk/Source/WebInspectorUI/ChangeLog 2018-08-13 22:29:37 UTC (rev 234821) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-08-13 22:44:18 UTC (rev 234822) @@ -1,3 +1,26 @@ +2018-08-13 Matt Baker + +Web Inspector: Table should handle row selection instead of the table delegate +https://bugs.webkit.org/show_bug.cgi?id=188534 + + +Reviewed by Joseph Pecoraro. + +Row selection should be implemented by Table, rather than its delegate. + +* UserInterface/Views/NetworkTableContentView.js: +(WI.NetworkTableContentView.prototype.tableShouldSelectRow): +(WI.NetworkTableContentView.prototype.tableCellMouseDown): Deleted. +Prevent selection unless the clicked cell belongs to the name column. + +* UserInterface/Views/ResourceCookiesContentView.js: +(WI.ResourceCookiesContentView.prototype.tableShouldSelectRow): +Always prevent selection. + +* UserInterface/Views/Table.js: +(WI.Table): +(WI.Table.prototype._handleMouseDown): + 2018-08-12 Aditya Keerthi [macOS] Color wells should appear pressed when presenting a color picker Modified: trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js (234821 => 234822) --- trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js 2018-08-13 22:29:37 UTC (rev 234821) +++ trunk/Source/WebInspectorUI/UserInterface/Views/NetworkTableContentView.js 2018-08-13 22:44:18 UTC (rev 234822) @@ -324,14 +324,6 @@ // Table delegate -tableCellMouseDown(table, cell, column, rowIndex, event) -{ -if (column !== this._nameColumn) -return; - -this._table.selectRow(rowIndex); -} - tableCellContextMenuClicked(table, cell, column, rowIndex, event) { if (column !== this._nameColumn) @@ -347,6 +339,11 @@ contextMenu.appendItem(WI.UIString("Export HAR"), () => { this._exportHAR(); }); } +tableShouldSelectRow(table, cell, column, rowIndex) +{ +return column === this._nameColumn; +} + tableSelectedRowChanged(table, rowIndex) { if (isNaN(rowIndex)) { Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ResourceCookiesContentView.js (234821 => 234822) --- trunk/Source/WebInspectorUI/UserInterface/Views/ResourceCookiesContentView.js 2018-08-13 22:29:37 UTC (rev 234821) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ResourceCookiesContentView.js 2018-08-13 22:44:18 UTC (rev 234822) @@ -58,6 +58,11 @@ // Table delegate +tableShouldSelectRow(table, cell, column, rowIndex) +{ +return false; +} + tablePopulateCell(table, cell, column, rowIndex) { let cookie = this._dataSourceForTable(table)[rowIndex]; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/Table.js (234821 => 234822) --- trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-08-13 22:29:37 UTC (rev 234821) +++ trunk/Source/WebInspectorUI/UserInterface/Views/Table.js 2018-08-13 22:44:18 UTC (rev 234822) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2008-2017 Apple Inc. All Rights Reserved. + * Copyright (C) 2008-2018 Apple Inc. All Rights Reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -56,8 +56,7 @@ this._scrollContainerElement.className = "data-container"; this._scrollContainerElement.addEventListener("scroll", scrollHandler); this._scrollContainerElement.addEventListener("mousewheel", scrollHandler); -if (this._delegate.tableCellMouseDown) -this._scrollContainerElement.addEventListener("mousedown", this._handleMouseDown.bind(this)); +this
[webkit-changes] [234635] trunk/LayoutTests
Title: [234635] trunk/LayoutTests Revision 234635 Author mattba...@apple.com Date 2018-08-06 16:53:33 -0700 (Mon, 06 Aug 2018) Log Message Web Inspector: split-up async stack trace test suite to improve clarity and maintainability https://bugs.webkit.org/show_bug.cgi?id=185398 Reviewed by Joseph Pecoraro. * inspector/debugger/async-stack-trace-basic-expected.txt: Added. * inspector/debugger/async-stack-trace-basic.html: Added. Basic tests that check for the existence of an asynchronous stack trace when pausing inside an asynchronous callback function. * inspector/debugger/async-stack-trace-event-listener-expected.txt: Added. * inspector/debugger/async-stack-trace-event-listener.html: Added. * inspector/debugger/async-stack-trace-expected.txt: Removed. * inspector/debugger/async-stack-trace-truncate-expected.txt: Added. * inspector/debugger/async-stack-trace-truncate.html: Added. Test scenarios where the number of call frames in the async stack trace exceeds the maximum depth and is truncated. * inspector/debugger/async-stack-trace.html: Removed. * inspector/debugger/resources/async-stack-trace-test.js: Added. (TestPage.registerInitializer.window.getAsyncStackTrace): (TestPage.registerInitializer.logCallFrame): (TestPage.registerInitializer.window.logAsyncStackTrace): (TestPage.registerInitializer.window.addAsyncStackTraceTestCase): (TestPage.registerInitializer): Utility functions used across tests. * inspector/debugger/resources/postMessage-echo.html: Removed. This was unnecessary. To check that an async stack trace exists when pausing in a postMessage handler, all we need is an iframe that posts a message to its parent as soon as it is created. The iframe is now created inline in async-stack-trace-basic.html. * platform/mac/TestExpectations: Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/platform/mac/TestExpectations Added Paths trunk/LayoutTests/inspector/debugger/async-stack-trace-basic-expected.txt trunk/LayoutTests/inspector/debugger/async-stack-trace-basic.html trunk/LayoutTests/inspector/debugger/async-stack-trace-event-listener-expected.txt trunk/LayoutTests/inspector/debugger/async-stack-trace-event-listener.html trunk/LayoutTests/inspector/debugger/async-stack-trace-truncate-expected.txt trunk/LayoutTests/inspector/debugger/async-stack-trace-truncate.html trunk/LayoutTests/inspector/debugger/resources/async-stack-trace-test.js Removed Paths trunk/LayoutTests/inspector/debugger/async-stack-trace-expected.txt trunk/LayoutTests/inspector/debugger/async-stack-trace.html trunk/LayoutTests/inspector/debugger/resources/postMessage-echo.html Diff Modified: trunk/LayoutTests/ChangeLog (234634 => 234635) --- trunk/LayoutTests/ChangeLog 2018-08-06 23:49:09 UTC (rev 234634) +++ trunk/LayoutTests/ChangeLog 2018-08-06 23:53:33 UTC (rev 234635) @@ -1,3 +1,43 @@ +2018-08-06 Matt Baker + +Web Inspector: split-up async stack trace test suite to improve clarity and maintainability +https://bugs.webkit.org/show_bug.cgi?id=185398 + + +Reviewed by Joseph Pecoraro. + +* inspector/debugger/async-stack-trace-basic-expected.txt: Added. +* inspector/debugger/async-stack-trace-basic.html: Added. +Basic tests that check for the existence of an asynchronous stack trace +when pausing inside an asynchronous callback function. + +* inspector/debugger/async-stack-trace-event-listener-expected.txt: Added. +* inspector/debugger/async-stack-trace-event-listener.html: Added. +* inspector/debugger/async-stack-trace-expected.txt: Removed. + +* inspector/debugger/async-stack-trace-truncate-expected.txt: Added. +* inspector/debugger/async-stack-trace-truncate.html: Added. +Test scenarios where the number of call frames in the async stack trace +exceeds the maximum depth and is truncated. + +* inspector/debugger/async-stack-trace.html: Removed. + +* inspector/debugger/resources/async-stack-trace-test.js: Added. +(TestPage.registerInitializer.window.getAsyncStackTrace): +(TestPage.registerInitializer.logCallFrame): +(TestPage.registerInitializer.window.logAsyncStackTrace): +(TestPage.registerInitializer.window.addAsyncStackTraceTestCase): +(TestPage.registerInitializer): +Utility functions used across tests. + +* inspector/debugger/resources/postMessage-echo.html: Removed. +This was unnecessary. To check that an async stack trace exists when +pausing in a postMessage handler, all we need is an iframe that posts a +message to its parent as soon as it is created. The iframe is now created +inline in async-stack-trace-basic.html. + +* platform/mac/TestExpectations: + 2018-08-06 Daniel Bates Setting table layout to fixed causes incorrect cell width calculations Added: trunk/LayoutTests/inspector/debugger/async-stack-trace-basic-expected.txt (0 => 23
[webkit-changes] [233920] trunk/Source/WebInspectorUI
Title: [233920] trunk/Source/WebInspectorUI Revision 233920 Author mattba...@apple.com Date 2018-07-18 11:40:14 -0700 (Wed, 18 Jul 2018) Log Message Web Inspector: REGRESSION(r232591): CodeMirrorEditor should not use a RegExp lineSeparator option https://bugs.webkit.org/show_bug.cgi?id=187772 Reviewed by Joseph Pecoraro. * UserInterface/Views/CodeMirrorEditor.js: (WI.CodeMirrorEditor.create): (WI.CodeMirrorEditor): CodeMirror should be left to auto-detect line separators. By default it detects \n, \r\n, and \r. By specifying a regular _expression_ we merely cause problems when CodeMirror uses the supplied lineSeparator when joining its array of lines together. * UserInterface/Views/TextEditor.js: (WI.TextEditor.set string.update): (WI.TextEditor.prototype.set string): This assertion was only true when we forced "\n" line endings everywhere. It no longer holds for source text with "\r\n" (Windows-style) line endings. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233919 => 233920) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-18 18:35:16 UTC (rev 233919) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-18 18:40:14 UTC (rev 233920) @@ -1,3 +1,25 @@ +2018-07-18 Matt Baker + +Web Inspector: REGRESSION(r232591): CodeMirrorEditor should not use a RegExp lineSeparator option +https://bugs.webkit.org/show_bug.cgi?id=187772 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/CodeMirrorEditor.js: +(WI.CodeMirrorEditor.create): +(WI.CodeMirrorEditor): +CodeMirror should be left to auto-detect line separators. By default +it detects \n, \r\n, and \r. By specifying a regular _expression_ we +merely cause problems when CodeMirror uses the supplied lineSeparator +when joining its array of lines together. + +* UserInterface/Views/TextEditor.js: +(WI.TextEditor.set string.update): +(WI.TextEditor.prototype.set string): +This assertion was only true when we forced "\n" line endings everywhere. +It no longer holds for source text with "\r\n" (Windows-style) line endings. + 2018-07-16 Matt Baker Web Inspector: Fix execution highlighting after r233820 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js (233919 => 233920) --- trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js 2018-07-18 18:35:16 UTC (rev 233919) +++ trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js 2018-07-18 18:40:14 UTC (rev 233920) @@ -27,10 +27,6 @@ { static create(element, options) { -// Default line endings match typical expected line endings for _javascript_ (at least those supported by _javascript_Core). -if (options.lineSeparator === undefined) -options.lineSeparator = /\r\n?|\n/; - // CodeMirror's manual scrollbar positioning results in double scrollbars, // nor does it handle braces and brackets well, so default to using LTR. // Clients can override this if custom layout for RTL is available. Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js (233919 => 233920) --- trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js 2018-07-18 18:35:16 UTC (rev 233919) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js 2018-07-18 18:40:14 UTC (rev 233920) @@ -118,10 +118,9 @@ if (this._initialStringNotSet) this._codeMirror.removeLineClass(0, "wrap"); -if (this._codeMirror.getValue() !== newString) { +if (this._codeMirror.getValue() !== newString) this._codeMirror.setValue(newString); -console.assert(this.string.length === newString.length, "A lot of our code depends on precise text offsets, so the string should remain the same."); -} else { +else { // Ensure we at display content even if the value did not change. This often happens when auto formatting. this.layout(); } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [233861] trunk/Source/WebInspectorUI
Title: [233861] trunk/Source/WebInspectorUI Revision 233861 Author mattba...@apple.com Date 2018-07-16 13:06:52 -0700 (Mon, 16 Jul 2018) Log Message Web Inspector: Fix execution highlighting after r233820 https://bugs.webkit.org/show_bug.cgi?id=187703 Reviewed by Joseph Pecoraro. * UserInterface/Views/SourceCodeTextEditor.js: (WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange): * UserInterface/Views/TextEditor.js: (WI.TextEditor.prototype.currentPositionToOriginalPosition): (WI.TextEditor.prototype._updateExecutionRangeHighlight): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233860 => 233861) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-16 19:49:11 UTC (rev 233860) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-16 20:06:52 UTC (rev 233861) @@ -1,3 +1,17 @@ +2018-07-16 Matt Baker + +Web Inspector: Fix execution highlighting after r233820 +https://bugs.webkit.org/show_bug.cgi?id=187703 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/SourceCodeTextEditor.js: +(WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange): +* UserInterface/Views/TextEditor.js: +(WI.TextEditor.prototype.currentPositionToOriginalPosition): +(WI.TextEditor.prototype._updateExecutionRangeHighlight): + 2018-07-16 Aaron Chu AX: Audit Tab should have an Audit Manager Modified: trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js (233860 => 233861) --- trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js 2018-07-16 19:49:11 UTC (rev 233860) +++ trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js 2018-07-16 20:06:52 UTC (rev 233861) @@ -1413,8 +1413,7 @@ textEditorExecutionHighlightRange(currentPosition, callback) { -let {line, ch} = this.currentPositionToOriginalPosition(currentPosition); -let position = new WI.SourceCodePosition(line, ch); +let position = this.currentPositionToOriginalPosition(currentPosition); let script = this._getAssociatedScript(position); if (!script) { @@ -1491,7 +1490,7 @@ return aLength - bLength; }); -let characterAtPosition = this.getTextInRange(currentPosition, {line: currentPosition.line, ch: currentPosition.ch + 1}); +let characterAtPosition = this.getTextInRange(currentPosition, currentPosition.offsetColumn(1)); let characterAtPositionIsDotOrBracket = characterAtPosition === "." || characterAtPosition === "["; for (let i = 0; i < nodes.length; ++i) { Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js (233860 => 233861) --- trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js 2018-07-16 19:49:11 UTC (rev 233860) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js 2018-07-16 20:06:52 UTC (rev 233861) @@ -784,8 +784,8 @@ if (!this._formatterSourceMap) return position; -let location = this._formatterSourceMap.formattedToOriginal(position.line, position.ch); -return {line: location.lineNumber, ch: location.columnNumber}; +let location = this._formatterSourceMap.formattedToOriginal(position.lineNumber, position.columnNumber); +return new WI.SourceCodePosition(location.lineNumber, location.columnNumber); } currentPositionToCurrentOffset(position) @@ -1323,7 +1323,7 @@ if (isNaN(this._executionLineNumber)) return; -let currentPosition = {line: this._executionLineNumber, ch: this._executionColumnNumber}; +let currentPosition = new WI.SourceCodePosition(this._executionLineNumber, this._executionColumnNumber); this._delegate.textEditorExecutionHighlightRange(currentPosition, (range) => { let start, end; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [233824] trunk/Source/WebInspectorUI
Title: [233824] trunk/Source/WebInspectorUI Revision 233824 Author mattba...@apple.com Date 2018-07-13 16:11:08 -0700 (Fri, 13 Jul 2018) Log Message Web Inspector: REGRESSION (r195723): Improve support for resources with '\r' and '\r\n' line endings https://bugs.webkit.org/show_bug.cgi?id=186453 Reviewed by Joseph Pecoraro. Now that the frontend no longer uses offsets from the original source file to calculate positions within CodeMirror, it is possible to support resources with '\r' and '\r\n' line endings in the editor. * UserInterface/Views/CodeMirrorEditor.js: (WI.CodeMirrorEditor.create): (WI.CodeMirrorEditor): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233823 => 233824) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 22:54:16 UTC (rev 233823) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 23:11:08 UTC (rev 233824) @@ -1,5 +1,21 @@ 2018-07-13 Matt Baker +Web Inspector: REGRESSION (r195723): Improve support for resources with '\r' and '\r\n' line endings +https://bugs.webkit.org/show_bug.cgi?id=186453 + + +Reviewed by Joseph Pecoraro. + +Now that the frontend no longer uses offsets from the original source +file to calculate positions within CodeMirror, it is possible to support +resources with '\r' and '\r\n' line endings in the editor. + +* UserInterface/Views/CodeMirrorEditor.js: +(WI.CodeMirrorEditor.create): +(WI.CodeMirrorEditor): + +2018-07-13 Matt Baker + Web Inspector: Basic blocks highlighting should use line/column locations instead of offsets https://bugs.webkit.org/show_bug.cgi?id=187613 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js (233823 => 233824) --- trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js 2018-07-13 22:54:16 UTC (rev 233823) +++ trunk/Source/WebInspectorUI/UserInterface/Views/CodeMirrorEditor.js 2018-07-13 23:11:08 UTC (rev 233824) @@ -27,8 +27,9 @@ { static create(element, options) { +// Default line endings match typical expected line endings for _javascript_ (at least those supported by _javascript_Core). if (options.lineSeparator === undefined) -options.lineSeparator = "\n"; +options.lineSeparator = /\r\n?|\n/; // CodeMirror's manual scrollbar positioning results in double scrollbars, // nor does it handle braces and brackets well, so default to using LTR. ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [233820] trunk/Source/WebInspectorUI
Title: [233820] trunk/Source/WebInspectorUI Revision 233820 Author mattba...@apple.com Date 2018-07-13 15:27:30 -0700 (Fri, 13 Jul 2018) Log Message Web Inspector: Basic blocks highlighting should use line/column locations instead of offsets https://bugs.webkit.org/show_bug.cgi?id=187613 Reviewed by Joseph Pecoraro. * UserInterface/Controllers/BasicBlockAnnotator.js: Basic blocks sent from the backend include offsets into the original file, rather than line/column locations. In order to translate to positions within CodeMirror, we need to calculate the original line and column for each block. (WI.BasicBlockAnnotator.prototype.insertAnnotations): (WI.BasicBlockAnnotator.prototype._calculateBasicBlockPositions.offsetToPosition): (WI.BasicBlockAnnotator.prototype._calculateBasicBlockPositions): (WI.BasicBlockAnnotator.prototype._annotateBasicBlockExecutionRanges.): (WI.BasicBlockAnnotator.prototype._annotateBasicBlockExecutionRanges): (WI.BasicBlockAnnotator.prototype._highlightTextForBasicBlock): * UserInterface/Models/SourceCodePosition.js: (WI.SourceCodePosition.prototype.offsetColumn): * UserInterface/Views/TextEditor.js: (WI.TextEditor.prototype.getTextInRange): (WI.TextEditor.prototype.addStyleToTextRange): Better encapsulation for CodeMirror positions. * UserInterface/Workers/Formatter/FormatterUtilities.js: (get if): Update String.prototype.lineEndings to support additional line separators. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/BasicBlockAnnotator.js trunk/Source/WebInspectorUI/UserInterface/Models/SourceCodePosition.js trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js trunk/Source/WebInspectorUI/UserInterface/Workers/Formatter/FormatterUtilities.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233819 => 233820) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 22:26:10 UTC (rev 233819) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 22:27:30 UTC (rev 233820) @@ -1,5 +1,38 @@ 2018-07-13 Matt Baker +Web Inspector: Basic blocks highlighting should use line/column locations instead of offsets +https://bugs.webkit.org/show_bug.cgi?id=187613 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Controllers/BasicBlockAnnotator.js: +Basic blocks sent from the backend include offsets into the original +file, rather than line/column locations. In order to translate to positions +within CodeMirror, we need to calculate the original line and column +for each block. + +(WI.BasicBlockAnnotator.prototype.insertAnnotations): +(WI.BasicBlockAnnotator.prototype._calculateBasicBlockPositions.offsetToPosition): +(WI.BasicBlockAnnotator.prototype._calculateBasicBlockPositions): +(WI.BasicBlockAnnotator.prototype._annotateBasicBlockExecutionRanges.): +(WI.BasicBlockAnnotator.prototype._annotateBasicBlockExecutionRanges): +(WI.BasicBlockAnnotator.prototype._highlightTextForBasicBlock): + +* UserInterface/Models/SourceCodePosition.js: +(WI.SourceCodePosition.prototype.offsetColumn): + +* UserInterface/Views/TextEditor.js: +(WI.TextEditor.prototype.getTextInRange): +(WI.TextEditor.prototype.addStyleToTextRange): +Better encapsulation for CodeMirror positions. + +* UserInterface/Workers/Formatter/FormatterUtilities.js: +(get if): +Update String.prototype.lineEndings to support additional line separators. + +2018-07-13 Matt Baker + Web Inspector: Execution highlighting in the frontend should be line/column-based https://bugs.webkit.org/show_bug.cgi?id=187532 Modified: trunk/Source/WebInspectorUI/UserInterface/Controllers/BasicBlockAnnotator.js (233819 => 233820) --- trunk/Source/WebInspectorUI/UserInterface/Controllers/BasicBlockAnnotator.js 2018-07-13 22:26:10 UTC (rev 233819) +++ trunk/Source/WebInspectorUI/UserInterface/Controllers/BasicBlockAnnotator.js 2018-07-13 22:27:30 UTC (rev 233820) @@ -46,13 +46,49 @@ { if (!this.isActive()) return; -this._annotateBasicBlockExecutionRanges(); +this._script.requestContent().then(this._annotateBasicBlockExecutionRanges.bind(this)); } // Private +_calculateBasicBlockPositions(basicBlocks, content) +{ +if (!basicBlocks || !basicBlocks.length) +return; + +let lineEndings = []; +let lineEndingLengths = []; +let pattern = /\r\n?|\n/g; +let match = pattern.exec(content); +while (match) { +lineEndings.push(match.index); +lineEndingLengths.push(match[0].length); +match = pattern.exec(content) +} + +function offsetToPosition(offset) { +let lineNumber = lineEndings.upperBound(offset - 1); +if (lineNumber) { +let previousLine = lineNum
[webkit-changes] [233817] trunk/Source/WebInspectorUI
Title: [233817] trunk/Source/WebInspectorUI Revision 233817 Author mattba...@apple.com Date 2018-07-13 14:53:14 -0700 (Fri, 13 Jul 2018) Log Message Web Inspector: Execution highlighting in the frontend should be line/column-based https://bugs.webkit.org/show_bug.cgi?id=187532 Reviewed by Joseph Pecoraro. Source code offsets from Esprima should not be used to calculate ranges in CodeMirror for _expression_ highlighting. This also fixes a long standing bug when adjusting for the starting position of an inline script. Previously the start offset from the script TextRange was used for this purpose, but the value is often incorrect (see https://bugs.webkit.org/show_bug.cgi?id=187532#c5). By using the starting line/column instead, we avoid the problem. * UserInterface/Models/ScriptSyntaxTree.js: (WI.ScriptSyntaxTree.prototype.containersOfPosition): (WI.ScriptSyntaxTree.prototype.containersOfOffset): Deleted. * UserInterface/Models/SourceCodePosition.js: (WI.SourceCodePosition.prototype.offsetColumn): * UserInterface/Views/SourceCodeTextEditor.js: (WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange.toInlineScriptPosition): (WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange.fromInlineScriptPosition): (WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange): (WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange.convertRangeOffsetsToSourceCodeOffsets): Deleted. * UserInterface/Views/TextEditor.js: (WI.TextEditor.prototype._updateExecutionRangeHighlight): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Models/ScriptSyntaxTree.js trunk/Source/WebInspectorUI/UserInterface/Models/SourceCodePosition.js trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233816 => 233817) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 20:56:36 UTC (rev 233816) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 21:53:14 UTC (rev 233817) @@ -1,5 +1,38 @@ 2018-07-13 Matt Baker +Web Inspector: Execution highlighting in the frontend should be line/column-based +https://bugs.webkit.org/show_bug.cgi?id=187532 + + +Reviewed by Joseph Pecoraro. + +Source code offsets from Esprima should not be used to calculate ranges +in CodeMirror for _expression_ highlighting. + +This also fixes a long standing bug when adjusting for the starting +position of an inline script. Previously the start offset from the script +TextRange was used for this purpose, but the value is often incorrect (see +https://bugs.webkit.org/show_bug.cgi?id=187532#c5). By using the starting +line/column instead, we avoid the problem. + +* UserInterface/Models/ScriptSyntaxTree.js: +(WI.ScriptSyntaxTree.prototype.containersOfPosition): +(WI.ScriptSyntaxTree.prototype.containersOfOffset): Deleted. + +* UserInterface/Models/SourceCodePosition.js: +(WI.SourceCodePosition.prototype.offsetColumn): + +* UserInterface/Views/SourceCodeTextEditor.js: +(WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange.toInlineScriptPosition): +(WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange.fromInlineScriptPosition): +(WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange): +(WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange.convertRangeOffsetsToSourceCodeOffsets): Deleted. + +* UserInterface/Views/TextEditor.js: +(WI.TextEditor.prototype._updateExecutionRangeHighlight): + +2018-07-13 Matt Baker + Web Inspector: SourceCodePosition.js missing from Test.html https://bugs.webkit.org/show_bug.cgi?id=187644 Modified: trunk/Source/WebInspectorUI/UserInterface/Models/ScriptSyntaxTree.js (233816 => 233817) --- trunk/Source/WebInspectorUI/UserInterface/Models/ScriptSyntaxTree.js 2018-07-13 20:56:36 UTC (rev 233816) +++ trunk/Source/WebInspectorUI/UserInterface/Models/ScriptSyntaxTree.js 2018-07-13 21:53:14 UTC (rev 233817) @@ -1,5 +1,5 @@ /* - * Copyright (C) 2014, 2015 Apple Inc. All rights reserved. + * Copyright (C) 2014-2018 Apple Inc. All rights reserved. * * Redistribution and use in source and binary forms, with or without * modification, are permitted provided that the following conditions @@ -79,7 +79,7 @@ return nodes; } -containersOfOffset(offset) +containersOfPosition(position) { console.assert(this._parsedSuccessfully); if (!this._parsedSuccessfully) @@ -86,15 +86,13 @@ return []; let allNodes = []; -const start = 0; -const end = 1; this.forEachNode((node, state) => { -if (node.range[end] < offset) +if (node.endPosition.isB
[webkit-changes] [233800] trunk/Source/WebInspectorUI
Title: [233800] trunk/Source/WebInspectorUI Revision 233800 Author mattba...@apple.com Date 2018-07-13 10:10:28 -0700 (Fri, 13 Jul 2018) Log Message Web Inspector: SourceCodePosition.js missing from Test.html https://bugs.webkit.org/show_bug.cgi?id=187644 Reviewed by Brian Burg. * UserInterface/Test.html: Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Test.html Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233799 => 233800) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 16:19:31 UTC (rev 233799) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 17:10:28 UTC (rev 233800) @@ -1,3 +1,12 @@ +2018-07-13 Matt Baker + +Web Inspector: SourceCodePosition.js missing from Test.html +https://bugs.webkit.org/show_bug.cgi?id=187644 + +Reviewed by Brian Burg. + +* UserInterface/Test.html: + 2018-07-12 Matt Baker Web Inspector: Type token positioning should use line/column locations from Esprima instead of offsets Modified: trunk/Source/WebInspectorUI/UserInterface/Test.html (233799 => 233800) --- trunk/Source/WebInspectorUI/UserInterface/Test.html 2018-07-13 16:19:31 UTC (rev 233799) +++ trunk/Source/WebInspectorUI/UserInterface/Test.html 2018-07-13 17:10:28 UTC (rev 233800) @@ -97,6 +97,7 @@
[webkit-changes] [233792] trunk/Source/WebInspectorUI
Title: [233792] trunk/Source/WebInspectorUI Revision 233792 Author mattba...@apple.com Date 2018-07-12 19:06:48 -0700 (Thu, 12 Jul 2018) Log Message Web Inspector: Type token positioning should use line/column locations from Esprima instead of offsets https://bugs.webkit.org/show_bug.cgi?id=187612 Reviewed by Joseph Pecoraro. * UserInterface/Controllers/TypeTokenAnnotator.js: (WI.TypeTokenAnnotator.prototype.insertAnnotations): (WI.TypeTokenAnnotator.prototype._insertTypeToken): (WI.TypeTokenAnnotator.prototype._insertToken): Use line/column locations, instead of offsets, from the AST when calculating token positions for CodeMirror. Once in CodeMirror's string space, we can safely convert to/from offsets. * UserInterface/Models/ScriptSyntaxTree.js: Retrieve line/column locations for AST nodes, in addition to offsets. Offsets into the original file are still needed for getting type information from the profiler in the backend. (WI.ScriptSyntaxTree): (WI.ScriptSyntaxTree.prototype.filterByRange): Filter by positions, which can be safely used from CodeMirror, instead of offsets. (WI.ScriptSyntaxTree.prototype._createInternalSyntaxTree): (WI.ScriptSyntaxTree.prototype.filterByRange.filterForNodesInRange): Deleted. * UserInterface/Models/SourceCodePosition.js: Add convenience methods for comparing line/column positions, and for converting to the format expected by CodeMirror. SourceCodePosition could be made to interoperate with CodeMirror by exposing properties `line` and `ch`, but making the conversion explicit improves code readability. (WI.SourceCodePosition.prototype.equals): (WI.SourceCodePosition.prototype.isBefore): (WI.SourceCodePosition.prototype.isAfter): (WI.SourceCodePosition.prototype.isWithin): (WI.SourceCodePosition.prototype.toCodeMirror): (WI.SourceCodePosition): * UserInterface/Views/TextEditor.js: (WI.TextEditor.prototype.visibleRangePositions): (WI.TextEditor.prototype.originalPositionToCurrentPosition): (WI.TextEditor.prototype.currentOffsetToCurrentPosition): (WI.TextEditor.prototype.currentPositionToCurrentOffset): (WI.TextEditor.prototype.setInlineWidget): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Controllers/TypeTokenAnnotator.js trunk/Source/WebInspectorUI/UserInterface/Models/ScriptSyntaxTree.js trunk/Source/WebInspectorUI/UserInterface/Models/SourceCodePosition.js trunk/Source/WebInspectorUI/UserInterface/Views/TextEditor.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233791 => 233792) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 01:20:40 UTC (rev 233791) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-13 02:06:48 UTC (rev 233792) @@ -1,3 +1,51 @@ +2018-07-12 Matt Baker + +Web Inspector: Type token positioning should use line/column locations from Esprima instead of offsets +https://bugs.webkit.org/show_bug.cgi?id=187612 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Controllers/TypeTokenAnnotator.js: +(WI.TypeTokenAnnotator.prototype.insertAnnotations): +(WI.TypeTokenAnnotator.prototype._insertTypeToken): +(WI.TypeTokenAnnotator.prototype._insertToken): +Use line/column locations, instead of offsets, from the AST when calculating +token positions for CodeMirror. Once in CodeMirror's string space, we +can safely convert to/from offsets. + +* UserInterface/Models/ScriptSyntaxTree.js: +Retrieve line/column locations for AST nodes, in addition to offsets. +Offsets into the original file are still needed for getting type information +from the profiler in the backend. + +(WI.ScriptSyntaxTree): +(WI.ScriptSyntaxTree.prototype.filterByRange): +Filter by positions, which can be safely used from CodeMirror, instead of offsets. + +(WI.ScriptSyntaxTree.prototype._createInternalSyntaxTree): +(WI.ScriptSyntaxTree.prototype.filterByRange.filterForNodesInRange): Deleted. + +* UserInterface/Models/SourceCodePosition.js: +Add convenience methods for comparing line/column positions, and for +converting to the format expected by CodeMirror. SourceCodePosition could +be made to interoperate with CodeMirror by exposing properties `line` +and `ch`, but making the conversion explicit improves code readability. + +(WI.SourceCodePosition.prototype.equals): +(WI.SourceCodePosition.prototype.isBefore): +(WI.SourceCodePosition.prototype.isAfter): +(WI.SourceCodePosition.prototype.isWithin): +(WI.SourceCodePosition.prototype.toCodeMirror): +(WI.SourceCodePosition): + +* UserInterface/Views/TextEditor.js: +(WI.TextEditor.prototype.visibleRangePositions): +(WI.TextEditor.prototype.originalPositionToCurrentPosition): +(WI.TextEditor.prototype.currentOffsetToCurrentPosition): +(WI.TextEditor.prototype.currentPositionToCurrent
[webkit-changes] [233693] trunk/Source/WebInspectorUI
Title: [233693] trunk/Source/WebInspectorUI Revision 233693 Author mattba...@apple.com Date 2018-07-10 12:14:59 -0700 (Tue, 10 Jul 2018) Log Message Web Inspector: Remove unused NavigationSidebarPanel.treeElementAddedOrChanged https://bugs.webkit.org/show_bug.cgi?id=187508 Reviewed by Joseph Pecoraro. * UserInterface/Views/NavigationSidebarPanel.js: (WI.NavigationSidebarPanel.prototype._treeElementAddedOrChanged): (WI.NavigationSidebarPanel.prototype.treeElementAddedOrChanged): Deleted. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/NavigationSidebarPanel.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233692 => 233693) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-10 18:24:04 UTC (rev 233692) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-10 19:14:59 UTC (rev 233693) @@ -1,5 +1,16 @@ 2018-07-10 Matt Baker +Web Inspector: Remove unused NavigationSidebarPanel.treeElementAddedOrChanged +https://bugs.webkit.org/show_bug.cgi?id=187508 + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/NavigationSidebarPanel.js: +(WI.NavigationSidebarPanel.prototype._treeElementAddedOrChanged): +(WI.NavigationSidebarPanel.prototype.treeElementAddedOrChanged): Deleted. + +2018-07-10 Matt Baker + Web Inspector: REGRESSION (r217505): Debugger content view doesn't update when left sidebar is collapsed https://bugs.webkit.org/show_bug.cgi?id=187482 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/NavigationSidebarPanel.js (233692 => 233693) --- trunk/Source/WebInspectorUI/UserInterface/Views/NavigationSidebarPanel.js 2018-07-10 18:24:04 UTC (rev 233692) +++ trunk/Source/WebInspectorUI/UserInterface/Views/NavigationSidebarPanel.js 2018-07-10 19:14:59 UTC (rev 233693) @@ -449,11 +449,6 @@ } } -treeElementAddedOrChanged(treeElement) -{ -// Implemented by subclasses if needed. -} - // Private _updateContentOverflowShadowVisibility() @@ -604,8 +599,6 @@ if (this.selected) this._checkElementsForPendingViewStateCookie([treeElement]); - -this.treeElementAddedOrChanged(treeElement); } _treeElementDisclosureDidChange(event) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [233686] trunk/Source/WebInspectorUI
Title: [233686] trunk/Source/WebInspectorUI Revision 233686 Author mattba...@apple.com Date 2018-07-10 09:44:45 -0700 (Tue, 10 Jul 2018) Log Message Web Inspector: REGRESSION (r217505): Debugger content view doesn't update when left sidebar is collapsed https://bugs.webkit.org/show_bug.cgi?id=187482 Reviewed by Brian Burg. Subclasses of NavigationSidebarPanel must process tree selection changes even when collapsed. Sidebar panels perform critical controller tasks for their tabs, such as updating the view when pausing in the debugger, and when the hierarchical path component selection changes. * UserInterface/Views/DebuggerSidebarPanel.js: (WI.DebuggerSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/ResourceSidebarPanel.js: (WI.ResourceSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/SearchSidebarPanel.js: (WI.SearchSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/SourcesSidebarPanel.js: (WI.SourcesSidebarPanel.prototype._treeSelectionDidChange): * UserInterface/Views/StorageSidebarPanel.js: (WI.StorageSidebarPanel._treeSelectionDidChange): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/ResourceSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/SearchSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/SourcesSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/StorageSidebarPanel.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (233685 => 233686) --- trunk/Source/WebInspectorUI/ChangeLog 2018-07-10 16:35:35 UTC (rev 233685) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-07-10 16:44:45 UTC (rev 233686) @@ -1,3 +1,27 @@ +2018-07-10 Matt Baker + +Web Inspector: REGRESSION (r217505): Debugger content view doesn't update when left sidebar is collapsed +https://bugs.webkit.org/show_bug.cgi?id=187482 + + +Reviewed by Brian Burg. + +Subclasses of NavigationSidebarPanel must process tree selection changes +even when collapsed. Sidebar panels perform critical controller tasks +for their tabs, such as updating the view when pausing in the debugger, +and when the hierarchical path component selection changes. + +* UserInterface/Views/DebuggerSidebarPanel.js: +(WI.DebuggerSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/ResourceSidebarPanel.js: +(WI.ResourceSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/SearchSidebarPanel.js: +(WI.SearchSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/SourcesSidebarPanel.js: +(WI.SourcesSidebarPanel.prototype._treeSelectionDidChange): +* UserInterface/Views/StorageSidebarPanel.js: +(WI.StorageSidebarPanel._treeSelectionDidChange): + 2018-07-09 Brian Burg REGRESSION: Web Inspector no longer pauses in internal injected scripts like WDFindNodes.js Modified: trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js (233685 => 233686) --- trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js 2018-07-10 16:35:35 UTC (rev 233685) +++ trunk/Source/WebInspectorUI/UserInterface/Views/DebuggerSidebarPanel.js 2018-07-10 16:44:45 UTC (rev 233686) @@ -828,7 +828,7 @@ _treeSelectionDidChange(event) { -if (!this.visible) +if (!this.selected) return; let treeElement = event.data.selectedElement; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ResourceSidebarPanel.js (233685 => 233686) --- trunk/Source/WebInspectorUI/UserInterface/Views/ResourceSidebarPanel.js 2018-07-10 16:35:35 UTC (rev 233685) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ResourceSidebarPanel.js 2018-07-10 16:44:45 UTC (rev 233686) @@ -452,7 +452,7 @@ _treeSelectionDidChange(event) { -if (!this.visible) +if (!this.selected) return; let treeElement = event.data.selectedElement; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/SearchSidebarPanel.js (233685 => 233686) --- trunk/Source/WebInspectorUI/UserInterface/Views/SearchSidebarPanel.js 2018-07-10 16:35:35 UTC (rev 233685) +++ trunk/Source/WebInspectorUI/UserInterface/Views/SearchSidebarPanel.js 2018-07-10 16:44:45 UTC (rev 233686) @@ -363,7 +363,7 @@ _treeSelectionDidChange(event) { -if (!this.visible) +if (!this.selected) return; let treeElement = event.data.selectedElement; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/SourcesSidebarPanel.js (233685 => 233686) --- trunk/Source/WebInspectorUI/UserInterface/Views/SourcesSidebarPanel.js 2018-07-10 16:35:35 UTC (rev 233685) +++ trunk/Source/WebInspectorUI/UserInterface/Views/SourcesSidebarPanel.js 2018-07-10 16:44:45 UTC
[webkit-changes] [233334] trunk/Source/WebInspectorUI
Title: [24] trunk/Source/WebInspectorUI Revision 24 Author mattba...@apple.com Date 2018-06-28 15:38:41 -0700 (Thu, 28 Jun 2018) Log Message Web Inspector: REGRESSION (r213000): copy from Search results content view broken https://bugs.webkit.org/show_bug.cgi?id=187020 Reviewed by Timothy Hatcher. Since WI._copy listens for a copy event from the document, it is called after CodeMirror handles the event and sets clipboard data. If WI._copy finds a custom copy handler to call, that handler can determine whether to overwrite the current clipboard data, or leave it alone. SearchTabContentView's handleCopyEvent method should return early if the content tree outline doesn't have the focus. This prevents the selection in the TextEditor from being overwritten, without any special knowledge of the content browser's current view. * UserInterface/Views/SearchTabContentView.js: (WI.SearchTabContentView.prototype.handleCopyEvent): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/SearchTabContentView.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (23 => 24) --- trunk/Source/WebInspectorUI/ChangeLog 2018-06-28 22:14:39 UTC (rev 23) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-06-28 22:38:41 UTC (rev 24) @@ -1,3 +1,24 @@ +2018-06-28 Matt Baker + +Web Inspector: REGRESSION (r213000): copy from Search results content view broken +https://bugs.webkit.org/show_bug.cgi?id=187020 + + +Reviewed by Timothy Hatcher. + +Since WI._copy listens for a copy event from the document, it is called +after CodeMirror handles the event and sets clipboard data. If WI._copy +finds a custom copy handler to call, that handler can determine whether +to overwrite the current clipboard data, or leave it alone. + +SearchTabContentView's handleCopyEvent method should return early if the +content tree outline doesn't have the focus. This prevents the selection +in the TextEditor from being overwritten, without any special knowledge of +the content browser's current view. + +* UserInterface/Views/SearchTabContentView.js: +(WI.SearchTabContentView.prototype.handleCopyEvent): + 2018-06-25 Nikita Vasilyev Web Inspector: Dark Mode: Box Model section should have dark background Modified: trunk/Source/WebInspectorUI/UserInterface/Views/SearchTabContentView.js (23 => 24) --- trunk/Source/WebInspectorUI/UserInterface/Views/SearchTabContentView.js 2018-06-28 22:14:39 UTC (rev 23) +++ trunk/Source/WebInspectorUI/UserInterface/Views/SearchTabContentView.js 2018-06-28 22:38:41 UTC (rev 24) @@ -99,7 +99,11 @@ handleCopyEvent(event) { -let selectedTreeElement = this.navigationSidebarPanel.contentTreeOutline.selectedTreeElement; +let contentTreeOutline = this.navigationSidebarPanel.contentTreeOutline; +if (contentTreeOutline.element !== document.activeElement) +return; + +let selectedTreeElement = contentTreeOutline.selectedTreeElement; if (!selectedTreeElement) return; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [232524] trunk/Source/WebInspectorUI
Title: [232524] trunk/Source/WebInspectorUI Revision 232524 Author mattba...@apple.com Date 2018-06-05 15:41:00 -0700 (Tue, 05 Jun 2018) Log Message Web Inspector: Tab picker is briefly visible when TabBar initially shown https://bugs.webkit.org/show_bug.cgi?id=186317 Reviewed by Joseph Pecoraro. * UserInterface/Views/TabBar.js: (WI.TabBar): Picker should be initially hidden. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (232523 => 232524) --- trunk/Source/WebInspectorUI/ChangeLog 2018-06-05 22:26:58 UTC (rev 232523) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-06-05 22:41:00 UTC (rev 232524) @@ -1,3 +1,13 @@ +2018-06-05 Matt Baker + +Web Inspector: Tab picker is briefly visible when TabBar initially shown +https://bugs.webkit.org/show_bug.cgi?id=186317 + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/TabBar.js: +(WI.TabBar): Picker should be initially hidden. + 2018-06-05 Nikita Vasilyev Web Inspector: Text in "Add New Class" in auto-capitalizes Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js (232523 => 232524) --- trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js 2018-06-05 22:26:58 UTC (rev 232523) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js 2018-06-05 22:41:00 UTC (rev 232524) @@ -47,7 +47,7 @@ } this._tabPickerTabBarItem = new WI.PinnedTabBarItem("Images/TabPicker.svg", WI.UIString("Show hidden tabs")); -this._tabPickerTabBarItem.element.classList.add("tab-picker"); +this._tabPickerTabBarItem.element.classList.add("tab-picker", "hidden"); this._tabPickerTabBarItem.element.addEventListener("contextmenu", this._handleTabPickerTabContextMenu.bind(this)); this.addTabBarItem(this._tabPickerTabBarItem, {suppressAnimations: true}); } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [232481] trunk/Source/WebInspectorUI
Title: [232481] trunk/Source/WebInspectorUI Revision 232481 Author mattba...@apple.com Date 2018-06-04 14:49:50 -0700 (Mon, 04 Jun 2018) Log Message Web Inspector: Cannot copy a link address in Elements tab https://bugs.webkit.org/show_bug.cgi?id=186281 Reviewed by Brian Burg. * UserInterface/Views/ContextMenuUtilities.js: (WI.appendContextMenuItemsForURL): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (232480 => 232481) --- trunk/Source/WebInspectorUI/ChangeLog 2018-06-04 21:29:36 UTC (rev 232480) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-06-04 21:49:50 UTC (rev 232481) @@ -1,3 +1,14 @@ +2018-06-04 Matt Baker + +Web Inspector: Cannot copy a link address in Elements tab +https://bugs.webkit.org/show_bug.cgi?id=186281 + + +Reviewed by Brian Burg. + +* UserInterface/Views/ContextMenuUtilities.js: +(WI.appendContextMenuItemsForURL): + 2018-05-30 Daniel Bates Web Inspector: Annotate Same-Site cookies Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js (232480 => 232481) --- trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js 2018-06-04 21:29:36 UTC (rev 232480) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ContextMenuUtilities.js 2018-06-04 21:49:50 UTC (rev 232481) @@ -120,7 +120,7 @@ } contextMenu.appendItem(WI.UIString("Copy Link Address"), () => { -InspectorFrontendHost.copyText(sourceCode.url); +InspectorFrontendHost.copyText(url); }); }; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [232189] trunk/Source/WebInspectorUI
Title: [232189] trunk/Source/WebInspectorUI Revision 232189 Author mattba...@apple.com Date 2018-05-25 09:25:27 -0700 (Fri, 25 May 2018) Log Message Web Inspector: Popover dismissed while attempting to move cursor inside https://bugs.webkit.org/show_bug.cgi?id=185741 Reviewed by Joseph Pecoraro. Hovering a token within the bounds of the current popover should not show a new popover. This prevents the popover from being dismissed when the cursor passes over a token under the transparent portion of the popover frame. * UserInterface/Views/SourceCodeTextEditor.js: (WI.SourceCodeTextEditor.prototype._showPopover): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (232188 => 232189) --- trunk/Source/WebInspectorUI/ChangeLog 2018-05-25 14:33:54 UTC (rev 232188) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-05-25 16:25:27 UTC (rev 232189) @@ -1,3 +1,19 @@ +2018-05-25 Matt Baker + +Web Inspector: Popover dismissed while attempting to move cursor inside +https://bugs.webkit.org/show_bug.cgi?id=185741 + + +Reviewed by Joseph Pecoraro. + +Hovering a token within the bounds of the current popover should not +show a new popover. This prevents the popover from being dismissed when +the cursor passes over a token under the transparent portion of the +popover frame. + +* UserInterface/Views/SourceCodeTextEditor.js: +(WI.SourceCodeTextEditor.prototype._showPopover): + 2018-05-22 Ryan Haddad Unreviewed, rolling out r232052. Modified: trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js (232188 => 232189) --- trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js 2018-05-25 14:33:54 UTC (rev 232188) +++ trunk/Source/WebInspectorUI/UserInterface/Views/SourceCodeTextEditor.js 2018-05-25 16:25:27 UTC (rev 232189) @@ -1815,6 +1815,12 @@ var rects = this.rectsForRange(candidate.hoveredTokenRange); bounds = WI.Rect.unionOfRects(rects); +if (this._popover && this._popover.visible) { +let intersection = bounds.intersectionWithRect(this._popover.frame); +if (intersection.size.width && intersection.size.height) +return; +} + shouldHighlightRange = true; } ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [231838] trunk/Source/WebCore
Title: [231838] trunk/Source/WebCore Revision 231838 Author mattba...@apple.com Date 2018-05-15 22:30:09 -0700 (Tue, 15 May 2018) Log Message Web Inspector: element details hanger in inspector overlay should have better placement logic https://bugs.webkit.org/show_bug.cgi?id=128482 Reviewed by Timothy Hatcher. When determining the best position for the hovered element details "tooltip", perform placement tests in view space, not canvas space, and account for the top content inset. * inspector/InspectorOverlayPage.js: (reset): Drive by fix: added missing `.height`. (_drawElementTitle): Modified Paths trunk/Source/WebCore/ChangeLog trunk/Source/WebCore/inspector/InspectorOverlayPage.js Diff Modified: trunk/Source/WebCore/ChangeLog (231837 => 231838) --- trunk/Source/WebCore/ChangeLog 2018-05-16 04:43:15 UTC (rev 231837) +++ trunk/Source/WebCore/ChangeLog 2018-05-16 05:30:09 UTC (rev 231838) @@ -1,3 +1,19 @@ +2018-05-15 Matt Baker + +Web Inspector: element details hanger in inspector overlay should have better placement logic +https://bugs.webkit.org/show_bug.cgi?id=128482 + + +Reviewed by Timothy Hatcher. + +When determining the best position for the hovered element details "tooltip", +perform placement tests in view space, not canvas space, and account for the +top content inset. + +* inspector/InspectorOverlayPage.js: +(reset): Drive by fix: added missing `.height`. +(_drawElementTitle): + 2018-05-15 Commit Queue Unreviewed, rolling out r231765. Modified: trunk/Source/WebCore/inspector/InspectorOverlayPage.js (231837 => 231838) --- trunk/Source/WebCore/inspector/InspectorOverlayPage.js 2018-05-16 04:43:15 UTC (rev 231837) +++ trunk/Source/WebCore/inspector/InspectorOverlayPage.js 2018-05-16 05:30:09 UTC (rev 231838) @@ -137,7 +137,7 @@ document.getElementById("element-title-container").textContent = ""; document.body.classList.remove("dimmed"); -document.getElementById("log").style.setProperty("top", DATA.contentInset + "px"); +document.getElementById("log").style.setProperty("top", DATA.contentInset.height + "px"); } function DOMBuilder(tagName, className) @@ -338,20 +338,24 @@ anchorTop -= scroll.y; anchorBottom -= scroll.y; -if (boxX + titleWidth > canvas.width) -boxX = canvas.width - titleWidth - 2; +var viewportWidth = DATA.viewportSize.width; +if (boxX + titleWidth > viewportWidth) +boxX = viewportWidth - titleWidth - 2; +var viewportHeight = DATA.viewportSize.height; +var viewportTop = DATA.contentInset.height; + var boxY; -if (anchorTop > canvas.height) { +if (anchorTop > viewportHeight) { boxY = canvas.height - titleHeight - arrowHeight; renderArrowDown = true; -} else if (anchorBottom < 0) { +} else if (anchorBottom < viewportTop) { boxY = arrowHeight; renderArrowUp = true; -} else if (anchorBottom + titleHeight + arrowHeight < canvas.height) { +} else if (anchorBottom + titleHeight + arrowHeight < viewportHeight) { boxY = anchorBottom + arrowHeight - 4; renderArrowUp = true; -} else if (anchorTop - titleHeight - arrowHeight > 0) { +} else if (anchorTop - titleHeight - arrowHeight > viewportTop) { boxY = anchorTop - titleHeight - arrowHeight + 3; renderArrowDown = true; } else ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [231659] trunk
Title: [231659] trunk Revision 231659 Author mattba...@apple.com Date 2018-05-10 13:59:07 -0700 (Thu, 10 May 2018) Log Message Web Inspector: ASSERT_NOT_REACHED in PageDebuggerAgent::didAddEventListener when page adds attribute event listener https://bugs.webkit.org/show_bug.cgi?id=181580 Reviewed by Brian Burg. Source/WebCore: EventTarget should pass newly added EventListeners to InspectorInstrumentation, instead of PageDebuggerAgent assuming the last item in the EventListenerVector is the most recently added listener. This assumption does not hold when the new listener replaces an existing listener. * dom/EventTarget.cpp: (WebCore::EventTarget::addEventListener): (WebCore::EventTarget::setAttributeEventListener): * inspector/InspectorInstrumentation.cpp: (WebCore::InspectorInstrumentation::didAddEventListenerImpl): * inspector/InspectorInstrumentation.h: (WebCore::InspectorInstrumentation::didAddEventListener): * inspector/agents/page/PageDebuggerAgent.cpp: (WebCore::PageDebuggerAgent::didAddEventListener): * inspector/agents/page/PageDebuggerAgent.h: LayoutTests: Add new test covering the case where adding an attribute event listener causes an existing attribute event listener to be replaced. * inspector/debugger/async-stack-trace-expected.txt: * inspector/debugger/async-stack-trace.html: Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/debugger/async-stack-trace-expected.txt trunk/LayoutTests/inspector/debugger/async-stack-trace.html trunk/Source/WebCore/ChangeLog trunk/Source/WebCore/dom/EventTarget.cpp trunk/Source/WebCore/inspector/InspectorInstrumentation.cpp trunk/Source/WebCore/inspector/InspectorInstrumentation.h trunk/Source/WebCore/inspector/agents/page/PageDebuggerAgent.cpp trunk/Source/WebCore/inspector/agents/page/PageDebuggerAgent.h Diff Modified: trunk/LayoutTests/ChangeLog (231658 => 231659) --- trunk/LayoutTests/ChangeLog 2018-05-10 20:54:12 UTC (rev 231658) +++ trunk/LayoutTests/ChangeLog 2018-05-10 20:59:07 UTC (rev 231659) @@ -1,3 +1,17 @@ +2018-05-10 Matt Baker + +Web Inspector: ASSERT_NOT_REACHED in PageDebuggerAgent::didAddEventListener when page adds attribute event listener +https://bugs.webkit.org/show_bug.cgi?id=181580 + + +Reviewed by Brian Burg. + +Add new test covering the case where adding an attribute event listener +causes an existing attribute event listener to be replaced. + +* inspector/debugger/async-stack-trace-expected.txt: +* inspector/debugger/async-stack-trace.html: + 2018-05-10 Chris Dumez 'Cross-Origin-Options header implementation follow-up Modified: trunk/LayoutTests/inspector/debugger/async-stack-trace-expected.txt (231658 => 231659) --- trunk/LayoutTests/inspector/debugger/async-stack-trace-expected.txt 2018-05-10 20:54:12 UTC (rev 231658) +++ trunk/LayoutTests/inspector/debugger/async-stack-trace-expected.txt 2018-05-10 20:59:07 UTC (rev 231659) @@ -1,4 +1,4 @@ -CONSOLE MESSAGE: line 55: Unable to post message to http://example.com. Recipient has origin . +CONSOLE MESSAGE: line 83: Unable to post message to http://example.com. Recipient has origin . Tests for async stack traces. @@ -80,6 +80,26 @@ 5: [F] testAddEventListener 6: [P] Global Code +-- Running test case: CheckAsyncStackTrace.AddAttributeEventListener +PAUSE #1 +CALL STACK: +0: [F] pauseThenFinishTest +1: [F] handleClick +2: [F] testAttributeEventListener +3: [P] Global Code +4: [F] testAttributeEventListener +5: [P] Global Code + +-- Running test case: CheckAsyncStackTrace.ReplaceAttributeEventListener +PAUSE #1 +CALL STACK: +0: [F] pauseThenFinishTest +1: [F] handleClick2 +2: [F] testReplaceAttributeEventListener +3: [P] Global Code +4: [F] testReplaceAttributeEventListener +5: [P] Global Code + -- Running test case: CheckAsyncStackTrace.PostMessage PAUSE #1 CALL STACK: Modified: trunk/LayoutTests/inspector/debugger/async-stack-trace.html (231658 => 231659) --- trunk/LayoutTests/inspector/debugger/async-stack-trace.html 2018-05-10 20:54:12 UTC (rev 231658) +++ trunk/LayoutTests/inspector/debugger/async-stack-trace.html 2018-05-10 20:59:07 UTC (rev 231659) @@ -50,6 +50,34 @@ document.body.click(); } +function testAttributeEventListener() { +let previousListener = document.body.onclick; + +function handleClick() { +document.body._onclick_ = previousListener; +pauseThenFinishTest(); +} + +document.body._onclick_ = handleClick; +document.body.click(); +} + +function testReplaceAttributeEventListener() { +let previousListener = document.body.onclick; + +function handleClick1() {} + +function handleClick2() { +document.body._onclick_ = previousListener; +pauseThenFinishTest(); +} + +document.body._onclick_ = handleClick1; +document.body.addEventListener("click", handleClick1, {once: true}); +document.body._onclick_ = handleClick2; +document.body.click(); +} +
[webkit-changes] [231527] trunk/Source/WebInspectorUI
Title: [231527] trunk/Source/WebInspectorUI Revision 231527 Author mattba...@apple.com Date 2018-05-08 17:09:41 -0700 (Tue, 08 May 2018) Log Message Web Inspector: Console drawer resizing is broken when console prompt has >1 line of code https://bugs.webkit.org/show_bug.cgi?id=185369 Reviewed by Devin Rousso. Mouse offset calculation should account for the height of the quick console. The only reason resizing worked with the single-line quick console is that the offset calculation included the resizer height, which is very close to that of the single-line quick console (27px and 30px respectively). * UserInterface/Views/ConsoleDrawer.js: Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleDrawer.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (231526 => 231527) --- trunk/Source/WebInspectorUI/ChangeLog 2018-05-09 00:04:10 UTC (rev 231526) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-05-09 00:09:41 UTC (rev 231527) @@ -1,3 +1,18 @@ +2018-05-08 Matt Baker + +Web Inspector: Console drawer resizing is broken when console prompt has >1 line of code +https://bugs.webkit.org/show_bug.cgi?id=185369 + + +Reviewed by Devin Rousso. + +Mouse offset calculation should account for the height of the quick console. +The only reason resizing worked with the single-line quick console is that +the offset calculation included the resizer height, which is very close +to that of the single-line quick console (27px and 30px respectively). + +* UserInterface/Views/ConsoleDrawer.js: + 2018-05-04 Devin Rousso Web Inspector: simplify the WI.Collection interface Modified: trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleDrawer.js (231526 => 231527) --- trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleDrawer.js 2018-05-09 00:04:10 UTC (rev 231526) +++ trunk/Source/WebInspectorUI/UserInterface/Views/ConsoleDrawer.js 2018-05-09 00:09:41 UTC (rev 231527) @@ -122,7 +122,8 @@ return; let resizerElement = event.target; -let mouseOffset = resizerElement.offsetHeight - (event.pageY - resizerElement.totalOffsetTop); +let quickConsoleHeight = window.innerHeight - (this.element.totalOffsetTop + this.height); +let mouseOffset = quickConsoleHeight - (event.pageY - resizerElement.totalOffsetTop); function dockedResizerDrag(event) { ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [230903] trunk/Source/WebKit
Title: [230903] trunk/Source/WebKit Revision 230903 Author mattba...@apple.com Date 2018-04-22 16:03:44 -0700 (Sun, 22 Apr 2018) Log Message Web Inspector: WebInspectorProxy releases WKWebInspectorProxyObjCAdapter without removing corresponding observer https://bugs.webkit.org/show_bug.cgi?id=184865 Reviewed by Brian Burg. Replace the early return removed in https://bugs.webkit.org/show_bug.cgi?id=177661, so that WKWebInspectorProxyObjCAdapter and the view controller can be reused when reopening the Inspector while the WebView is still alive. * UIProcess/mac/WebInspectorProxyMac.mm: (WebKit::WebInspectorProxy::platformCreateFrontendPage): Modified Paths trunk/Source/WebKit/ChangeLog trunk/Source/WebKit/UIProcess/mac/WebInspectorProxyMac.mm Diff Modified: trunk/Source/WebKit/ChangeLog (230902 => 230903) --- trunk/Source/WebKit/ChangeLog 2018-04-22 21:39:30 UTC (rev 230902) +++ trunk/Source/WebKit/ChangeLog 2018-04-22 23:03:44 UTC (rev 230903) @@ -1,3 +1,18 @@ +2018-04-22 Matt Baker + +Web Inspector: WebInspectorProxy releases WKWebInspectorProxyObjCAdapter without removing corresponding observer +https://bugs.webkit.org/show_bug.cgi?id=184865 + + +Reviewed by Brian Burg. + +Replace the early return removed in https://bugs.webkit.org/show_bug.cgi?id=177661, +so that WKWebInspectorProxyObjCAdapter and the view controller can be reused +when reopening the Inspector while the WebView is still alive. + +* UIProcess/mac/WebInspectorProxyMac.mm: +(WebKit::WebInspectorProxy::platformCreateFrontendPage): + 2018-04-22 Paul Knight Add -[WKInputDelegate _webView:decidePolicyForFocusedElement:] so clients can request default focusing behavior Modified: trunk/Source/WebKit/UIProcess/mac/WebInspectorProxyMac.mm (230902 => 230903) --- trunk/Source/WebKit/UIProcess/mac/WebInspectorProxyMac.mm 2018-04-22 21:39:30 UTC (rev 230902) +++ trunk/Source/WebKit/UIProcess/mac/WebInspectorProxyMac.mm 2018-04-22 23:03:44 UTC (rev 230903) @@ -217,6 +217,11 @@ m_closeFrontendAfterInactivityTimer.stop(); +if (m_inspectorViewController) { +ASSERT(m_objCAdapter); +return [m_inspectorViewController webView]->_page.get(); +} + m_objCAdapter = adoptNS([[WKWebInspectorProxyObjCAdapter alloc] initWithWebInspectorProxy:this]); NSView *inspectedView = inspectedPage()->inspectorAttachmentView(); [[NSNotificationCenter defaultCenter] addObserver:m_objCAdapter.get() selector:@selector(inspectedViewFrameDidChange:) name:NSViewFrameDidChangeNotification object:inspectedView]; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [230149] trunk/Source/WebInspectorUI
Title: [230149] trunk/Source/WebInspectorUI Revision 230149 Author mattba...@apple.com Date 2018-04-01 22:59:28 -0700 (Sun, 01 Apr 2018) Log Message Web Inspector: Remove dead TabBrowser/TabContentView code https://bugs.webkit.org/show_bug.cgi?id=184104 Reviewed by Devin Rousso. * UserInterface/Base/Main.js: (WI._tryToRestorePendingTabs): * UserInterface/Views/NewTabContentView.js: (WI.NewTabContentView.prototype.shown): (WI.NewTabContentView.prototype.hidden): * UserInterface/Views/TabBrowser.js: (WI.TabBrowser.prototype.addTabForContentView): (WI.TabBrowser.prototype.showTabForContentView): (WI.TabBrowser._tabBarItemRemoved): * UserInterface/Views/TabContentView.js: (WI.TabContentView.prototype.get parentTabBrowser): Deleted. (WI.TabContentView.prototype.set parentTabBrowser): Deleted. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/Main.js trunk/Source/WebInspectorUI/UserInterface/Views/NewTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBrowser.js trunk/Source/WebInspectorUI/UserInterface/Views/TabContentView.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (230148 => 230149) --- trunk/Source/WebInspectorUI/ChangeLog 2018-04-02 05:03:57 UTC (rev 230148) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-04-02 05:59:28 UTC (rev 230149) @@ -1,3 +1,23 @@ +2018-04-01 Matt Baker + +Web Inspector: Remove dead TabBrowser/TabContentView code +https://bugs.webkit.org/show_bug.cgi?id=184104 + +Reviewed by Devin Rousso. + +* UserInterface/Base/Main.js: +(WI._tryToRestorePendingTabs): +* UserInterface/Views/NewTabContentView.js: +(WI.NewTabContentView.prototype.shown): +(WI.NewTabContentView.prototype.hidden): +* UserInterface/Views/TabBrowser.js: +(WI.TabBrowser.prototype.addTabForContentView): +(WI.TabBrowser.prototype.showTabForContentView): +(WI.TabBrowser._tabBarItemRemoved): +* UserInterface/Views/TabContentView.js: +(WI.TabContentView.prototype.get parentTabBrowser): Deleted. +(WI.TabContentView.prototype.set parentTabBrowser): Deleted. + 2018-03-30 Devin Rousso Web Inspector: tint all pixels drawn by shader program when hovering ShaderProgramTreeElement Modified: trunk/Source/WebInspectorUI/UserInterface/Base/Main.js (230148 => 230149) --- trunk/Source/WebInspectorUI/UserInterface/Base/Main.js 2018-04-02 05:03:57 UTC (rev 230148) +++ trunk/Source/WebInspectorUI/UserInterface/Base/Main.js 2018-04-02 05:59:28 UTC (rev 230149) @@ -614,7 +614,7 @@ this._pendingOpenTabs = stillPendingOpenTabs; if (!WI.settings.experimentalEnableNewTabBar.value) -this.tabBrowser.tabBar.updateNewTabTabBarItemState(); +this.tabBar.updateNewTabTabBarItemState(); }; WI.showNewTabTab = function(options) @@ -1416,8 +1416,6 @@ if (!event.target.isMainFrame()) return; -this._inProvisionalLoad = false; - // Run cookie restoration after we are sure all of the Tabs and NavigationSidebarPanels // have updated with respect to the main resource change. setTimeout(this._restoreCookieForOpenTabs.bind(this, WI.StateRestorationType.Navigation)); @@ -1433,8 +1431,6 @@ return; this._saveCookieForOpenTabs(); - -this._inProvisionalLoad = true; }; WI._restoreCookieForOpenTabs = function(restorationType) Modified: trunk/Source/WebInspectorUI/UserInterface/Views/NewTabContentView.js (230148 => 230149) --- trunk/Source/WebInspectorUI/UserInterface/Views/NewTabContentView.js 2018-04-02 05:03:57 UTC (rev 230148) +++ trunk/Source/WebInspectorUI/UserInterface/Views/NewTabContentView.js 2018-04-02 05:59:28 UTC (rev 230149) @@ -62,8 +62,8 @@ shown() { -WI.tabBrowser.tabBar.addEventListener(WI.TabBar.Event.TabBarItemAdded, this._updateTabItems, this); -WI.tabBrowser.tabBar.addEventListener(WI.TabBar.Event.TabBarItemRemoved, this._updateTabItems, this); +WI.tabBar.addEventListener(WI.TabBar.Event.TabBarItemAdded, this._updateTabItems, this); +WI.tabBar.addEventListener(WI.TabBar.Event.TabBarItemRemoved, this._updateTabItems, this); this._updateTabItems(); } @@ -70,7 +70,7 @@ hidden() { -WI.tabBrowser.tabBar.removeEventListener(null, null, this); +WI.tabBar.removeEventListener(null, null, this); } get supportsSplitContentBrowser() Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TabBrowser.js (230148 => 230149) --- trunk/Source/WebInspectorUI/UserInterface/Views/TabBrowser.js 2018-04-02 05:03:57 UTC (rev 230148) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TabBrowser.js 2018-04-02 05:59:28 UTC (rev 230149) @@ -157,8 +157,6 @@ if (tabBarItem.representedObject !== tabContentView) tabBarItem.representedObject = tabContentView; -tabContentView.parentTabBrowser = this; - if (tabBarItem.p
[webkit-changes] [228937] trunk/Source/WebKit
Title: [228937] trunk/Source/WebKit Revision 228937 Author mattba...@apple.com Date 2018-02-22 14:58:50 -0800 (Thu, 22 Feb 2018) Log Message Web Inspector: REGRESSION (r228349): ImageBitmap builtin is now runtime guarded https://bugs.webkit.org/show_bug.cgi?id=183056 Reviewed by Joseph Pecoraro. * WebProcess/WebPage/WebInspectorUI.cpp: (WebKit::WebInspectorUI::WebInspectorUI): Modified Paths trunk/Source/WebKit/ChangeLog trunk/Source/WebKit/WebProcess/WebPage/WebInspectorUI.cpp Diff Modified: trunk/Source/WebKit/ChangeLog (228936 => 228937) --- trunk/Source/WebKit/ChangeLog 2018-02-22 22:53:41 UTC (rev 228936) +++ trunk/Source/WebKit/ChangeLog 2018-02-22 22:58:50 UTC (rev 228937) @@ -1,3 +1,14 @@ +2018-02-22 Matt Baker + +Web Inspector: REGRESSION (r228349): ImageBitmap builtin is now runtime guarded +https://bugs.webkit.org/show_bug.cgi?id=183056 + + +Reviewed by Joseph Pecoraro. + +* WebProcess/WebPage/WebInspectorUI.cpp: +(WebKit::WebInspectorUI::WebInspectorUI): + 2018-02-22 Youenn Fablet Caches::initialize should call all pending initialization callbacks in case of error Modified: trunk/Source/WebKit/WebProcess/WebPage/WebInspectorUI.cpp (228936 => 228937) --- trunk/Source/WebKit/WebProcess/WebPage/WebInspectorUI.cpp 2018-02-22 22:53:41 UTC (rev 228936) +++ trunk/Source/WebKit/WebProcess/WebPage/WebInspectorUI.cpp 2018-02-22 22:58:50 UTC (rev 228937) @@ -50,6 +50,7 @@ , m_frontendAPIDispatcher(page) { RuntimeEnabledFeatures::sharedFeatures().setInspectorAdditionsEnabled(true); +RuntimeEnabledFeatures::sharedFeatures().setImageBitmapOffscreenCanvasEnabled(true); } void WebInspectorUI::establishConnection(IPC::Attachment encodedConnectionIdentifier, uint64_t inspectedPageIdentifier, bool underTest, unsigned inspectionLevel) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [228722] trunk/Source/WebInspectorUI
Title: [228722] trunk/Source/WebInspectorUI Revision 228722 Author mattba...@apple.com Date 2018-02-19 18:04:30 -0800 (Mon, 19 Feb 2018) Log Message Web Inspector: Canvas tab: hide navigation sidebar when viewing the overview https://bugs.webkit.org/show_bug.cgi?id=182597 Reviewed by Devin Rousso. Support showing/hiding the navigation sidebar panel based on the current represented object. Individual TabContentViews can opt-in to this behavior, by overriding TabContentView.prototype.managesNavigationSidebarPanel. * UserInterface/Views/CanvasSidebarPanel.js: (WI.CanvasSidebarPanel.prototype.canShowRepresentedObject): * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView.prototype.get managesNavigationSidebarPanel): Hide the Canvas navigation sidebar when viewing the overview. * UserInterface/Views/ContentBrowserTabContentView.js: (WI.ContentBrowserTabContentView): (WI.ContentBrowserTabContentView.prototype.showNavigationSidebarPanel): (WI.ContentBrowserTabContentView.prototype._navigationSidebarCollapsedStateDidChange): (WI.ContentBrowserTabContentView.prototype._contentBrowserCurrentRepresentedObjectsDidChange): * UserInterface/Views/NavigationSidebarPanel.js: (WI.NavigationSidebarPanel.prototype.canShowRepresentedObject): Provide default implementation that just defers to the TabContentView. This exists so that a NavigationSidebarPanel that implements canShowRepresentedObject will have a meaningful default to fall back on. * UserInterface/Views/TabBrowser.js: (WI.TabBrowser.prototype._sidebarCollapsedStateDidChange): (WI.TabBrowser.prototype._showNavigationSidebarPanelForTabContentView): * UserInterface/Views/TabContentView.js: (WI.TabContentView.prototype.get managesNavigationSidebarPanel): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CanvasSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/CanvasTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/ContentBrowserTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/NavigationSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBrowser.js trunk/Source/WebInspectorUI/UserInterface/Views/TabContentView.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (228721 => 228722) --- trunk/Source/WebInspectorUI/ChangeLog 2018-02-20 02:02:57 UTC (rev 228721) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-02-20 02:04:30 UTC (rev 228722) @@ -1,3 +1,40 @@ +2018-02-19 Matt Baker + +Web Inspector: Canvas tab: hide navigation sidebar when viewing the overview +https://bugs.webkit.org/show_bug.cgi?id=182597 + + +Reviewed by Devin Rousso. + +Support showing/hiding the navigation sidebar panel based on the current +represented object. Individual TabContentViews can opt-in to this behavior, +by overriding TabContentView.prototype.managesNavigationSidebarPanel. + +* UserInterface/Views/CanvasSidebarPanel.js: +(WI.CanvasSidebarPanel.prototype.canShowRepresentedObject): +* UserInterface/Views/CanvasTabContentView.js: +(WI.CanvasTabContentView.prototype.get managesNavigationSidebarPanel): +Hide the Canvas navigation sidebar when viewing the overview. + +* UserInterface/Views/ContentBrowserTabContentView.js: +(WI.ContentBrowserTabContentView): +(WI.ContentBrowserTabContentView.prototype.showNavigationSidebarPanel): +(WI.ContentBrowserTabContentView.prototype._navigationSidebarCollapsedStateDidChange): +(WI.ContentBrowserTabContentView.prototype._contentBrowserCurrentRepresentedObjectsDidChange): + +* UserInterface/Views/NavigationSidebarPanel.js: +(WI.NavigationSidebarPanel.prototype.canShowRepresentedObject): +Provide default implementation that just defers to the TabContentView. +This exists so that a NavigationSidebarPanel that implements canShowRepresentedObject +will have a meaningful default to fall back on. + +* UserInterface/Views/TabBrowser.js: +(WI.TabBrowser.prototype._sidebarCollapsedStateDidChange): +(WI.TabBrowser.prototype._showNavigationSidebarPanelForTabContentView): + +* UserInterface/Views/TabContentView.js: +(WI.TabContentView.prototype.get managesNavigationSidebarPanel): + 2018-02-16 Matt Baker Web Inspector: TabBar redesign: remove top-level search field and pin the Search tab Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CanvasSidebarPanel.js (228721 => 228722) --- trunk/Source/WebInspectorUI/UserInterface/Views/CanvasSidebarPanel.js 2018-02-20 02:02:57 UTC (rev 228721) +++ trunk/Source/WebInspectorUI/UserInterface/Views/CanvasSidebarPanel.js 2018-02-20 02:04:30 UTC (rev 228722) @@ -151,6 +151,14 @@ super.hidden(); } +canShowRepresentedObject(representedObject) +{ +if (representedObject instanceof WI.CanvasCollection) +
[webkit-changes] [228581] trunk/Source/WebInspectorUI
Title: [228581] trunk/Source/WebInspectorUI Revision 228581 Author mattba...@apple.com Date 2018-02-16 14:06:01 -0800 (Fri, 16 Feb 2018) Log Message Web Inspector: TabBar redesign: remove top-level search field and pin the Search tab https://bugs.webkit.org/show_bug.cgi?id=182353 Reviewed by Devin Rousso. * Localizations/en.lproj/localizedStrings.js: * UserInterface/Base/Main.js: (WI.contentLoaded): Create Search UI based on experimental setting. When the new TabBar is enabled, the Search tab is a pinned tab. Since it is also saveable, it needs to be added to the TabBrowser (the browser adds the item to the bar). When restoring saved tabs, make an additional check to prevent a tab from being added twice. This can occur now that the Search tab is pinned. * UserInterface/Images/Search.svg: Update art to better match Safari/macOS. Slightly increase the radius of the lens, and shorten the length of the handle. * UserInterface/Views/GoToLineDialog.css: (.go-to-line-dialog > div::before): Update styles for new Search icon. * UserInterface/Views/LegacyTabBar.js: (WI.LegacyTabBar.prototype.get saveableTabCount): Backported new TabBar method which is called by TabBrowser. * UserInterface/Views/OpenResourceDialog.css: (.open-resource-dialog > .field::before): Update styles for new Search icon. * UserInterface/Views/PinnedTabBarItem.js: (WI.PinnedTabBarItem.prototype.fromTabInfo): Match GeneralTabBarItem.fromTabInfo. * UserInterface/Views/SearchTabContentView.js: (WI.SearchTabContentView): (WI.SearchTabContentView.tabInfo): New image (magnifying glass without border) when new TabBar is enabled. * UserInterface/Views/SettingsTabContentView.js: (WI.SettingsTabContentView): * UserInterface/Views/TabBar.js: (WI.TabBar): Move creation of the Settings item out of TabBar. The TabBar should only be concerned with managing tabs. (WI.TabBar.prototype.get saveableTabCount): (WI.TabBar.prototype._handleContextMenu): (WI.TabBar.prototype.get normalNonEphemeralTabCount): Deleted. Now that the Search tab is pinned, there aren't any normal tabs that are also ephemeral. For the LegacyTabBar, both the Search and New Tab tabs are still in this category. * UserInterface/Views/TabBrowser.js: (WI.TabBrowser.prototype.addTabForContentView): (WI.TabBrowser.prototype.closeTabForContentView): (WI.TabBrowser.prototype._tabBarItemSelected): (WI.TabBrowser._tabBarItemRemoved): Recent tab list should be validated against the list of saveable tabs, since the Search tab is no longer a normal tab (a GeneralTabBarItem), but is still persisted across Inspector sessions. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js trunk/Source/WebInspectorUI/UserInterface/Base/Main.js trunk/Source/WebInspectorUI/UserInterface/Images/Search.svg trunk/Source/WebInspectorUI/UserInterface/Views/GoToLineDialog.css trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js trunk/Source/WebInspectorUI/UserInterface/Views/OpenResourceDialog.css trunk/Source/WebInspectorUI/UserInterface/Views/PinnedTabBarItem.js trunk/Source/WebInspectorUI/UserInterface/Views/SearchTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/SettingsTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBrowser.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (228580 => 228581) --- trunk/Source/WebInspectorUI/ChangeLog 2018-02-16 21:56:16 UTC (rev 228580) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-02-16 22:06:01 UTC (rev 228581) @@ -1,5 +1,73 @@ 2018-02-16 Matt Baker +Web Inspector: TabBar redesign: remove top-level search field and pin the Search tab +https://bugs.webkit.org/show_bug.cgi?id=182353 + + +Reviewed by Devin Rousso. + +* Localizations/en.lproj/localizedStrings.js: + +* UserInterface/Base/Main.js: +(WI.contentLoaded): +Create Search UI based on experimental setting. When the new TabBar is +enabled, the Search tab is a pinned tab. Since it is also saveable, it +needs to be added to the TabBrowser (the browser adds the item to the bar). + +When restoring saved tabs, make an additional check to prevent a tab +from being added twice. This can occur now that the Search tab is pinned. + +* UserInterface/Images/Search.svg: +Update art to better match Safari/macOS. Slightly increase the radius of +the lens, and shorten the length of the handle. + +* UserInterface/Views/GoToLineDialog.css: +(.go-to-line-dialog > div::before): +Update styles for new Search icon. + +* UserInterface/Views/LegacyTabBar.js: +(WI.LegacyTabBar.prototype.get saveableTabCount): +Backported new TabBar method which is called by TabBrowser. + +* UserInterface/Views/OpenResourceDialog.css: +(.open-resource-dialog > .field::before):
[webkit-changes] [228573] trunk/Source/WebInspectorUI
Title: [228573] trunk/Source/WebInspectorUI Revision 228573 Author mattba...@apple.com Date 2018-02-16 12:59:55 -0800 (Fri, 16 Feb 2018) Log Message Web Inspector: TabBar redesign: TabBarItem close button is incorrectly positioned https://bugs.webkit.org/show_bug.cgi?id=182844 Reviewed by Timothy Hatcher. * UserInterface/Views/GeneralTabBarItem.js: (WI.GeneralTabBarItem.prototype.set title): Insert the title before the last flexible space item. * UserInterface/Views/TabBar.css: (.tab-bar > .item): (.tab-bar > .item > .close): (.tab-bar > .item > .flex-space): (.tab-bar > .item.ephemeral > .flex-space:last-child): (.tab-bar.collapsed > .item): (.tab-bar.collapsed > .item > .flex-space): (.tab-bar.collapsed > .item > .close): (.tab-bar.collapsed > .item:hover > .close): (.tab-bar.collapsed > .item.ephemeral:hover > .icon): (.tab-bar > .item:hover > .close): Deleted. (.tab-bar:not(.collapsed) > .item.ephemeral:hover > .icon): Deleted. * UserInterface/Views/TabBarItem.js: (WI.TabBarItem): Restore flexible space items before and after the icon. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/GeneralTabBarItem.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.css trunk/Source/WebInspectorUI/UserInterface/Views/TabBarItem.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (228572 => 228573) --- trunk/Source/WebInspectorUI/ChangeLog 2018-02-16 20:43:28 UTC (rev 228572) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-02-16 20:59:55 UTC (rev 228573) @@ -1,3 +1,32 @@ +2018-02-16 Matt Baker + +Web Inspector: TabBar redesign: TabBarItem close button is incorrectly positioned +https://bugs.webkit.org/show_bug.cgi?id=182844 + + +Reviewed by Timothy Hatcher. + +* UserInterface/Views/GeneralTabBarItem.js: +(WI.GeneralTabBarItem.prototype.set title): +Insert the title before the last flexible space item. + +* UserInterface/Views/TabBar.css: +(.tab-bar > .item): +(.tab-bar > .item > .close): +(.tab-bar > .item > .flex-space): +(.tab-bar > .item.ephemeral > .flex-space:last-child): +(.tab-bar.collapsed > .item): +(.tab-bar.collapsed > .item > .flex-space): +(.tab-bar.collapsed > .item > .close): +(.tab-bar.collapsed > .item:hover > .close): +(.tab-bar.collapsed > .item.ephemeral:hover > .icon): +(.tab-bar > .item:hover > .close): Deleted. +(.tab-bar:not(.collapsed) > .item.ephemeral:hover > .icon): Deleted. + +* UserInterface/Views/TabBarItem.js: +(WI.TabBarItem): +Restore flexible space items before and after the icon. + 2018-02-14 Nikita Vasilyev Web Inspector: Styles: completion popover doesn't hide when switching panels Modified: trunk/Source/WebInspectorUI/UserInterface/Views/GeneralTabBarItem.js (228572 => 228573) --- trunk/Source/WebInspectorUI/UserInterface/Views/GeneralTabBarItem.js 2018-02-16 20:43:28 UTC (rev 228572) +++ trunk/Source/WebInspectorUI/UserInterface/Views/GeneralTabBarItem.js 2018-02-16 20:59:55 UTC (rev 228573) @@ -69,7 +69,7 @@ titleContentElement.textContent = title; this._titleElement.appendChild(titleContentElement); -this.element.appendChild(this._titleElement); +this.element.insertBefore(this._titleElement, this.element.lastChild); } else { if (this._titleElement) this._titleElement.remove(); Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.css (228572 => 228573) --- trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.css 2018-02-16 20:43:28 UTC (rev 228572) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.css 2018-02-16 20:59:55 UTC (rev 228573) @@ -84,7 +84,6 @@ z-index: 1; -justify-content: center; align-items: center; padding: 0 6px; @@ -192,6 +191,8 @@ transition-property: background-color, opacity; transition-duration: 250ms, 500ms; transition-delay: 0, 50ms; + +-webkit-margin-end: 4px; } body:not(.window-inactive) .tab-bar > .item:hover > .close { @@ -214,6 +215,15 @@ opacity: 0.8 !important; } +.tab-bar > .item > .flex-space { +display: flex; +flex: 1; +} + +.tab-bar > .item.ephemeral > .flex-space:last-child { +-webkit-margin-end: 16px; +} + .tab-bar > .item > .icon { width: 16px; height: 16px; @@ -274,24 +284,29 @@ color: hsla(0, 0%, 0%, 0.7); } +.tab-bar.collapsed > .item { +justify-content: center; +} + .tab-bar.collapsed > .item:not(.pinned) > .icon { display: none; } -.tab-bar > .item > .close { +.tab-bar.collapsed > .item > .flex-space { display: none; } -.tab-bar > .item:hover > .close { -display: inline-block; +.tab-bar.collapsed > .item > .close { +display: none; +-webkit-margin-end: 0; } .tab-bar.collapsed > .item:hover > .close { +display: inline-blo
[webkit-changes] [228479] trunk/Source/WebInspectorUI
Title: [228479] trunk/Source/WebInspectorUI Revision 228479 Author mattba...@apple.com Date 2018-02-14 12:17:30 -0800 (Wed, 14 Feb 2018) Log Message Web Inspector: TabBar redesign: only show allowed tabs in the available tabs context menu https://bugs.webkit.org/show_bug.cgi?id=182721 Reviewed by Timothy Hatcher. In addition to only including allowed tabs in the TabBar context menu, perform a sanity check when setting the selected tab item, since the serialized selection index could refer to a tab that is no longer allowed. * UserInterface/Views/LegacyTabBar.js: (WI.LegacyTabBar.prototype.set selectedTabBarItem): (WI.LegacyTabBar.prototype._handleContextMenu): * UserInterface/Views/TabBar.js: (WI.TabBar.prototype.set selectedTabBarItem): (WI.TabBar.prototype._handleContextMenu): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (228478 => 228479) --- trunk/Source/WebInspectorUI/ChangeLog 2018-02-14 19:47:57 UTC (rev 228478) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-02-14 20:17:30 UTC (rev 228479) @@ -1,3 +1,23 @@ +2018-02-14 Matt Baker + +Web Inspector: TabBar redesign: only show allowed tabs in the available tabs context menu +https://bugs.webkit.org/show_bug.cgi?id=182721 + + +Reviewed by Timothy Hatcher. + +In addition to only including allowed tabs in the TabBar context menu, +perform a sanity check when setting the selected tab item, since the +serialized selection index could refer to a tab that is no longer allowed. + +* UserInterface/Views/LegacyTabBar.js: +(WI.LegacyTabBar.prototype.set selectedTabBarItem): +(WI.LegacyTabBar.prototype._handleContextMenu): + +* UserInterface/Views/TabBar.js: +(WI.TabBar.prototype.set selectedTabBarItem): +(WI.TabBar.prototype._handleContextMenu): + 2018-02-09 Matt Baker Web Inspector: Canvas tab: tree selection abruptly changes when selecting a recording frame Modified: trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js (228478 => 228479) --- trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js 2018-02-14 19:47:57 UTC (rev 228478) +++ trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js 2018-02-14 20:17:30 UTC (rev 228479) @@ -364,8 +364,8 @@ set selectedTabBarItem(tabBarItemOrIndex) { let tabBarItem = this._findTabBarItem(tabBarItemOrIndex); -if (tabBarItem === this._newTabTabBarItem) { -// Get the item before the New-Tab item since it is not selectable. +if (tabBarItem === this._newTabTabBarItem || tabBarItem === this._tabPickerTabBarItem) { +// Get the last normal tab item if the item is not selectable. tabBarItem = this._tabBarItems[this.normalTabCount - 1]; } @@ -804,7 +804,7 @@ let contextMenu = WI.ContextMenu.createFromEvent(event); for (let tabClass of WI.knownTabClasses()) { -if (tabClass.tabInfo().isEphemeral) +if (!tabClass.isTabAllowed() || tabClass.tabInfo().isEphemeral) continue; let openTabBarItem = null; Modified: trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js (228478 => 228479) --- trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js 2018-02-14 19:47:57 UTC (rev 228478) +++ trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js 2018-02-14 20:17:30 UTC (rev 228479) @@ -336,6 +336,11 @@ set selectedTabBarItem(tabBarItemOrIndex) { let tabBarItem = this._findTabBarItem(tabBarItemOrIndex); +if (tabBarItem === this._tabPickerTabBarItem) { +// Get the last normal tab item if the item is not selectable. +tabBarItem = this._tabBarItems[this.normalTabCount - 1]; +} + if (this._selectedTabBarItem === tabBarItem) return; @@ -767,7 +772,7 @@ let contextMenu = WI.ContextMenu.createFromEvent(event); for (let tabClass of WI.knownTabClasses()) { -if (tabClass.tabInfo().isEphemeral) +if (!tabClass.isTabAllowed() || tabClass.tabInfo().isEphemeral) continue; let openTabBarItem = null; ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [228362] trunk/Source/WebInspectorUI
Title: [228362] trunk/Source/WebInspectorUI Revision 228362 Author mattba...@apple.com Date 2018-02-09 22:15:46 -0800 (Fri, 09 Feb 2018) Log Message Web Inspector: Canvas tab: tree selection abruptly changes when selecting a recording frame https://bugs.webkit.org/show_bug.cgi?id=182667 Reviewed by Devin Rousso. * UserInterface/Views/CanvasSidebarPanel.css: (.sidebar > .panel.navigation.canvas > .content > .recording-content > .navigation-bar): (.sidebar > .panel.navigation.canvas:not(.has-recordings) > .filter-bar,): (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.recording > .icon): (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.folder-icon > .icon): (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.folder-icon > .status): (.sidebar > .panel.navigation.canvas > .content > .navigation-bar): Deleted. (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.recording > .icon): Deleted. (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .icon): Deleted. (.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .status): Deleted. Style changes for the additional DOM element required to virtualize the recording tree outline. * UserInterface/Views/CanvasSidebarPanel.js: (WI.CanvasSidebarPanel): In order to be virtualized, the tree must be the only child of its parent. (WI.CanvasSidebarPanel.prototype.set action): Ensure that a frame tree element isn't deselected when the last action in the frame becomes selected in the RecordingContentView. (WI.CanvasSidebarPanel.prototype.shown): Refresh the sidebar, as represented objects may have changed while hidden. (WI.CanvasSidebarPanel.prototype._currentRepresentedObjectsDidChange): Unset the recording when no valid represented objects are found, to prevent a stale recording tree from being shown when viewing the overview. (WI.CanvasSidebarPanel.prototype._canvasChanged): (WI.CanvasSidebarPanel.prototype._recordingChanged): (WI.CanvasSidebarPanel.prototype._updateRecordingScopeBar): Moved toggling of the "has-recordings" style to _canvasChanged, since the navigation bar should be hidden when no canvas exists. * UserInterface/Views/CollectionContentView.js: (WI.CollectionContentView.prototype.addContentViewForItem): (WI.CollectionContentView.prototype.removeContentViewForItem): Drive by fixes for child view visible state. * UserInterface/Views/TreeOutline.css: (.tree-outline:not(.large):matches(:focus, .force-focus) .item.selected .status .indeterminate-progress-spinner): Make spinner easier to see against the selection background color. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CanvasSidebarPanel.css trunk/Source/WebInspectorUI/UserInterface/Views/CanvasSidebarPanel.js trunk/Source/WebInspectorUI/UserInterface/Views/CollectionContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/TreeOutline.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (228361 => 228362) --- trunk/Source/WebInspectorUI/ChangeLog 2018-02-10 06:14:52 UTC (rev 228361) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-02-10 06:15:46 UTC (rev 228362) @@ -1,5 +1,55 @@ 2018-02-09 Matt Baker +Web Inspector: Canvas tab: tree selection abruptly changes when selecting a recording frame +https://bugs.webkit.org/show_bug.cgi?id=182667 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/CanvasSidebarPanel.css: +(.sidebar > .panel.navigation.canvas > .content > .recording-content > .navigation-bar): +(.sidebar > .panel.navigation.canvas:not(.has-recordings) > .filter-bar,): +(.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.recording > .icon): +(.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.folder-icon > .icon): +(.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline .item.folder-icon > .status): +(.sidebar > .panel.navigation.canvas > .content > .navigation-bar): Deleted. +(.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.recording > .icon): Deleted. +(.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .icon): Deleted. +(.sidebar > .panel.navigation.canvas > .content > .tree-outline .item.folder-icon > .status): Deleted. +Style changes for the additional DOM element required to virtualize the recording tree outline. + +* UserInterface/Views/CanvasSidebarPanel.js: +(WI.CanvasSidebarPanel): +In order to be virtualized, the tree must be the only child of its parent. + +(WI.CanvasSidebarPanel.prototype.set action): +Ensure that a frame tree element isn't deselected when the last action +
[webkit-changes] [228336] trunk
Title: [228336] trunk Revision 228336 Author mattba...@apple.com Date 2018-02-09 12:40:10 -0800 (Fri, 09 Feb 2018) Log Message Web Inspector: Object.shallowEqual always fails when comparing array property values https://bugs.webkit.org/show_bug.cgi?id=182634 Reviewed by Devin Rousso. Source/WebInspectorUI: Object.shallowEqual should use Array.shallowEqual when comparing property values, since strictly comparing objects/arrays is only true if both operands reference the same Object. * UserInterface/Base/Utilities.js: (value): LayoutTests: * inspector/unit-tests/object-utilities-expected.txt: * inspector/unit-tests/object-utilities.html: Modified Paths trunk/LayoutTests/ChangeLog trunk/LayoutTests/inspector/unit-tests/object-utilities-expected.txt trunk/LayoutTests/inspector/unit-tests/object-utilities.html trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/Utilities.js Diff Modified: trunk/LayoutTests/ChangeLog (228335 => 228336) --- trunk/LayoutTests/ChangeLog 2018-02-09 20:06:02 UTC (rev 228335) +++ trunk/LayoutTests/ChangeLog 2018-02-09 20:40:10 UTC (rev 228336) @@ -1,3 +1,14 @@ +2018-02-09 Matt Baker + +Web Inspector: Object.shallowEqual always fails when comparing array property values +https://bugs.webkit.org/show_bug.cgi?id=182634 + + +Reviewed by Devin Rousso. + +* inspector/unit-tests/object-utilities-expected.txt: +* inspector/unit-tests/object-utilities.html: + 2018-02-09 Andy Estes [Payment Request] Crash in PaymentRequest::canMakePayment() when Apple Pay payment method data is missing required fields Modified: trunk/LayoutTests/inspector/unit-tests/object-utilities-expected.txt (228335 => 228336) --- trunk/LayoutTests/inspector/unit-tests/object-utilities-expected.txt 2018-02-09 20:06:02 UTC (rev 228335) +++ trunk/LayoutTests/inspector/unit-tests/object-utilities-expected.txt 2018-02-09 20:40:10 UTC (rev 228336) @@ -9,6 +9,11 @@ PASS: shallowEqual of equal objects should be true. PASS: shallowEqual of unequal objects should be false. PASS: shallowEqual of unequal objects should be false. +PASS: shallowEqual of objects with similar arrays at the same key should be true. +PASS: shallowEqual of objects with similar arrays at the same key should be true. +PASS: shallowEqual of objects with similar arrays at the same key should be true. +PASS: shallowEqual of objects with dissimilar arrays at the same key should be false. +PASS: shallowEqual of objects with dissimilar arrays at the same key should be false. PASS: shallowEqual of an object and null should be false. PASS: shallowEqual of an object and non-object should be false. PASS: shallowEqual of a non-object with itself should be false. Modified: trunk/LayoutTests/inspector/unit-tests/object-utilities.html (228335 => 228336) --- trunk/LayoutTests/inspector/unit-tests/object-utilities.html 2018-02-09 20:06:02 UTC (rev 228335) +++ trunk/LayoutTests/inspector/unit-tests/object-utilities.html 2018-02-09 20:40:10 UTC (rev 228336) @@ -26,6 +26,13 @@ InspectorTest.expectThat(!Object.shallowEqual(obj1, obj3), "shallowEqual of unequal objects should be false."); InspectorTest.expectThat(!Object.shallowEqual(obj3, obj1), "shallowEqual of unequal objects should be false."); +InspectorTest.expectThat(Object.shallowEqual({x: []}, {x: []}), "shallowEqual of objects with similar arrays at the same key should be true."); +InspectorTest.expectThat(Object.shallowEqual({x: new Array}, {x: new Array}), "shallowEqual of objects with similar arrays at the same key should be true."); +InspectorTest.expectThat(Object.shallowEqual({x: [1]}, {x: [1]}), "shallowEqual of objects with similar arrays at the same key should be true."); + +InspectorTest.expectThat(!Object.shallowEqual({x: [1]}, {x: []}), "shallowEqual of objects with dissimilar arrays at the same key should be false."); +InspectorTest.expectThat(!Object.shallowEqual({x: new Array(1)}, {x: new Array}), "shallowEqual of objects with dissimilar arrays at the same key should be false."); + InspectorTest.expectThat(!Object.shallowEqual({}, null), "shallowEqual of an object and null should be false."); InspectorTest.expectThat(!Object.shallowEqual({}, 1.23), "shallowEqual of an object and non-object should be false."); Modified: trunk/Source/WebInspectorUI/ChangeLog (228335 => 228336) --- trunk/Source/WebInspectorUI/ChangeLog 2018-02-09 20:06:02 UTC (rev 228335) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-02-09 20:40:10 UTC (rev 228336) @@ -1,3 +1,18 @@ +2018-02-09 Matt Baker + +Web Inspector: Object.shallowEqual always fails when comparing array property values +https://bugs.webkit.org/show_bug.cgi?id=182634 + + +Reviewed by Devin Rousso. + +Object.shallowEqual should use Array.shallowEqual when comparing property +
[webkit-changes] [228251] trunk/Source/WebInspectorUI
Title: [228251] trunk/Source/WebInspectorUI Revision 228251 Author mattba...@apple.com Date 2018-02-07 16:58:25 -0800 (Wed, 07 Feb 2018) Log Message Web Inspector: replace isAncestor with Node.contains() in LegacyTabBar https://bugs.webkit.org/show_bug.cgi?id=182586 Reviewed by Timothy Hatcher. * UserInterface/Views/LegacyTabBar.js: Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (228250 => 228251) --- trunk/Source/WebInspectorUI/ChangeLog 2018-02-08 00:39:17 UTC (rev 228250) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-02-08 00:58:25 UTC (rev 228251) @@ -1,3 +1,12 @@ +2018-02-07 Matt Baker + +Web Inspector: replace isAncestor with Node.contains() in LegacyTabBar +https://bugs.webkit.org/show_bug.cgi?id=182586 + +Reviewed by Timothy Hatcher. + +* UserInterface/Views/LegacyTabBar.js: + 2018-02-07 Nikita Vasilyev Web Inspector: Styles: completion popover doesn't hide when switching panels Modified: trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js (228250 => 228251) --- trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js 2018-02-08 00:39:17 UTC (rev 228250) +++ trunk/Source/WebInspectorUI/UserInterface/Views/LegacyTabBar.js 2018-02-08 00:58:25 UTC (rev 228251) @@ -112,7 +112,7 @@ var nextSibling = this._tabBarItems[index + 1]; let nextSiblingElement = nextSibling ? nextSibling.element : this._tabBarItems.lastValue.element; -if (this.element.isAncestor(nextSiblingElement)) +if (this.element.contains(nextSiblingElement)) this.element.insertBefore(tabBarItem.element, nextSiblingElement); else this.element.appendChild(tabBarItem.element); ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [228024] trunk/Source/WebInspectorUI
Title: [228024] trunk/Source/WebInspectorUI Revision 228024 Author mattba...@apple.com Date 2018-02-02 13:04:52 -0800 (Fri, 02 Feb 2018) Log Message Web Inspector: TabBar redesign: remove New Tab button and add experimental feature flag https://bugs.webkit.org/show_bug.cgi?id=182342 Reviewed by Devin Rousso. This patch adds a new experimental setting group, "User Interface", with a single setting, "Enable New TabBar". When enabled, the New Tab button is no longer available in the top-level TabBar. The 'open tabs' context menu no longer allows the last non-ephemeral open tab to be closed (unchecked). * Localizations/en.lproj/localizedStrings.js: * UserInterface/Base/Main.js: (WI.contentLoaded): (WI._tryToRestorePendingTabs): Retain legacy behavior behind experimental feature setting. (WI.isNewTabWithTypeAllowed): * UserInterface/Base/Setting.js: * UserInterface/Main.html: * UserInterface/Views/CanvasTabContentView.js: (WI.CanvasTabContentView): * UserInterface/Views/ConsoleTabContentView.js: (WI.ConsoleTabContentView): * UserInterface/Views/DebuggerTabContentView.js: (WI.DebuggerTabContentView): * UserInterface/Views/ElementsTabContentView.js: (WI.ElementsTabContentView): * UserInterface/Views/GeneralTabBarItem.js: (WI.GeneralTabBarItem): (WI.GeneralTabBarItem.prototype.fromTabInfo): (WI.GeneralTabBarItem.prototype.get isEphemeral): (WI.GeneralTabBarItem.fromTabContentViewConstructor): Deleted. * UserInterface/Views/LayersTabContentView.js: (WI.LayersTabContentView): * UserInterface/Views/LegacyTabBar.js: Copied from Source/WebInspectorUI/UserInterface/Views/TabBar.js. (WI.LegacyTabBar): (WI.LegacyTabBar.prototype.get newTabTabBarItem): (WI.LegacyTabBar.prototype.updateNewTabTabBarItemState): (WI.LegacyTabBar.prototype.addTabBarItem): (WI.LegacyTabBar.prototype.insertTabBarItem.animateTabs): (WI.LegacyTabBar.prototype.insertTabBarItem.removeStyles): (WI.LegacyTabBar.prototype.insertTabBarItem): (WI.LegacyTabBar.prototype.removeTabBarItem.animateTabs): (WI.LegacyTabBar.prototype.removeTabBarItem.removeStyles): (WI.LegacyTabBar.prototype.removeTabBarItem): (WI.LegacyTabBar.prototype.selectPreviousTab): (WI.LegacyTabBar.prototype.selectNextTab): (WI.LegacyTabBar.prototype.get selectedTabBarItem): (WI.LegacyTabBar.prototype.set selectedTabBarItem): (WI.LegacyTabBar.prototype.get tabBarItems): (WI.LegacyTabBar.prototype.get normalTabCount): (WI.LegacyTabBar.prototype.layout.forceItemHidden): (WI.LegacyTabBar.prototype.layout): (WI.LegacyTabBar.prototype._tabBarItemsFromLeftToRight): (WI.LegacyTabBar.prototype._findTabBarItem): (WI.LegacyTabBar.prototype._hasMoreThanOneNormalTab): (WI.LegacyTabBar.prototype._openDefaultTab): (WI.LegacyTabBar.prototype._recordTabBarItemSizesAndPositions): (WI.LegacyTabBar.prototype._applyTabBarItemSizesAndPositions): (WI.LegacyTabBar.prototype._clearTabBarItemSizesAndPositions): (WI.LegacyTabBar.prototype._finishExpandingTabsAfterClose.): (WI.LegacyTabBar.prototype._finishExpandingTabsAfterClose): (WI.LegacyTabBar.prototype._handleMouseDown): (WI.LegacyTabBar.prototype._handleClick): (WI.LegacyTabBar.prototype._handleMouseMoved): (WI.LegacyTabBar.prototype._handleMouseUp): (WI.LegacyTabBar.prototype._handleMouseLeave): (WI.LegacyTabBar.prototype._handleContextMenu): (WI.LegacyTabBar.prototype._handleNewTabClick): (WI.LegacyTabBar.prototype._handleTabPickerTabContextMenu): (WI.LegacyTabBar.prototype._handleNewTabMouseEnter): * UserInterface/Views/NetworkTabContentView.js: (WI.NetworkTabContentView): * UserInterface/Views/NewTabContentView.js: (WI.NewTabContentView): (WI.NewTabContentView.tabInfo): (WI.NewTabContentView.isEphemeral): Deleted. * UserInterface/Views/ResourcesTabContentView.js: (WI.ResourcesTabContentView): * UserInterface/Views/SearchTabContentView.js: (WI.SearchTabContentView): (WI.SearchTabContentView.tabInfo): (WI.SearchTabContentView.isEphemeral): Deleted. * UserInterface/Views/SettingsTabContentView.js: (WI.SettingsTabContentView.tabInfo): (WI.SettingsTabContentView.prototype._createExperimentalSettingsView): (WI.SettingsTabContentView.isEphemeral): Deleted. * UserInterface/Views/StorageTabContentView.js: (WI.StorageTabContentView): * UserInterface/Views/TabBar.css: * UserInterface/Views/TabBar.js: (WI.TabBar): (WI.TabBar.prototype.insertTabBarItem): (WI.TabBar.prototype.removeTabBarItem): (WI.TabBar.prototype.set selectedTabBarItem): (WI.TabBar.prototype.get normalNonEphemeralTabCount): (WI.TabBar.prototype._handleMouseDown): (WI.TabBar.prototype._handleClick): (WI.TabBar.prototype._handleMouseMoved): (WI.TabBar.prototype._handleMouseLeave): (WI.TabBar.prototype._handleContextMenu): (WI.TabBar.prototype._handleTabPickerTabContextMenu): (WI.TabBar.prototype.get newTabTabBarItem): Deleted. (WI.TabBar.prototype.updateNewTabTabBarItemState): Deleted. (WI.TabBar.prototype._openDefaultTab): Deleted. (WI.TabBar.prototype._handleNewTabClick): Deleted. (WI.TabBar.prototype._handleNewTabMouseEnter): Deleted. Remove support for the New Tab button an
[webkit-changes] [227707] trunk/Source/WebInspectorUI
Title: [227707] trunk/Source/WebInspectorUI Revision 227707 Author mattba...@apple.com Date 2018-01-26 17:36:36 -0800 (Fri, 26 Jan 2018) Log Message Web Inspector: Timelines content browser NavigationBar is squashed at narrow heights https://bugs.webkit.org/show_bug.cgi?id=182196 Reviewed by Joseph Pecoraro. * UserInterface/Views/NavigationBar.css: (.navigation-bar): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/NavigationBar.css Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (227706 => 227707) --- trunk/Source/WebInspectorUI/ChangeLog 2018-01-27 01:35:47 UTC (rev 227706) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-01-27 01:36:36 UTC (rev 227707) @@ -1,5 +1,16 @@ 2018-01-26 Matt Baker +Web Inspector: Timelines content browser NavigationBar is squashed at narrow heights +https://bugs.webkit.org/show_bug.cgi?id=182196 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/NavigationBar.css: +(.navigation-bar): + +2018-01-26 Matt Baker + Web Inspector: TabBar redesign: improvements to tab layout and resize behavior https://bugs.webkit.org/show_bug.cgi?id=181468 Modified: trunk/Source/WebInspectorUI/UserInterface/Views/NavigationBar.css (227706 => 227707) --- trunk/Source/WebInspectorUI/UserInterface/Views/NavigationBar.css 2018-01-27 01:35:47 UTC (rev 227706) +++ trunk/Source/WebInspectorUI/UserInterface/Views/NavigationBar.css 2018-01-27 01:36:36 UTC (rev 227707) @@ -27,6 +27,7 @@ display: flex; justify-content: center; align-items: center; +flex-shrink: 0; flex-wrap: wrap; border-bottom: 1px solid var(--border-color); ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [227243] trunk/Source/WebInspectorUI
Title: [227243] trunk/Source/WebInspectorUI Revision 227243 Author mattba...@apple.com Date 2018-01-19 15:01:11 -0800 (Fri, 19 Jan 2018) Log Message Web Inspector: Canvas Tab: Multiple "waiting for frames" messages displayed https://bugs.webkit.org/show_bug.cgi?id=181865 Reviewed by Devin Rousso. * UserInterface/Views/CanvasContentView.js: (WI.CanvasContentView.prototype._recordingStarted): (WI.CanvasContentView.prototype._recordingStopped): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CanvasContentView.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (227242 => 227243) --- trunk/Source/WebInspectorUI/ChangeLog 2018-01-19 22:58:48 UTC (rev 227242) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-01-19 23:01:11 UTC (rev 227243) @@ -1,3 +1,15 @@ +2018-01-19 Matt Baker + +Web Inspector: Canvas Tab: Multiple "waiting for frames" messages displayed +https://bugs.webkit.org/show_bug.cgi?id=181865 + + +Reviewed by Devin Rousso. + +* UserInterface/Views/CanvasContentView.js: +(WI.CanvasContentView.prototype._recordingStarted): +(WI.CanvasContentView.prototype._recordingStopped): + 2018-01-19 Nikita Vasilyev Web Inspector: Styles Redesign: tabbing on commented out property throws exception Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CanvasContentView.js (227242 => 227243) --- trunk/Source/WebInspectorUI/UserInterface/Views/CanvasContentView.js 2018-01-19 22:58:48 UTC (rev 227242) +++ trunk/Source/WebInspectorUI/UserInterface/Views/CanvasContentView.js 2018-01-19 23:01:11 UTC (rev 227243) @@ -263,6 +263,9 @@ { this._updateRecordNavigationItem(); +if (!this.representedObject.isRecording) +return; + if (!this._recordingProgressElement) { this._recordingProgressElement = this._previewContainerElement.insertAdjacentElement("beforebegin", document.createElement("div")); this._recordingProgressElement.className = "progress"; @@ -297,13 +300,16 @@ this._updateRecordNavigationItem(); let {canvas, recording} = event.data; -if (canvas !== this.representedObject || !recording) +if (canvas !== this.representedObject) return; -this._addRecording(recording); +if (recording) +this._addRecording(recording); -this._recordingProgressElement.remove(); -this._recordingProgressElement = null; +if (this._recordingProgressElement) { +this._recordingProgressElement.remove(); +this._recordingProgressElement = null; +} } _handleRecordingSelectElementChange(event) ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [227008] trunk/Source/WebInspectorUI
Title: [227008] trunk/Source/WebInspectorUI Revision 227008 Author mattba...@apple.com Date 2018-01-16 15:17:36 -0800 (Tue, 16 Jan 2018) Log Message Web Inspector: Canvas tab: typing a "space" in the QuickConsole shouldn't trigger a recording https://bugs.webkit.org/show_bug.cgi?id=181706 Reviewed by Joseph Pecoraro. * UserInterface/Views/CanvasOverviewContentView.js: (WI.CanvasOverviewContentView): (WI.CanvasOverviewContentView.prototype._handleSpace): Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Views/CanvasOverviewContentView.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (227007 => 227008) --- trunk/Source/WebInspectorUI/ChangeLog 2018-01-16 23:08:44 UTC (rev 227007) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-01-16 23:17:36 UTC (rev 227008) @@ -1,3 +1,15 @@ +2018-01-16 Matt Baker + +Web Inspector: Canvas tab: typing a "space" in the QuickConsole shouldn't trigger a recording +https://bugs.webkit.org/show_bug.cgi?id=181706 + + +Reviewed by Joseph Pecoraro. + +* UserInterface/Views/CanvasOverviewContentView.js: +(WI.CanvasOverviewContentView): +(WI.CanvasOverviewContentView.prototype._handleSpace): + 2018-01-16 Joseph Pecoraro Web Inspector: Make Console's Execution Context picker stand out when it is non-default Modified: trunk/Source/WebInspectorUI/UserInterface/Views/CanvasOverviewContentView.js (227007 => 227008) --- trunk/Source/WebInspectorUI/UserInterface/Views/CanvasOverviewContentView.js 2018-01-16 23:08:44 UTC (rev 227007) +++ trunk/Source/WebInspectorUI/UserInterface/Views/CanvasOverviewContentView.js 2018-01-16 23:17:36 UTC (rev 227008) @@ -61,10 +61,16 @@ new WI.KeyboardShortcut(null, WI.KeyboardShortcut.Key.Right, this._handleRight.bind(this)), new WI.KeyboardShortcut(null, WI.KeyboardShortcut.Key.Down, this._handleDown.bind(this)), new WI.KeyboardShortcut(null, WI.KeyboardShortcut.Key.Left, this._handleLeft.bind(this)), -new WI.KeyboardShortcut(null, WI.KeyboardShortcut.Key.Space, this._handleSpace.bind(this)), -new WI.KeyboardShortcut(WI.KeyboardShortcut.Modifier.Shift, WI.KeyboardShortcut.Key.Space, this._handleSpace.bind(this)), ]; +let recordShortcut = new WI.KeyboardShortcut(null, WI.KeyboardShortcut.Key.Space, this._handleSpace.bind(this)); +recordShortcut.implicitlyPreventsDefault = false; +this._keyboardShortcuts.push(recordShortcut); + +let recordSingleFrameShortcut = new WI.KeyboardShortcut(WI.KeyboardShortcut.Modifier.Shift, WI.KeyboardShortcut.Key.Space, this._handleSpace.bind(this)); +recordSingleFrameShortcut.implicitlyPreventsDefault = false; +this._keyboardShortcuts.push(recordSingleFrameShortcut); + for (let shortcut of this._keyboardShortcuts) shortcut.disabled = true; } @@ -241,6 +247,9 @@ _handleSpace(event) { +if (WI.isEventTargetAnEditableField(event)) +return; + if (!this._selectedItem) return; @@ -250,6 +259,8 @@ let singleFrame = !!event.shiftKey; WI.canvasManager.startRecording(this._selectedItem, singleFrame); } + +event.preventDefault(); } _updateShowImageGrid() ___ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes
[webkit-changes] [226963] trunk/Source/WebInspectorUI
Title: [226963] trunk/Source/WebInspectorUI Revision 226963 Author mattba...@apple.com Date 2018-01-15 23:03:57 -0800 (Mon, 15 Jan 2018) Log Message Web Inspector: TabBar redesign: add context menu to TabBar for toggling available tabs https://bugs.webkit.org/show_bug.cgi?id=181448 Reviewed by Devin Rousso. * UserInterface/Base/Main.js: (WI.loaded): (WI.contentLoaded): Reorder production tab classes and default (open) tabs. (WI.registerTabClass): Removed. Not used. * UserInterface/Base/Object.js: Remove notification that is no longer used. * UserInterface/Views/GeneralTabBarItem.js: (WI.GeneralTabBarItem): (WI.GeneralTabBarItem.prototype.set title): (WI.GeneralTabBarItem.prototype._handleContextMenuEvent): Deleted. Remove per-tab context menu (provided Close Tab and Close Other Tabs). * UserInterface/Views/NewTabContentView.js: (WI.NewTabContentView): * UserInterface/Views/TabBar.js: (WI.TabBar): (WI.TabBar.prototype._handleContextMenu): * UserInterface/Views/TabBrowser.js: (WI.TabBrowser): (WI.TabBrowser._handleNewTabContextMenu): Deleted. No longer needed. Modified Paths trunk/Source/WebInspectorUI/ChangeLog trunk/Source/WebInspectorUI/UserInterface/Base/Main.js trunk/Source/WebInspectorUI/UserInterface/Base/Object.js trunk/Source/WebInspectorUI/UserInterface/Views/GeneralTabBarItem.js trunk/Source/WebInspectorUI/UserInterface/Views/NewTabContentView.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBar.js trunk/Source/WebInspectorUI/UserInterface/Views/TabBrowser.js Diff Modified: trunk/Source/WebInspectorUI/ChangeLog (226962 => 226963) --- trunk/Source/WebInspectorUI/ChangeLog 2018-01-16 06:44:41 UTC (rev 226962) +++ trunk/Source/WebInspectorUI/ChangeLog 2018-01-16 07:03:57 UTC (rev 226963) @@ -1,3 +1,39 @@ +2018-01-15 Matt Baker + +Web Inspector: TabBar redesign: add context menu to TabBar for toggling available tabs +https://bugs.webkit.org/show_bug.cgi?id=181448 + + +Reviewed by Devin Rousso. + +* UserInterface/Base/Main.js: +(WI.loaded): +(WI.contentLoaded): +Reorder production tab classes and default (open) tabs. +(WI.registerTabClass): Removed. +Not used. + +* UserInterface/Base/Object.js: +Remove notification that is no longer used. + +* UserInterface/Views/GeneralTabBarItem.js: +(WI.GeneralTabBarItem): +(WI.GeneralTabBarItem.prototype.set title): +(WI.GeneralTabBarItem.prototype._handleContextMenuEvent): Deleted. +Remove per-tab context menu (provided Close Tab and Close Other Tabs). + +* UserInterface/Views/NewTabContentView.js: +(WI.NewTabContentView): + +* UserInterface/Views/TabBar.js: +(WI.TabBar): +(WI.TabBar.prototype._handleContextMenu): + +* UserInterface/Views/TabBrowser.js: +(WI.TabBrowser): +(WI.TabBrowser._handleNewTabContextMenu): Deleted. +No longer needed. + 2018-01-13 Nikita Vasilyev Web Inspector: Styles Redesign: properties should never be semitransparent or crossed out while editing Modified: trunk/Source/WebInspectorUI/UserInterface/Base/Main.js (226962 => 226963) --- trunk/Source/WebInspectorUI/UserInterface/Base/Main.js 2018-01-16 06:44:41 UTC (rev 226962) +++ trunk/Source/WebInspectorUI/UserInterface/Base/Main.js 2018-01-16 07:03:57 UTC (rev 226963) @@ -158,7 +158,7 @@ // Create settings. this._showingSplitConsoleSetting = new WI.Setting("showing-split-console", false); -this._openTabsSetting = new WI.Setting("open-tab-types", ["elements", "network", "resources", "timeline", "debugger", "storage", "canvas", "console"]); +this._openTabsSetting = new WI.Setting("open-tab-types", ["elements", "network", "debugger", "resources", "timeline", "storage", "canvas", "console"]); this._selectedTabIndexSetting = new WI.Setting("selected-tab-index", 0); this.showShadowDOMSetting = new WI.Setting("show-shadow-dom", false); @@ -428,18 +428,18 @@ // These tabs are always available for selecting, modulo isTabAllowed(). // Other tabs may be engineering-only or toggled at runtime if incomplete. let productionTabClasses = [ -WI.CanvasTabContentView, -WI.ConsoleTabContentView, -WI.DebuggerTabContentView, WI.ElementsTabContentView, -WI.LayersTabContentView, WI.NetworkTabContentView, -WI.NewTabContentView, +WI.DebuggerTabContentView, WI.ResourcesTabContentView, +WI.TimelineTabContentView, +WI.StorageTabContentView, +WI.CanvasTabContentView, +WI.LayersTabContentView, +WI.ConsoleTabContentView, WI.SearchTabContentView, +WI.NewTabContentView, WI.SettingsTabContentView, -WI.StorageTabContentView, -WI.TimelineTabContentView, ]; this._knownTabClassesByType = new Map; @@ -662,21 +662,6 @@ this.tabBrowser.showTabForContentVie