67b538665e3c47924a016ec28283f7043a14f702
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2018-11-07  Joseph Pecoraro  <pecoraro@apple.com>
2
3         Web Inspector: Fix "Javascript" => "JavaScript" enum in protocol generated objects
4         https://bugs.webkit.org/show_bug.cgi?id=191340
5
6         Reviewed by Devin Rousso.
7
8         * UserInterface/Models/Canvas.js:
9         (WI.Canvas.fromPayload):
10         Insert a missing break statement for the WebGPU case.
11
12         * UserInterface/Models/MemoryTimelineRecord.js:
13         (WI.MemoryTimelineRecord.memoryCategoriesFromProtocol):
14         Use new enum name.
15
16         * UserInterface/Protocol/Legacy/10.0/InspectorBackendCommands.js:
17         * UserInterface/Protocol/Legacy/10.3/InspectorBackendCommands.js:
18         * UserInterface/Protocol/Legacy/11.0/InspectorBackendCommands.js:
19         * UserInterface/Protocol/Legacy/11.3/InspectorBackendCommands.js:
20         * UserInterface/Protocol/Legacy/12.0/InspectorBackendCommands.js:
21         * UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js:
22         * UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js:
23         * UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js:
24         Update enums with new generator.
25
26 2018-11-06  Joseph Pecoraro  <pecoraro@apple.com>
27
28         REGRESSION: Web Inspector: Popovers drawing incorrectly in Network Tab (clicking between a few items)
29         https://bugs.webkit.org/show_bug.cgi?id=191323
30
31         Reviewed by Devin Rousso.
32
33         * UserInterface/Views/Popover.js:
34         (WI.Popover.prototype._drawBackground):
35         Save and restore the context state between updates. Something
36         was affecting the clearRect, making it so that it didn't actually
37         clear the entire rect each time.
38
39 2018-11-05  Devin Rousso  <drousso@apple.com>
40
41         Web Inspector: Audit: turn off Start button when all tests are removed
42         https://bugs.webkit.org/show_bug.cgi?id=191235
43
44         Reviewed by Matt Baker.
45
46         * UserInterface/Views/AuditNavigationSidebarPanel.js:
47         (WI.AuditNavigationSidebarPanel.prototype._handleAuditTestRemoved):
48
49 2018-11-05  Matt Baker  <mattbaker@apple.com>
50
51         Web Inspector: Table selection should not require that rows be in the cache
52         https://bugs.webkit.org/show_bug.cgi?id=190993
53         <rdar://problem/45613812>
54
55         Reviewed by Devin Rousso.
56
57         Deselecting a table row shouldn't depend on it being in the cache. This
58         allows us to implement select all, and other kinds of bulk selection
59         actions that affect rows that haven't been revealed.
60
61         * UserInterface/Views/Table.js:
62         (WI.Table.prototype.deselectRow):
63
64 2018-11-05  Devin Rousso  <drousso@apple.com>
65
66         Web Inspector: show save/restore stack for recorded 2D Canvases
67         https://bugs.webkit.org/show_bug.cgi?id=175283
68         <rdar://problem/34040756>
69
70         Reviewed by Matt Baker.
71
72         Instead of using plain objects for holding the `WI.Recording`'s state, use a model object
73         so that more data can be passed around. When visualizing the state, show any previously
74         saved states in a `WI.DetailsSection` underneath the current state. If there are no saved
75         states (meaning there is only the current state), don't use a `WI.DetailsSection`.
76
77         * UserInterface/Models/RecordingState.js: Added.
78         (WI.RecordingState):
79         (WI.RecordingState.fromContext):
80         (WI.RecordingState.async swizzleInitialState):
81         (WI.RecordingState.prototype.get source):
82         (WI.RecordingState.prototype.has):
83         (WI.RecordingState.prototype.get return):
84         (WI.RecordingState.prototype.toJSON):
85         (WI.RecordingState.prototype.[Symbol.iterator]):
86
87         * UserInterface/Models/Recording.js:
88         (WI.Recording.prototype.async _process):
89         (WI.Recording.prototype.async _swizzleState): Deleted.
90
91         * UserInterface/Models/RecordingAction.js:
92         (WI.RecordingAction.prototype.process):
93         (WI.RecordingAction.deriveCurrentState): Deleted.
94
95         * UserInterface/Views/RecordingContentView.js:
96         (WI.RecordingContentView.prototype._generateContentCanvas2D):
97
98         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
99         (WI.RecordingStateDetailsSidebarPanel):
100         (WI.RecordingStateDetailsSidebarPanel.prototype.get scrollElement):
101         (WI.RecordingStateDetailsSidebarPanel.prototype.sizeDidChange): Added.
102         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
103         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D.isColorProperty): Deleted.
104         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D.createInlineSwatch): Deleted.
105         * UserInterface/Views/RecordingStateDetailsSidebarPanel.css:
106         (.sidebar > .panel.details.recording-state > .content .details-section > .header .source): Added.
107         (.sidebar > .panel.details.recording-state > .content .data-grid tr.modified): Added.
108         (.sidebar > .panel.details.recording-state > .content .data-grid tr:not(.selected).non-standard .name-column): Added.
109         (.sidebar > .panel.details.recording-state > .content .data-grid tr:not(.selected) .unavailable): Added.
110         (.sidebar > .panel.details.recording-state > .content .data-grid .inline-swatch): Added.
111         (.sidebar > .panel.details.recording-state > .content > .data-grid tr.modified): Deleted.
112         (.sidebar > .panel.details.recording-state > .content > .data-grid tr:not(.selected).non-standard): Deleted.
113         (.sidebar > .panel.details.recording-state > .content > .data-grid tr:not(.selected) .unavailable): Deleted.
114         (.sidebar > .panel.details.recording-state > .content > .data-grid .inline-swatch): Deleted.
115
116         * UserInterface/Main.html:
117         * UserInterface/Test.html:
118
119         * Localizations/en.lproj/localizedStrings.js:
120
121 2018-11-03  Devin Rousso  <drousso@apple.com>
122
123         Web Inspector: Canvas: capture changes to <canvas> that would affect the recorded context
124         https://bugs.webkit.org/show_bug.cgi?id=190854
125
126         Reviewed by Matt Baker.
127
128         * UserInterface/Models/RecordingAction.js:
129         (WI.RecordingAction):
130         (WI.RecordingAction.isFunctionForType):
131         (WI.RecordingAction.constantNameForParameter):
132         (WI.RecordingAction.prototype.get contextReplacer): Added.
133         (WI.RecordingAction.prototype.async.swizzle):
134         (WI.RecordingAction.prototype.apply):
135         Create a constant list of actions for each recording type that need to replace the context
136         with a different value before being applied (e.g. `width` should be applied to the
137         `context`'s `canvas` instead of directly to the `context`).
138
139         * UserInterface/Views/RecordingContentView.js:
140         (WI.RecordingContentView.prototype._generateContentCanvas2D.actionModifiesPath): Added.
141         (WI.RecordingContentView.prototype._generateContentCanvas2D):
142         (WI.RecordingContentView._actionModifiesPath): Deleted.
143         Generate the path context after the actions are applied to the preview context so that the
144         final width/height are known and can be used. This is needed because changing the
145         width/height causes the content to be erased.
146
147         * UserInterface/Views/RecordingActionTreeElement.js:
148         (WI.RecordingActionTreeElement._generateDOM):
149         (WI.RecordingActionTreeElement._classNameForAction):
150         * UserInterface/Views/RecordingActionTreeElement.css:
151         (.tree-outline:focus .item.action.selected:not(.invalid, .initial-state, .has-context-replacer) > .icon): Added.
152         (.item.action > .titles .context-replacer::after): Added.
153         (.item.action.has-context-replacer > .icon): Added.
154         (@media (prefers-dark-interface) .item.action:not(.invalid, .initial-state, .has-context-replacer) > .icon): Added.
155         (.tree-outline:focus .item.action.selected:not(.initial-state, .invalid) > .icon): Deleted.
156         (@media (prefers-dark-interface) .item.action:not(.initial-state) > .icon): Deleted.
157         (@media (prefers-dark-interface) .tree-outline:not(.hide-disclosure-buttons) .item.action:not(.initial-state, .parent) > .icon): Deleted.
158         Add the context replacer text to the beginning of the action's name if it exists.
159
160         * UserInterface/Views/CanvasContentView.js:
161         (WI.CanvasContentView.prototype._refreshPixelSize):
162         (WI.CanvasContentView.prototype._updatePixelSize): Deleted.
163         Update preview image when the canvas' size changes.
164
165 2018-11-02  Matt Baker  <mattbaker@apple.com>
166
167         Web Inspector: support multiple selection/deletion of cookie records
168         https://bugs.webkit.org/show_bug.cgi?id=66381
169         <rdar://problem/19281525>
170
171         Reviewed by Devin Rousso.
172
173         * Localizations/en.lproj/localizedStrings.js:
174
175         * UserInterface/Views/CookieStorageContentView.js:
176         (WI.CookieStorageContentView):
177         (WI.CookieStorageContentView.prototype.get scrollableElements):
178         (WI.CookieStorageContentView.prototype.tableNumberOfRows):
179         (WI.CookieStorageContentView.prototype.tableSortChanged):
180         (WI.CookieStorageContentView.prototype.tableCellContextMenuClicked):
181         (WI.CookieStorageContentView.prototype.tableDidRemoveRows):
182         (WI.CookieStorageContentView.prototype.tablePopulateCell):
183         (WI.CookieStorageContentView.prototype.initialLayout):
184         (WI.CookieStorageContentView.prototype._generateSortComparator):
185         (WI.CookieStorageContentView.prototype._refreshButtonClicked):
186         (WI.CookieStorageContentView.prototype._reloadCookies):
187         (WI.CookieStorageContentView.prototype._updateSort):
188         (WI.CookieStorageContentView.prototype._handleTableKeyDown):
189         (WI.CookieStorageContentView.prototype.update): Deleted.
190         (WI.CookieStorageContentView.prototype._rebuildTable): Deleted.
191         (WI.CookieStorageContentView.prototype._sortDataGrid.localeCompare): Deleted.
192         (WI.CookieStorageContentView.prototype._sortDataGrid.numberCompare): Deleted.
193         (WI.CookieStorageContentView.prototype._sortDataGrid.expiresCompare): Deleted.
194         (WI.CookieStorageContentView.prototype._sortDataGrid): Deleted.
195         (WI.CookieStorageContentView.prototype._deleteCallback): Deleted.
196         Replace DataGrid with Table. The content view serves as the table
197         delegate and data source, and handles delete and backspace key events
198         to allow deleting the selected cookies. Cookies may also be deleted from
199         the table context menu and a new button in the navigation bar.
200
201         * UserInterface/Views/Table.js:
202         (WI.Table.prototype.isRowSelected):
203         (WI.Table.prototype.selectRow):
204         (WI.Table.prototype.deselectRow):
205         (WI.Table.prototype.removeRow):
206         (WI.Table.prototype._getOrCreateRow):
207         (WI.Table.prototype._handleMouseDown):
208         (WI.Table.prototype._removeRows):
209         (WI.Table.prototype._isRowSelected): Deleted.
210         Make `isSelectedRow` public. It is more convenient and efficient than
211         calling `Table.prototype.selectedRows.includes(rowIndex)`.
212
213 2018-11-01  Devin Rousso  <drousso@apple.com>
214
215         Web Inspector: View: introduce a didLayoutSubtree
216         https://bugs.webkit.org/show_bug.cgi?id=191176
217
218         Reviewed by Matt Baker.
219
220         Introduce logic to allow subclasses of `WI.View` to perform logic after every `WI.View` in
221         their subtree has finished `layout`.
222
223         * UserInterface/Views/View.js:
224         (WI.View.prototype.didLayoutSubtree): Added.
225         (WI.View.prototype._layoutSubtree):
226
227         * UserInterface/Views/NetworkTableContentView.js:
228         (WI.NetworkTableContentView.prototype.layout):
229         (WI.NetworkTableContentView.prototype.didLayoutSubtree): Added.
230
231 2018-11-01  Devin Rousso  <drousso@apple.com>
232
233         Web Inspector: Network: remove unnecessary media event tracking
234         https://bugs.webkit.org/show_bug.cgi?id=191174
235
236         Reviewed by Joseph Pecoraro.
237
238         Renames "Group by Node" to "Group Media Requests" for clarity.
239
240         * UserInterface/Views/NetworkTableContentView.js:
241         (WI.NetworkTableContentView):
242         (WI.NetworkTableContentView.prototype.reset):
243         (WI.NetworkTableContentView.prototype.showRepresentedObject):
244         (WI.NetworkTableContentView.prototype.networkDetailViewClose):
245         (WI.NetworkTableContentView.prototype._populateNameCell):
246         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.createDOMEventLine):
247         (WI.NetworkTableContentView.prototype._populateWaterfallGraph):
248         (WI.NetworkTableContentView.prototype.layout):
249         (WI.NetworkTableContentView.prototype._entryForDOMNode):
250         (WI.NetworkTableContentView.prototype._handleGroupByDOMNodeCheckedDidChange):
251         (WI.NetworkTableContentView.prototype._restoreSelectedRow):
252         (WI.NetworkTableContentView.prototype._handleResourceEntryMousedownWaterfall):
253         (WI.NetworkTableContentView.prototype._handleNodeEntryMousedownWaterfall):
254         (WI.NetworkTableContentView.prototype._handleMousedownWaterfall):
255         * UserInterface/Views/NetworkTableContentView.css:
256         (.network-table .data-container .cell.name .range): Added.
257         (.network-table .data-container .cell.name .range::before): Added.
258         (.network-table:focus .data-container li.selected .cell.name .range): Added.
259         (@media (prefers-dark-interface) .network-table .data-container .cell.name .range): Added.
260         Always display the "Byte Range" title as a "subtitle", regardless of the media requests
261         setting being toggled.
262         Drive-by: update the position of the waterfall popover whenever the time range changes.
263         Drive-by: close the details view if a node is selected and the media requests setting is
264         turned off.
265
266         * UserInterface/Views/Popover.js:
267         (WI.Popover.prototype.resize): Added.
268         (WI.Popover.prototype.handleEvent):
269
270         * Localizations/en.lproj/localizedStrings.js:
271
272 2018-11-01  Devin Rousso  <drousso@apple.com>
273
274         Web Inspector: Uncaught Exception: TypeError: null is not an object (evaluating 'mouseBlock.addEventListener')
275         https://bugs.webkit.org/show_bug.cgi?id=191020
276
277         Reviewed by Joseph Pecoraro.
278
279         * UserInterface/Views/TimelineRuler.js:
280         (WI.TimelineRuler):
281         Since `undefined` is not a number, it isn't less than `0`, which caused us to divide by
282         `undefined` (equivalent to dividing by `0`), resulting in `NaN`.
283
284 2018-11-01  Nikita Vasilyev  <nvasilyev@apple.com>
285
286         Uncaught Exception: TypeError: undefined is not an object (evaluating 'WI.modifierKeys.metaKey') (at ScopeBarItem.js:87:67)
287         https://bugs.webkit.org/show_bug.cgi?id=191173
288
289         Reviewed by Devin Rousso.
290
291         WI.modifierKeys was accessed before it was initialized. Move it from WI.contentLoaded to WI.loaded,
292         which happens before WI.contentLoaded.
293
294         * UserInterface/Base/Main.js:
295         (WI.loaded):
296         (WI.contentLoaded):
297
298 2018-11-01  Nikita Vasilyev  <nvasilyev@apple.com>
299
300         REGRESSION(r237652): Web Inspector: dumpInspectorProtocolMessages is always enabled
301         https://bugs.webkit.org/show_bug.cgi?id=191161
302
303         Reviewed by Joseph Pecoraro.
304
305         * UserInterface/Protocol/InspectorBackend.js:
306         (InspectorBackendClass.prototype.get dumpInspectorProtocolMessages):
307
308 2018-11-01  Nikita Vasilyev  <nvasilyev@apple.com>
309
310         Web Inspector: Styles: Toggle selected properties by pressing Space or Command+/
311         https://bugs.webkit.org/show_bug.cgi?id=181145
312         <rdar://problem/36203388>
313
314         Reviewed by Brian Burg.
315
316         Pressing Space key or Command-/ toggles (comments out or uncomments) selected properties.
317
318         This patch only works with "Enable Selection of Multiple Properties" checked. It shouldn't introduce any
319         changes when this setting is unchecked.
320
321         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
322         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.get selectionRange):
323         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.selectProperties):
324         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyCopy):
325         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._handleKeyDown):
326         * UserInterface/Views/SpreadsheetStyleProperty.js:
327         (WI.SpreadsheetStyleProperty):
328         (WI.SpreadsheetStyleProperty.prototype.update): Renamed from _update.
329         (WI.SpreadsheetStyleProperty.prototype.updateStatus):
330         (WI.SpreadsheetStyleProperty.prototype.applyFilter):
331         (WI.SpreadsheetStyleProperty.prototype.handleCopyEvent):
332         Make `update` method public. No other changes were made.
333
334 2018-10-31  Devin Rousso  <drousso@apple.com>
335
336         Web Inspector: Canvas: create a setting for auto-recording newly created contexts
337         https://bugs.webkit.org/show_bug.cgi?id=190856
338
339         Reviewed by Brian Burg.
340
341         * UserInterface/Controllers/CanvasManager.js:
342         (WI.CanvasManager.supportsRecordingAutoCapture): Added.
343         (WI.CanvasManager.prototype.setRecordingAutoCaptureFrameCount): Added.
344
345         * UserInterface/Models/Canvas.js:
346         (WI.Canvas.prototype.startRecording):
347         (WI.Canvas.prototype.recordingStarted):
348         (WI.Canvas.prototype.recordingFinished):
349
350         * UserInterface/Models/Recording.js:
351
352         * UserInterface/Views/CanvasOverviewContentView.js:
353         (WI.CanvasOverviewContentView):
354         (WI.CanvasOverviewContentView.prototype.get navigationItems):
355         (WI.CanvasOverviewContentView.prototype.initialLayout): Added.
356         (WI.CanvasOverviewContentView.prototype.attached):
357         (WI.CanvasOverviewContentView.prototype.detached):
358         (WI.CanvasOverviewContentView.prototype._setRecordingAutoCaptureFrameCount): Added.
359         (WI.CanvasOverviewContentView.prototype._updateRecordingAutoCaptureInputElementSize): Added.
360         (WI.CanvasOverviewContentView.prototype._handleRecordingAutoCaptureInput): Added.
361         (WI.CanvasOverviewContentView.prototype._handleRecordingAutoCaptureCheckedDidChange): Added.
362         (WI.CanvasOverviewContentView.prototype._handleCanvasRecordingAutoCaptureEnabledChanged): Added.
363         (WI.CanvasOverviewContentView.prototype._handleCanvasRecordingAutoCaptureFrameCountChanged): Added.
364         * UserInterface/Views/CanvasOverviewContentView.css:
365         (.navigation-bar > .item.canvas-recording-auto-capture > label): Added.
366         (.navigation-bar > .item.canvas-recording-auto-capture > label > input): Added.
367         (.navigation-bar > .item.canvas-recording-auto-capture > label > input::-webkit-inner-spin-button): Added.
368         (.popover-content > .tree-outline .item.recording > .icon): Deleted.
369         (.popover-content > .tree-outline .item.recording:hover): Deleted.
370         (.popover-content > .tree-outline .item.recording:hover > .icon): Deleted.
371         Drive-by: removed unused CSS rules.
372
373         * UserInterface/Views/CanvasContentView.js:
374         (WI.CanvasContentView.prototype.initialLayout):
375         (WI.CanvasContentView.prototype._updateProgressView):
376         (WI.CanvasContentView.prototype._updateViewRelatedItems):
377
378         * UserInterface/Views/CanvasTabContentView.js:
379         (WI.CanvasTabContentView.prototype._recordingImportedOrStopped):
380
381         * UserInterface/Views/CheckboxNavigationItem.js:
382         (WI.CheckboxNavigationItem):
383         (WI.CheckboxNavigationItem.prototype._handleLabelClick): Added.
384
385         * UserInterface/Base/Setting.js:
386
387         * Localizations/en.lproj/localizedStrings.js:
388
389 2018-10-31  Devin Rousso  <drousso@apple.com>
390
391         Web Inspector: display low-power enter/exit events in Timelines and Network node waterfalls
392         https://bugs.webkit.org/show_bug.cgi?id=190641
393         <rdar://problem/45319049>
394
395         Reviewed by Joseph Pecoraro.
396
397         * UserInterface/Protocol/DOMObserver.js:
398         (WI.DOMObserver.prototype.videoLowPowerChanged): Added.
399
400         * UserInterface/Controllers/DOMManager.js:
401         (WI.DOMManager.prototype.videoLowPowerChanged): Added.
402
403         * UserInterface/Models/DOMNode.js:
404         (WI.DOMNode):
405         (WI.DOMNode.prototype.get lowPowerRanges): Added.
406         (WI.DOMNode.prototype.videoLowPowerChanged): Added.
407         (WI.DOMNode.prototype.canEnterLowPowerMode): Added.
408
409         * UserInterface/Views/NetworkTableContentView.js:
410         (WI.NetworkTableContentView.prototype._populateDomainCell):
411         (WI.NetworkTableContentView.prototype._tryLinkResourceToDOMNode):
412         (WI.NetworkTableContentView.prototype._handleNodeLowPowerChanged): Added.
413         * UserInterface/Views/NetworkTableContentView.css:
414         (.network-table :not(.header) .cell.waterfall .waterfall-container > .area):
415         (.network-table :not(.header) .cell.waterfall .waterfall-container > .area.dom-fullscreen): Added.
416         (.network-table :not(.header) .cell.waterfall .waterfall-container > .area.low-power): Added.
417         (.network-table :not(.header) .cell.waterfall .waterfall-container > .dom-fullscreen): Deleted.
418
419         * UserInterface/Views/DOMNodeEventsContentView.js:
420         (WI.DOMNodeEventsContentView):
421         (WI.DOMNodeEventsContentView.prototype.initialLayout):
422         (WI.DOMNodeEventsContentView.prototype.closed): Deleted.
423         (WI.DOMNodeEventsContentView.prototype._handleDOMNodeDidFireEvent): Deleted.
424
425         * UserInterface/Views/DOMEventsBreakdownView.js:
426         (WI.DOMEventsBreakdownView):
427         (WI.DOMEventsBreakdownView.prototype.initialLayout):
428         (WI.DOMEventsBreakdownView.prototype.layout): Added.
429         (WI.DOMEventsBreakdownView.prototype._handleDOMNodeDidFireEvent): Added.
430         (WI.DOMEventsBreakdownView.prototype._handleDOMNodeLowPowerChanged): Added.
431         (WI.DOMEventsBreakdownView.prototype.addEvent): Deleted.
432         (WI.DOMEventsBreakdownView.prototype._populateTable.percentOfTotalTime): Deleted.
433         (WI.DOMEventsBreakdownView.prototype._populateTable): Deleted.
434         * UserInterface/Views/DOMEventsBreakdownView.css:
435         (.dom-events-breakdown .graph > .area): Added.
436         (.dom-events-breakdown .graph > .area.fullscreen):
437         (.dom-events-breakdown .graph > .area.low-power): Added.
438
439         * Localizations/en.lproj/localizedStrings.js:
440
441 2018-10-31  Devin Rousso  <drousso@apple.com>
442
443         Web Inspector: Audit: save imported audits across WebInspector sessions
444         https://bugs.webkit.org/show_bug.cgi?id=190858
445         <rdar://problem/45527625>
446
447         Reviewed by Brian Burg.
448
449         * UserInterface/Base/ObjectStore.js: Added.
450         (WI.ObjectStore):
451         (WI.ObjectStore.supported):
452         (WI.ObjectStore._open):
453         (WI.ObjectStore.get _databaseName):
454         (WI.ObjectStore.prototype.associateObject):
455         (WI.ObjectStore.prototype.async getAll):
456         (WI.ObjectStore.prototype.async add):
457         (WI.ObjectStore.prototype.async addObject):
458         (WI.ObjectStore.prototype.async delete):
459         (WI.ObjectStore.prototype.async deleteObject):
460         (WI.ObjectStore.prototype._resolveKeyPath):
461         (WI.ObjectStore.prototype.async _operation.listener):
462         (WI.ObjectStore.prototype.async _operation):
463         Wrapper for a global `IndexedDB` instance for all of WebInspector (per level). Instances of
464         `WI.ObjectStore` are able to control a given `IDBObjectStore` using a promise-based API.
465
466         *NOTE*: due to the constraint that `IDBObjectStore`s are only able to be created when the
467         owner `IndexedDB` is "upgrade"d, all `WI.ObjectStore` must be declared before the database
468         is opened for the first time. Additionally, any time a new `WI.ObjectStore` is added, the
469         `version` needs to be incremented to ensure that the "upgrade" event fires.
470
471         To use any of the `*Object` functions, one must implement a `toJSON` on the object provided.
472         This is so that `WI.ObjectStore` is able to add the resulting identifier value to the owner
473         object while storing its `toJSON` value in the IndexedDB (e.g. for objects that have cycles).
474
475         * UserInterface/Controllers/AuditManager.js:
476         (WI.AuditManager.prototype.import):
477         (WI.AuditManager.prototype.loadStoredTests): Added.
478         (WI.AuditManager.prototype.removeTest): Added.
479         (WI.AuditManager.prototype._addTest):
480
481         * UserInterface/Views/AuditTabContentView.js:
482         (WI.AuditTabContentView.prototype.initialLayout): Added.
483         Attempt to load stored audits when the Audit tab is first shown (lazy-load).
484
485         * UserInterface/Views/AuditNavigationSidebarPanel.js:
486         (WI.AuditNavigationSidebarPanel.prototype.initialLayout):
487         (WI.AuditNavigationSidebarPanel.prototype._handleAuditTestRemoved): Added.
488
489         * UserInterface/Views/AuditTreeElement.js:
490         (WI.AuditTreeElement.prototype.ondelete):
491         Only allow top-level audits to be deleted, as that is what matches the `WI.ObjectStore`.
492
493         * UserInterface/Main.html:
494         * UserInterface/Test.html:
495
496 2018-10-31  Joseph Pecoraro  <pecoraro@apple.com>
497
498         Web Inspector: Move a few remaining global WI settings to WI.settings
499         https://bugs.webkit.org/show_bug.cgi?id=191137
500
501         Reviewed by Brian Burg.
502
503         Move and better name some of the WI.settings created in Main.js
504         to WI.settings, alongside other global settings.
505
506         * UserInterface/Base/Main.js:
507         (WI.loaded):
508         Move settings, and register for settings changes in contentLoaded.
509
510         * UserInterface/Base/Setting.js:
511         New settings, and sort values.
512
513         * UserInterface/Test/Test.js:
514         (WI.loaded):
515         Update setting values for tests.
516
517         * UserInterface/Controllers/NetworkManager.js:
518         (WI.NetworkManager.prototype.initializeTarget):
519         * UserInterface/Controllers/RuntimeManager.js:
520         (WI.RuntimeManager.prototype.initializeTarget):
521         * UserInterface/Models/DOMNode.js:
522         (WI.DOMNode.prototype.get children):
523         (WI.DOMNode.prototype.get nextSibling):
524         (WI.DOMNode.prototype.get previousSibling):
525         (WI.DOMNode.prototype.get childNodeCount):
526         * UserInterface/Protocol/Target.js:
527         (WI.Target.prototype.initialize):
528         * UserInterface/Views/DOMTreeContentView.js:
529         (WI.DOMTreeContentView):
530         (WI.DOMTreeContentView.prototype.closed):
531         (WI.DOMTreeContentView.prototype._togglePaintFlashing):
532         (WI.DOMTreeContentView.prototype._showPaintRectsSettingChanged):
533         (WI.DOMTreeContentView.prototype._showShadowDOMSettingChanged):
534         (WI.DOMTreeContentView.prototype._toggleShowsShadowDOMSetting):
535         * UserInterface/Views/DOMTreeOutline.js:
536         (WI.DOMTreeOutline):
537         (WI.DOMTreeOutline.prototype.close):
538         (WI.DOMTreeOutline.prototype._revealAndSelectNode):
539         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
540         (WI.LayerTreeDetailsSidebarPanel.prototype.initialLayout):
541         (WI.LayerTreeDetailsSidebarPanel.prototype._updateDisplayWithLayers):
542         * UserInterface/Views/Layers3DContentView.js:
543         (WI.Layers3DContentView):
544         (WI.Layers3DContentView.prototype.closed):
545         (WI.Layers3DContentView.prototype._showPaintRectsSettingChanged):
546         (WI.Layers3DContentView.prototype._togglePaintFlashing):
547         * UserInterface/Views/NetworkTableContentView.js:
548         (WI.NetworkTableContentView):
549         (WI.NetworkTableContentView.prototype.closed):
550         (WI.NetworkTableContentView.prototype._resourceCachingDisabledSettingChanged):
551         (WI.NetworkTableContentView.prototype._toggleDisableResourceCache):
552         * UserInterface/Views/ScriptContentView.js:
553         (WI.ScriptContentView):
554         (WI.ScriptContentView.prototype.closed):
555         (WI.ScriptContentView.prototype._contentDidPopulate):
556         (WI.ScriptContentView.prototype._enableControlFlowProfilerSettingChanged):
557         (WI.ScriptContentView.prototype._showJavaScriptTypeInformationSettingChanged):
558         * UserInterface/Views/SourceCodeTextEditor.js:
559         (WI.SourceCodeTextEditor.prototype.shown):
560         (WI.SourceCodeTextEditor.prototype._proceedPopulateWithContent):
561         (WI.SourceCodeTextEditor.prototype._setTypeTokenAnnotatorEnabledState):
562         (WI.SourceCodeTextEditor.prototype.set _basicBlockAnnotatorEnabled):
563         * UserInterface/Views/TextResourceContentView.js:
564         (WI.TextResourceContentView):
565         (WI.TextResourceContentView.prototype.closed):
566         (WI.TextResourceContentView.prototype._contentDidPopulate):
567         (WI.TextResourceContentView.prototype._enableControlFlowProfilerSettingChanged):
568         (WI.TextResourceContentView.prototype._showJavaScriptTypeInformationSettingChanged):
569         Renamed setting.
570
571 2018-10-31  Devin Rousso  <drousso@apple.com>
572
573         Web Inspector: Styles: missing contextmenu items for links
574         https://bugs.webkit.org/show_bug.cgi?id=191021
575
576         Reviewed by Joseph Pecoraro.
577
578         * UserInterface/Views/SpreadsheetStyleProperty.js:
579         (WI.SpreadsheetStyleProperty.prototype._renderValue):
580         (WI.SpreadsheetStyleProperty.prototype._handleLinkContextMenu): Added.
581         If the token is subtype of "link", add contextmenu items to the wrapper element.
582
583         * UserInterface/Views/ContextMenuUtilities.js:
584         (WI.appendContextMenuItemsForURL.showResourceWithOptions):
585         (WI.appendContextMenuItemsForURL):
586         Drive-by: don't assume that `options` will be provided.
587
588         * Localizations/en.lproj/localizedStrings.js:
589
590 2018-10-31  Nikita Vasilyev  <nvasilyev@apple.com>
591
592         Web Inspector: Styles: implement copying and deletion of multiple properties
593         https://bugs.webkit.org/show_bug.cgi?id=191037
594         <rdar://problem/45650078>
595
596         Reviewed by Brian Burg.
597
598         This patch should only work with "Enable Selection of Multiple Properties" checked. It shouldn't introduce any
599         changes when this setting is unchecked.
600
601         Mousedown on a property (1) and moving the mouse cursor to another property (2) should select properties 1, 2, and
602         all properties between them until mouseup is fired.
603
604         Once selected:
605         - Pressing Command-C should copy the selected properties.
606         - Pressing Delete should remove the properties.
607
608         * UserInterface/Models/CSSProperty.js:
609         (WI.CSSProperty.prototype.get formattedText):
610         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
611         (.spreadsheet-style-declaration-editor):
612         (.multiple-properties-selection .spreadsheet-style-declaration-editor .property):
613         (.multiple-properties-selection .spreadsheet-style-declaration-editor :matches(.name, .value):not(.editing)):
614         (.multiple-properties-selection .spreadsheet-style-declaration-editor .property.selected):
615         (.multiple-properties-selection .spreadsheet-style-declaration-editor .property.selected:focus):
616         (@media (prefers-dark-interface)):
617
618         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
619         (WI.SpreadsheetCSSStyleDeclarationEditor):
620         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.initialLayout):
621         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.selectProperties):
622         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.deselectProperties):
623         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyBlur):
624         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyMouseEnter):
625         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyMouseLeave):
626         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyCopy):
627         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._handleKeyDown):
628         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._hasSelectedProperties):
629         Property selection is defined as two numbers: anchorIndex and focusIndex.
630         The property with focusIndex is actually focused. The focus outline is replaced by a more subtle left blue border.
631
632         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
633         (.spreadsheet-css-declaration.selecting,):
634         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
635         (WI.SpreadsheetCSSStyleDeclarationSection):
636         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.spreadsheetCSSStyleDeclarationEditorPropertyBlur):
637         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.spreadsheetCSSStyleDeclarationEditorPropertyMouseEnter):
638         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.spreadsheetCSSStyleDeclarationEditorPropertyMouseLeave):
639         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleMouseDown):
640         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleWindowMouseUp):
641         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._handleClick):
642         * UserInterface/Views/SpreadsheetStyleProperty.js:
643         (WI.SpreadsheetStyleProperty):
644         Implement copying the same way it's done for DataGrid: by adding copyHandler property to the focused element.
645         Add `tabIndex=-1` so the property element can be focused.
646
647         (WI.SpreadsheetStyleProperty.prototype.get property):
648         (WI.SpreadsheetStyleProperty.prototype.get selected):
649         (WI.SpreadsheetStyleProperty.prototype.set selected):
650         (WI.SpreadsheetStyleProperty.prototype.remove):
651         (WI.SpreadsheetStyleProperty.prototype.updateStatus):
652         (WI.SpreadsheetStyleProperty.prototype.handleCopyEvent):
653         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidCommit):
654         (WI.SpreadsheetStyleProperty.prototype.spreadsheetTextFieldDidBlur):
655         (WI.SpreadsheetStyleProperty.prototype._handleNamePaste):
656
657 2018-10-31  Devin Rousso  <drousso@apple.com>
658
659         Web Inspector: Audit: attempt to re-link DOM nodes for imported results
660         https://bugs.webkit.org/show_bug.cgi?id=191044
661         <rdar://problem/45687364>
662
663         Reviewed by Brian Burg.
664
665         When importing a `WI.AuditTestCaseResult`, attempt to `querySelector` for each item in
666         `data.domNodes`. If a node is found, replace it with that node and show a tree instead.
667
668         * UserInterface/Models/AuditTestCase.js:
669         (WI.AuditTestCase.async fromPayload): Added.
670         (WI.AuditTestCase.fromPayload): Deleted.
671
672         * UserInterface/Models/AuditTestGroup.js:
673         (WI.AuditTestGroup.async fromPayload): Added.
674         (WI.AuditTestGroup.fromPayload): Deleted.
675
676         * UserInterface/Models/AuditTestCaseResult.js:
677         (WI.AuditTestCaseResult.async fromPayload): Added.
678         (WI.AuditTestCaseResult.fromPayload): Deleted.
679
680         * UserInterface/Models/AuditTestGroupResult.js:
681         (WI.AuditTestGroupResult.async fromPayload): Added.
682         (WI.AuditTestGroupResult.fromPayload): Deleted.
683
684         * UserInterface/Controllers/AuditManager.js:
685         (WI.AuditManager.prototype.import):
686
687 2018-10-31  Joseph Pecoraro  <pecoraro@apple.com>
688
689         Follow-up review comment to r237652.
690
691         Reviewed by Brian Burg.
692
693         * UserInterface/Controllers/DebuggerManager.js:
694         (WI.DebuggerManager):
695
696 2018-10-31  Joseph Pecoraro  <pecoraro@apple.com>
697
698         Web Inspector: Separate target initialization from frontend initialization
699         https://bugs.webkit.org/show_bug.cgi?id=191052
700         <rdar://problem/45658384>
701
702         Reviewed by Brian Burg.
703
704         * UserInterface/Base/Main.js:
705         (WI.loaded):
706         (WI.performOneTimeFrontendInitializationsUsingTarget):
707         Create the targets after the rest of frontend initialization. This is a step
708         toward a frontend opening and being told about multiple targets instead of
709         knowing in advance a single target it is connected to. All backend
710         messages during frontend initialization now happen with an explicit target.
711
712         * UserInterface/Controllers/ApplicationCacheManager.js:
713         (WI.ApplicationCacheManager):
714         (WI.ApplicationCacheManager.prototype.initializeTarget):
715         (WI.ApplicationCacheManager.prototype.initialize):
716         * UserInterface/Controllers/CSSManager.js:
717         (WI.CSSManager):
718         (WI.CSSManager.prototype.initializeTarget):
719         * UserInterface/Controllers/CanvasManager.js:
720         (WI.CanvasManager):
721         (WI.CanvasManager.prototype.initializeTarget):
722         * UserInterface/Controllers/ConsoleManager.js:
723         (WI.ConsoleManager):
724         (WI.ConsoleManager.prototype.initializeLogChannels):
725         * UserInterface/Controllers/DOMManager.js:
726         (WI.DOMManager):
727         (WI.DOMManager.prototype.initializeTarget):
728         * UserInterface/Controllers/DOMStorageManager.js:
729         (WI.DOMStorageManager):
730         (WI.DOMStorageManager.prototype.initializeTarget):
731         * UserInterface/Controllers/DatabaseManager.js:
732         (WI.DatabaseManager):
733         (WI.DatabaseManager.prototype.initializeTarget):
734         * UserInterface/Controllers/DebuggerManager.js:
735         (WI.DebuggerManager):
736         (WI.DebuggerManager.prototype.initializeTarget):
737         (WI.DebuggerManager.restoreBreakpointsSoon): Deleted.
738         * UserInterface/Controllers/HeapManager.js:
739         (WI.HeapManager.prototype.initializeTarget):
740         * UserInterface/Controllers/IndexedDBManager.js:
741         (WI.IndexedDBManager):
742         (WI.IndexedDBManager.prototype.initializeTarget):
743         * UserInterface/Controllers/LayerTreeManager.js:
744         (WI.LayerTreeManager.prototype.initializeTarget):
745         * UserInterface/Controllers/MemoryManager.js:
746         (WI.MemoryManager.prototype.initializeTarget):
747         * UserInterface/Controllers/NetworkManager.js:
748         (WI.NetworkManager):
749         (WI.NetworkManager.prototype.initializeTarget):
750         * UserInterface/Controllers/RuntimeManager.js:
751         (WI.RuntimeManager):
752         (WI.RuntimeManager.prototype.initializeTarget):
753         * UserInterface/Controllers/TargetManager.js:
754         (WI.TargetManager):
755         (WI.TargetManager.prototype.initializeTargetsWithMainTarget):
756         * UserInterface/Controllers/TimelineManager.js:
757         (WI.TimelineManager):
758         (WI.TimelineManager.prototype.initializeTarget):
759         (WI.TimelineManager.prototype.set enabledTimelineTypes):
760         (WI.TimelineManager.prototype._updateAutoCaptureInstruments):
761         * UserInterface/Controllers/WorkerManager.js:
762         (WI.WorkerManager):
763         (WI.WorkerManager.prototype.initializeTarget):
764         Move Target initialization out of the constructor into a top level
765         `initializeTarget` function. This will be expected to be called
766         by any target that the frontend connects to.
767
768         (WI.DebuggerManager.prototype._pauseForInternalScriptsDidChange):
769         Drive-by fix. Update all targets if the setting changes.
770
771         (WI.WorkerManager.prototype.workerCreated):
772         Call initialize on the new target.
773
774         * UserInterface/Models/CSSCompletions.js:
775         (WI.CSSCompletions.initializeCSSCompletions):
776         (WI.CSSCompletions.requestCSSCompletions): Deleted.
777         Rename requestCSSCompletions to initializeCSSCompletions to try
778         and standardize on "initialize" being used for most frontend one
779         time initialization tasks. This being one such operation that
780         only needs to be performed once on a target that supports it.
781
782         * UserInterface/Protocol/Target.js:
783         (WI.Target):
784         (WI.Target.prototype.initialize):
785         Perform explicit target initialization, such as initializing
786         the state of all backend domains / agents. This is done by asking
787         each of the managers to do initialization work for this target.
788
789         (WI.Target.prototype.get ApplicationCacheAgent):
790         (WI.Target.prototype.get CSSAgent):
791         (WI.Target.prototype.get CanvasAgent):
792         (WI.Target.prototype.get ConsoleAgent):
793         (WI.Target.prototype.get DOMAgent):
794         (WI.Target.prototype.get DOMDebuggerAgent):
795         (WI.Target.prototype.get DOMStorageAgent):
796         (WI.Target.prototype.get DatabaseAgent):
797         (WI.Target.prototype.get DebuggerAgent):
798         (WI.Target.prototype.get HeapAgent):
799         (WI.Target.prototype.get IndexedDBAgent):
800         (WI.Target.prototype.get InspectorAgent):
801         (WI.Target.prototype.get LayerTreeAgent):
802         (WI.Target.prototype.get MemoryAgent):
803         (WI.Target.prototype.get NetworkAgent):
804         (WI.Target.prototype.get PageAgent):
805         (WI.Target.prototype.get RecordingAgent):
806         (WI.Target.prototype.get RuntimeAgent):
807         (WI.Target.prototype.get ScriptProfilerAgent):
808         (WI.Target.prototype.get ServiceWorkerAgent):
809         (WI.Target.prototype.get TargetAgent):
810         (WI.Target.prototype.get TimelineAgent):
811         (WI.Target.prototype.get WorkerAgent):
812         Accessors for all of the agents on a Target.
813
814         * UserInterface/Protocol/WorkerTarget.js:
815         (WI.WorkerTarget):
816         This is now automatically done in the base class.
817
818         * UserInterface/Test/Test.js:
819         (WI.loaded):
820         (WI.performOneTimeFrontendInitializationsUsingTarget):
821         New necessary top level hooks, and initialize more like Main.js.
822
823 2018-10-31  Devin Rousso  <drousso@apple.com>
824
825         Web Inspector: Audit: show metadata for results
826         https://bugs.webkit.org/show_bug.cgi?id=190853
827         <rdar://problem/45527623>
828
829         Reviewed by Brian Burg.
830
831         * UserInterface/Models/AuditTestCase.js:
832         (WI.AuditTestCase.prototype.async run):
833         Capture timestamps around the `RunetimeAgent.evaluate` call, as well as the URL of the page.
834
835         * UserInterface/Models/AuditTestCaseResult.js:
836         (WI.AuditTestCaseResult):
837         (WI.AuditTestCaseResult.fromPayload):
838         (WI.AuditTestCaseResult.prototype.get metadata): Added.
839         (WI.AuditTestCaseResult.prototype.toJSON):
840
841         * UserInterface/Views/AuditTestCaseContentView.js:
842         (WI.AuditTestCaseContentView.prototype.initialLayout):
843         (WI.AuditTestCaseContentView.prototype.layout):
844         * UserInterface/Views/AuditTestCaseContentView.css:
845         (.content-view.audit-test-case > header h1): Added.
846         (.content-view.audit-test-case > header h1 > img): Added.
847         (.content-view.audit-test-case > header > .metadata): Added.
848         (.content-view.audit-test-case > header > .metadata > .source > time): Added.
849         (.content-view.audit-test-case > header > .metadata > .source > a): Added.
850         (.content-view.audit-test-case > header > .metadata > .duration): Added.
851         (.content-view.audit-test-case > header > h1): Deleted.
852         (.content-view.audit-test-case > header > h1 > img): Deleted.
853         Display any metadata information where the `WI.ScopeBar` is for `WI.AuditTestGroupContentView`s.
854
855         * UserInterface/Views/AuditTestContentView.css:
856         (.content-view.audit-test > header):
857         (.content-view.audit-test > header > .information): Added.
858         * UserInterface/Views/AuditTestGroupContentView.css:
859         (.content-view.audit-test-group > header):
860         (.content-view.audit-test-group > header > .percentage-pass):
861         (.content-view.audit-test-group > header > .information): Deleted.
862         Move common CSS rules to common parent class.
863
864         * UserInterface/Base/Utilities.js:
865
866 2018-10-30  Devin Rousso  <drousso@apple.com>
867
868         Web Inspector: Audit: create Audit Tab
869         https://bugs.webkit.org/show_bug.cgi?id=190754
870
871         Reviewed by Matt Baker.
872
873         Create an Audit tab for running audits on the inspected page. Leverage `Runtime.evaluate`
874         for running the audit tests (arbitrary JavaScript), and use the returned value to generate
875         a preview UI of the results. All tests/results can be exported/imported to formatted JSON:
876
877         `AuditTestCase` JSON:
878             {
879                 "type": "test-case",
880                 "name": <string>,
881                 <optional> "description": <string>,
882                 "test": <stringified JavaScript function>,
883             }
884
885         `AuditTestGroup` JSON:
886             {
887                 "type": "test-group",
888                 "name": <string>,
889                 <optional> "description": <string>,
890                 "tests": [...<AuditTestCase, AuditTestGroup>],
891             }
892
893         `AuditTestCaseResult` JSON:
894             {
895                 "type": "test-case-result",
896                 "name": <string>,
897                 <optional> "description": <string>,
898                 "level": <"pass", "warn", "fail", "error", "unsupported">,
899                 "data": {
900                     "domNodes": [...<stringified CSS path>],
901                     "domAttributes": [...<string>],
902                     "errors": [...<string>],
903                 },
904             }
905
906         `AuditTestGroupResult` JSON:
907             {
908                 "type": "test-group-result",
909                 "name": <string>,
910                 <optional> "description": <string>,
911                 "results": [...<AuditTestCaseResult, AuditTestGroupResult>],
912             }
913
914         More keys may be added in the future (especially for `AuditTestCaseResult.data`).
915
916         * UserInterface/Controllers/AuditManager.js:
917         (WI.AuditManager):
918         (WI.AuditManager.synthesizeError): Added.
919         (WI.AuditManager.prototype.get tests): Added.
920         (WI.AuditManager.prototype.get results): Added.
921         (WI.AuditManager.prototype.get runningState): Added.
922         (WI.AuditManager.prototype.start): Added.
923         (WI.AuditManager.prototype.stop): Added.
924         (WI.AuditManager.prototype.import): Added.
925         (WI.AuditManager.prototype.export): Added.
926         (WI.AuditManager.prototype._addTest): Added.
927         (WI.AuditManager.prototype._addResult): Added.
928         (WI.AuditManager.prototype.get testSuites): Deleted.
929         (WI.AuditManager.prototype.get reports): Deleted.
930         (WI.AuditManager.prototype.async runAuditTestByRepresentedObject): Deleted.
931         (WI.AuditManager.prototype.reportForId): Deleted.
932         (WI.AuditManager.prototype.removeAllReports): Deleted.
933         (WI.AuditManager.prototype.async _runTestCase): Deleted.
934
935         * UserInterface/Models/AuditTestBase.js: Added.
936         (WI.AuditTestBases):
937         (WI.AuditTestBases.prototype.get name):
938         (WI.AuditTestBases.prototype.get description):
939         (WI.AuditTestBases.prototype.get runningState):
940         (WI.AuditTestBases.prototype.get result):
941         (WI.AuditTestBases.prototype.async start):
942         (WI.AuditTestBases.prototype.stop):
943         (WI.AuditTestBases.prototype.clearResult):
944         (WI.AuditTestBases.prototype.saveIdentityToCookie):
945         (WI.AuditTestBases.prototype.toJSON):
946         (WI.AuditTestBases.prototype.async run):
947
948         * UserInterface/Models/AuditTestCase.js:
949         (WI.AuditTestCase):
950         (WI.AuditTestCase.fromPayload): Added.
951         (WI.AuditTestCase.prototype.toJSON): Added.
952         (WI.AuditTestCase.prototype.async run): Added.
953         (WI.AuditTestCase.prototype.async run.setLevel): Added.
954         (WI.AuditTestCase.prototype.async run.addError): Added.
955         (WI.AuditTestCase.prototype.async run.checkResultProperty.addErrorForValueType): Added.
956         (WI.AuditTestCase.prototype.async run.checkResultProperty): Added.
957         (WI.AuditTestCase.prototype.async run.async resultArrayForEach): Added.
958         (WI.AuditTestCase.prototype.get id): Deleted.
959         (WI.AuditTestCase.prototype.get name): Deleted.
960         (WI.AuditTestCase.prototype.get suite): Deleted.
961         (WI.AuditTestCase.prototype.get setup): Deleted.
962         (WI.AuditTestCase.prototype.get tearDown): Deleted.
963         (WI.AuditTestCase.prototype.get errorDetails): Deleted.
964
965         * UserInterface/Models/AuditTestGroup.js: Added.
966         (WI.AuditTestGroup):
967         (WI.AuditTestGroup.fromPayload):
968         (WI.AuditTestGroup.prototype.get tests):
969         (WI.AuditTestGroup.prototype.stop):
970         (WI.AuditTestGroup.prototype.clearResult):
971         (WI.AuditTestGroup.prototype.async run):
972         (WI.AuditTestGroup.prototype.toJSON):
973         (WI.AuditTestGroup.prototype._updateResult):
974         (WI.AuditTestGroup.prototype._handleTestCompleted):
975         (WI.AuditTestGroup.prototype._handleTestProgress):
976
977         * UserInterface/Models/AuditTestResultBase.js: Added.
978         (WI.AuditTestResultBase):
979         (WI.AuditTestResultBase.prototype.get name):
980         (WI.AuditTestResultBase.prototype.get description):
981         (WI.AuditTestResultBase.prototype.get result):
982         (WI.AuditTestResultBase.prototype.get didPass):
983         (WI.AuditTestResultBase.prototype.get didWarn):
984         (WI.AuditTestResultBase.prototype.get didFail):
985         (WI.AuditTestResultBase.prototype.get didError):
986         (WI.AuditTestResultBase.prototype.get unsupported):
987         (WI.AuditTestResultBase.prototype.saveIdentityToCookie):
988         (WI.AuditTestResultBase.prototype.toJSON):
989
990         * UserInterface/Models/AuditTestCaseResult.js: Added.
991         (WI.AuditTestCaseResult):
992         (WI.AuditTestCaseResult.fromPayload.checkArray):
993         (WI.AuditTestCaseResult.fromPayload):
994         (WI.AuditTestCaseResult.prototype.get level):
995         (WI.AuditTestCaseResult.prototype.get data):
996         (WI.AuditTestCaseResult.prototype.get didPass):
997         (WI.AuditTestCaseResult.prototype.get didWarn):
998         (WI.AuditTestCaseResult.prototype.get didFail):
999         (WI.AuditTestCaseResult.prototype.get didError):
1000         (WI.AuditTestCaseResult.prototype.get unsupported):
1001         (WI.AuditTestCaseResult.prototype.toJSON):
1002
1003         * UserInterface/Models/AuditTestGroupResult.js: Added.
1004         (WI.AuditTestGroupResult):
1005         (WI.AuditTestGroupResult.fromPayload):
1006         (WI.AuditTestGroupResult.prototype.get results):
1007         (WI.AuditTestGroupResult.prototype.get levelCounts):
1008         (WI.AuditTestGroupResult.prototype.get didPass):
1009         (WI.AuditTestGroupResult.prototype.get didWarn):
1010         (WI.AuditTestGroupResult.prototype.get didFail):
1011         (WI.AuditTestGroupResult.prototype.get didError):
1012         (WI.AuditTestGroupResult.prototype.get unsupported):
1013         (WI.AuditTestGroupResult.prototype.toJSON):
1014
1015         * UserInterface/Views/AuditTabContentView.js: Added.
1016         (WI.AuditTabContentView):
1017         (WI.AuditTabContentView.tabInfo):
1018         (WI.AuditTabContentView.isTabAllowed):
1019         (WI.AuditTabContentView.prototype.get type):
1020         (WI.AuditTabContentView.prototype.get supportsSplitContentBrowser):
1021         (WI.AuditTabContentView.prototype.canShowRepresentedObject):
1022         (WI.AuditTabContentView.prototype.shown):
1023         (WI.AuditTabContentView.prototype.hidden):
1024         (WI.AuditTabContentView.prototype._handleSpace):
1025
1026         * UserInterface/Views/AuditNavigationSidebarPanel.js: Added.
1027         (WI.AuditNavigationSidebarPanel):
1028         (WI.AuditNavigationSidebarPanel.prototype.showDefaultContentView):
1029         (WI.AuditNavigationSidebarPanel.prototype.initialLayout):
1030         (WI.AuditNavigationSidebarPanel.prototype.closed):
1031         (WI.AuditNavigationSidebarPanel.prototype._addTest):
1032         (WI.AuditNavigationSidebarPanel.prototype._addResult):
1033         (WI.AuditNavigationSidebarPanel.prototype._updateStartStopButtonNavigationItemState):
1034         (WI.AuditNavigationSidebarPanel.prototype._handleAuditTestAdded):
1035         (WI.AuditNavigationSidebarPanel.prototype._handleAuditTestCompleted):
1036         (WI.AuditNavigationSidebarPanel.prototype._handleAuditTestScheduled):
1037         (WI.AuditNavigationSidebarPanel.prototype._treeSelectionDidChange):
1038         (WI.AuditNavigationSidebarPanel.prototype._handleStartStopButtonNavigationItemClicked):
1039         (WI.AuditNavigationSidebarPanel.prototype._handleImportButtonNavigationItemClicked):
1040         * UserInterface/Views/AuditNavigationSidebarPanel.css: Added.
1041         (.sidebar > .panel.navigation.audit > .content):
1042
1043         * UserInterface/Views/AuditTreeElement.js: Added.
1044         (WI.AuditTreeElement):
1045         (WI.AuditTreeElement.prototype.get result):
1046         (WI.AuditTreeElement.prototype.onattach):
1047         (WI.AuditTreeElement.prototype.ondetach):
1048         (WI.AuditTreeElement.prototype.onpopulate):
1049         (WI.AuditTreeElement.prototype.populateContextMenu):
1050         (WI.AuditTreeElement.prototype._start):
1051         (WI.AuditTreeElement.prototype._updateLevel):
1052         (WI.AuditTreeElement.prototype._showRunningSpinner):
1053         (WI.AuditTreeElement.prototype._showRunningProgress):
1054         (WI.AuditTreeElement.prototype._handleTestCaseCompleted):
1055         (WI.AuditTreeElement.prototype._handleTestResultCleared):
1056         (WI.AuditTreeElement.prototype._handleTestCaseScheduled):
1057         (WI.AuditTreeElement.prototype._handleTestGroupCompleted):
1058         (WI.AuditTreeElement.prototype._handleTestGroupProgress):
1059         (WI.AuditTreeElement.prototype._handleTestGroupScheduled):
1060         (WI.AuditTreeElement.prototype._handleStatusClick):
1061         * UserInterface/Views/AuditTreeElement.css: Added.
1062         (.tree-outline .item.audit > .status):
1063         (.tree-outline .item.audit > .status > img):
1064         (.tree-outline .item.audit:matches(.test-case, .test-group) > .status:hover > img):
1065         (.tree-outline .item.audit > .status:not(:hover) > img.show-on-hover, .tree-outline .item.audit.test-group.expanded > .status:not(:hover)):
1066         (.tree-outline .item.audit.test-group.expanded > .status:hover > :not(img), .tree-outline .item.audit.test-group-result.expanded > .status):
1067         (.tree-outline .item.audit > .status > img.pass):
1068         (.tree-outline .item.audit > .status > img.warn):
1069         (.tree-outline .item.audit > .status > img.fail):
1070         (.tree-outline .item.audit > .status > img.error):
1071         (.tree-outline .item.audit > .status > img.unsupported):
1072         (.audit.test-case .icon):
1073         (.audit.test-group .icon):
1074         (.audit.test-case-result .icon):
1075         (.audit.test-group-result .icon):
1076
1077         * UserInterface/Views/AuditTestContentView.js: Added.
1078         (WI.AuditTestContentView):
1079         (WI.AuditTestContentView.prototype.get navigationItems):
1080         (WI.AuditTestContentView.prototype.get headerView):
1081         (WI.AuditTestContentView.prototype.get contentView):
1082         (WI.AuditTestContentView.prototype.get supportsSave):
1083         (WI.AuditTestContentView.prototype.get saveData):
1084         (WI.AuditTestContentView.prototype.initialLayout):
1085         (WI.AuditTestContentView.prototype.layout):
1086         (WI.AuditTestContentView.prototype.shown):
1087         (WI.AuditTestContentView.prototype.hidden):
1088         (WI.AuditTestContentView.prototype.get placeholderElement):
1089         (WI.AuditTestContentView.prototype.set placeholderElement):
1090         (WI.AuditTestContentView.prototype.showRunningPlaceholder):
1091         (WI.AuditTestContentView.prototype.showStoppingPlaceholder):
1092         (WI.AuditTestContentView.prototype.showNoResultPlaceholder):
1093         (WI.AuditTestContentView.prototype.showNoResultDataPlaceholder):
1094         (WI.AuditTestContentView.prototype.showFilteredPlaceholder):
1095         (WI.AuditTestContentView.prototype.hidePlaceholder):
1096         (WI.AuditTestContentView.prototype.applyFilter):
1097         (WI.AuditTestContentView.prototype.resetFilter):
1098         (WI.AuditTestContentView.prototype._exportAudit):
1099         (WI.AuditTestContentView.prototype._updateExportButtonNavigationItemState):
1100         (WI.AuditTestContentView.prototype._showPlaceholder):
1101         (WI.AuditTestContentView.prototype._handleExportButtonNavigationItemClicked):
1102         (WI.AuditTestContentView.prototype._handleTestChanged):
1103         * UserInterface/Views/AuditTestContentView.css: Added.
1104         (.content-view-container > .content-view.audit-test):
1105         (.content-view-container > .content-view.audit-test > header):
1106         (.content-view-container > .content-view.audit-test > header h1):
1107         (.content-view-container > .content-view.audit-test > header p):
1108         (.content-view.audit-test):
1109         (.content-view.audit-test h1):
1110         (.content-view.audit-test > header):
1111         (.content-view.audit-test > header p):
1112         (.content-view.audit-test .audit-test.filtered, .content-view.audit-test .audit-test .message-text-view):
1113         (.content-view.audit-test > section):
1114         (.content-view.audit-test > section > .message-text-view):
1115         (.content-view.audit-test.showing-placeholder):
1116         (.content-view.audit-test.showing-placeholder > section):
1117         (.content-view.audit-test.showing-placeholder > section > :not(.message-text-view)):
1118         (@media (prefers-dark-interface) .content-view.audit-test):
1119
1120         * UserInterface/Views/AuditTestCaseContentView.js: Added.
1121         (WI.AuditTestCaseContentView):
1122         (WI.AuditTestCaseContentView.prototype.initialLayout):
1123         (WI.AuditTestCaseContentView.prototype.layout):
1124         (WI.AuditTestCaseContentView.prototype.showRunningPlaceholder):
1125         * UserInterface/Views/AuditTestCaseContentView.css: Added.
1126         (.content-view-container > .content-view.audit-test-case > header):
1127         (.content-view-container > .content-view.audit-test-case > section > :not(.message-text-view):first-child):
1128         (.content-view.audit-test-case > header > h1):
1129         (.content-view.audit-test-case > header > h1 > img):
1130         (.content-view.audit-test-case > section > :not(.message-text-view)):
1131         (.content-view.audit-test-case > section > :not(.message-text-view):last-child):
1132         (.content-view.audit-test-case > section > :not(.message-text-view) + :not(.message-text-view)):
1133         (.content-view.audit-test-case > section h1):
1134         (.content-view.audit-test-case > section table):
1135         (.content-view.audit-test-case > section table > tr + tr > td):
1136         (.content-view.audit-test-case > section table > tr > td > :not(.tree-outline)):
1137         (.content-view.audit-test-case > section table > tr > td:first-child):
1138         (.content-view.audit-test-case > section > .dom-nodes > table > tr > td:first-child):
1139         (.content-view.audit-test-case > section code):
1140         (.content-view.audit-test-case > section mark):
1141
1142         * UserInterface/Views/AuditTestGroupContentView.js: Added.
1143         (WI.AuditTestGroupContentView):
1144         (WI.AuditTestGroupContentView.prototype.initialLayout):
1145         (WI.AuditTestGroupContentView.prototype.layout):
1146         (WI.AuditTestGroupContentView.prototype.shown):
1147         (WI.AuditTestGroupContentView.prototype.hidden):
1148         (WI.AuditTestGroupContentView.prototype.applyFilter):
1149         (WI.AuditTestGroupContentView.prototype.resetFilter):
1150         (WI.AuditTestGroupContentView.prototype.showRunningPlaceholder):
1151         (WI.AuditTestGroupContentView.prototype._subobjects):
1152         (WI.AuditTestGroupContentView.prototype._updateLevelScopeBar):
1153         (WI.AuditTestGroupContentView.prototype._handleTestGroupCompleted):
1154         (WI.AuditTestGroupContentView.prototype._handleTestGroupProgress):
1155         (WI.AuditTestGroupContentView.prototype._handleTestGroupScheduled):
1156         (WI.AuditTestGroupContentView.prototype._handleLevelScopeBarSelectionChanged):
1157         * UserInterface/Views/AuditTestGroupContentView.css: Added.
1158         (.content-view-container > .content-view.audit-test-group > header):
1159         (.content-view.audit-test-group > header):
1160         (.content-view.audit-test-group.no-matches + .audit-test-group > header):
1161         (.content-view.audit-test-group > header, .content-view.audit-test-group:not(.filtered):last-child > header):
1162         (.content-view.audit-test-group.contains-test-case > header):
1163         (.content-view.audit-test-group.contains-test-case + .audit-test-group.contains-test-case):
1164         (.content-view.audit-test-group.contains-test-case:not(.contains-test-group) > section, .content-view.audit-test-group.contains-test-case.contains-test-group > section > .audit-test-case):
1165         (.content-view.audit-test-group > header > .information):
1166         (.content-view.audit-test-group > header > .information > p):
1167         (.content-view.audit-test-group > header > nav):
1168         (.content-view.audit-test-group > header > nav:empty):
1169         (.content-view.audit-test-group > header > nav:not(:empty):before):
1170         (.content-view.audit-test-group > header > nav > .scope-bar > li):
1171         (.content-view.audit-test-group > header > nav > .scope-bar > li:not(:hover, .selected)):
1172         (.content-view.audit-test-group > header > nav > .scope-bar > li:last-child):
1173         (.content-view.audit-test-group > header > nav > .scope-bar > li::before):
1174         (.content-view.audit-test-group > header > nav > .scope-bar > li.pass::before):
1175         (.content-view.audit-test-group > header > nav > .scope-bar > li.warn::before):
1176         (.content-view.audit-test-group > header > nav > .scope-bar > li.fail::before):
1177         (.content-view.audit-test-group > header > nav > .scope-bar > li.error::before):
1178         (.content-view.audit-test-group > header > nav > .scope-bar > li.unsupported::before):
1179         (.content-view.audit-test-group > header > .percentage-pass):
1180         (.content-view.audit-test-group > header > .percentage-pass:not(:empty)::after):
1181         (.content-view.audit-test-group > section > .audit-test-case:first-child, .content-view.audit-test-group > section > .audit-test-group + .audit-test-case, .content-view.audit-test-group > section > .audit-test-case + .audit-test-group):
1182         (.content-view.audit-test-group > section > .audit-test-case:last-child):
1183
1184         * UserInterface/Views/ScopeBarItem.js:
1185         (WI.ScopeBarItem):
1186         (WI.ScopeBarItem.prototype.set selected):
1187         * UserInterface/Views/MultipleScopeBarItem.js:
1188         (WI.MultipleScopeBarItem.prototype.set selectedScopeBarItem):
1189         Add an `independent` option that prevents selection changes from deselecting other
1190         `WI.ScopeBarItem`s in the same `WI.ScopeBar` (`exclusive` takes precedence).
1191
1192         * UserInterface/Views/DOMTreeElement.js:
1193         (WI.DOMTreeElement):
1194         (WI.DOMTreeElement.prototype.highlightAttribute):
1195         (WI.DOMTreeElement.prototype._buildAttributeDOM):
1196         * UserInterface/Views/DOMTreeOutline.css:
1197         (.tree-outline.dom li .highlight):
1198
1199         * UserInterface/Views/ToggleButtonNavigationItem.js:
1200         (WI.ToggleButtonNavigationItem.prototype.set toggled):
1201         Also change the `label` if the `ButtonStyle` has text.
1202
1203         * UserInterface/Base/Setting.js:
1204         * UserInterface/Views/SettingsTabContentView.js:
1205         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1206
1207         * UserInterface/Views/DividerNavigationItem.css:
1208         (.navigation-bar .item.divider):
1209
1210         * UserInterface/Base/Utilities.js:
1211         (Promise.chain): Added.
1212
1213         * UserInterface/Views/ContentView.js:
1214         (WI.ContentView.createFromRepresentedObject):
1215         (WI.ContentView.isViewable):
1216
1217         * UserInterface/Main.html:
1218         * UserInterface/Base/Main.js:
1219         (WI.loaded):
1220         (WI.contentLoaded):
1221
1222         * UserInterface/Test.html:
1223         * UserInterface/Base/Test.js:
1224         (WI.loaded):
1225
1226         * UserInterface/Images/Audit.svg: Added.
1227         * UserInterface/Images/AuditStart.svg: Added.
1228         * UserInterface/Images/AuditStop.svg: Added.
1229         * UserInterface/Images/AuditTestCase.svg: Added.
1230         * UserInterface/Images/AuditTestCaseResult.svg: Added.
1231         * UserInterface/Images/AuditTestError.svg: Added.
1232         * UserInterface/Images/AuditTestFail.svg: Added.
1233         * UserInterface/Images/AuditTestGroup.svg: Added.
1234         * UserInterface/Images/AuditTestGroupResult.svg: Added.
1235         * UserInterface/Images/AuditTestNoResult.svg: Added.
1236         * UserInterface/Images/AuditTestPass.svg: Added.
1237         * UserInterface/Images/AuditTestUnsupported.svg: Added.
1238         * UserInterface/Images/AuditTestWarn.svg: Added.
1239
1240         * Localizations/en.lproj/localizedStrings.js:
1241
1242 2018-10-30  Devin Rousso  <drousso@apple.com>
1243
1244         Web Inspector: provide options to WI.cssPath for more verbosity
1245         https://bugs.webkit.org/show_bug.cgi?id=190987
1246
1247         Reviewed by Brian Burg.
1248
1249         * UserInterface/Base/DOMUtilities.js:
1250         (WI.cssPath):
1251         (WI.cssPathComponent):
1252         When the option `full` is true, print every attribute along with every node in the hierarchy
1253         until the root is reached. This partially duplicates the effect of an XPath, but instead
1254         uses CSS selectors, making it much more human readable and recognizable.
1255
1256 2018-10-30  Devin Rousso  <drousso@apple.com>
1257
1258         Web Inspector: change WI.ColorWheel to use conic-gradient()
1259         https://bugs.webkit.org/show_bug.cgi?id=189485
1260
1261         Reviewed by Brian Burg.
1262
1263         Use the ("new") HSL `WI.ColorPicker` if `conic-gradient` is supported. Otherwise, use the
1264         ("old") RGB `WI.LegacyColorPicker`.
1265
1266         * UserInterface/Views/ColorWheel.js:
1267         (WI.ColorWheel):
1268         (WI.ColorWheel.prototype.set dimension):
1269         (WI.ColorWheel.prototype.set brightness):
1270         (WI.ColorWheel.prototype.get tintedColor):
1271         (WI.ColorWheel.prototype.set tintedColor):
1272         (WI.ColorWheel.prototype.get rawColor):
1273         (WI.ColorWheel.prototype.get _hue): Added.
1274         (WI.ColorWheel.prototype.get _saturation): Added.
1275         (WI.ColorWheel.prototype._updateColorForMouseEvent):
1276         (WI.ColorWheel.prototype._setCrosshairPosition):
1277         (WI.ColorWheel.prototype._updateGradient): Added.
1278         (WI.ColorWheel.prototype._pointInCircleForEvent.distance): Deleted.
1279         (WI.ColorWheel.prototype._pointInCircleForEvent.angleFromCenterToPoint): Deleted.
1280         (WI.ColorWheel.prototype._pointInCircleForEvent.pointOnCircumference): Deleted.
1281         (WI.ColorWheel.prototype._pointInCircleForEvent): Deleted.
1282         (WI.ColorWheel.prototype._tintedColorToPointAndBrightness): Deleted.
1283         (WI.ColorWheel.prototype._drawRawCanvas): Deleted.
1284         (WI.ColorWheel.prototype._colorAtPointWithBrightness): Deleted.
1285         (WI.ColorWheel.prototype._drawTintedCanvas): Deleted.
1286         (WI.ColorWheel.prototype._draw): Deleted.
1287         * UserInterface/Views/ColorWheel.css:
1288         (.color-wheel > .gradient): Added.
1289         (.color-wheel > .crosshair): Added.
1290
1291         * UserInterface/Views/LegacyColorWheel.js: Copied from Source/WebInspectorUI/UserInterface/Views/ColorWheel.js.
1292
1293         * UserInterface/Views/ColorPicker.js:
1294         (WI.ColorPicker):
1295         (WI.ColorPicker.supportsConicGradient): Added.
1296         (WI.ColorPicker.prototype._updateSliders):
1297
1298         * UserInterface/Models/Geometry.js:
1299         (WI.Point.prototype.distance):
1300
1301         * UserInterface/Main.html:
1302
1303 2018-10-30  Devin Rousso  <drousso@apple.com>
1304
1305         Web Inspector: make the layers sidebar in the Elements tab always visible
1306         https://bugs.webkit.org/show_bug.cgi?id=190158
1307
1308         Reviewed by Brian Burg.
1309
1310         * UserInterface/Views/ElementsTabContentView.js:
1311         (WI.ElementsTabContentView):
1312         * UserInterface/Views/SearchTabContentView.js:
1313         (WI.SearchTabContentView):
1314
1315 2018-10-30  Devin Rousso  <drousso@apple.com>
1316
1317         Web Inspector: refactor WI.ScopeBarItem for better extensibility
1318         https://bugs.webkit.org/show_bug.cgi?id=190986
1319
1320         Reviewed by Brian Burg.
1321
1322         Renames `withModifier` to `extendSelection` for clarity of usage, and to allow the changes
1323         in <https://webkit.org/b/190754> (adding an option to allow `WI.ScopeBarItem`s to be
1324         selected without deselcting any other `WI.ScopeBarItem`s) to use the same variable.
1325
1326         * UserInterface/Views/ScopeBarItem.js:
1327         (WI.ScopeBarItem):
1328         (WI.ScopeBarItem.prototype.set selected):
1329         (WI.ScopeBarItem.prototype._handleMouseDown):
1330         (WI.ScopeBarItem.prototype.setSelected): Deleted.
1331
1332         * UserInterface/Views/ScopeBar.js:
1333         (WI.ScopeBar):
1334         (WI.ScopeBar.prototype._populate):
1335         (WI.ScopeBar.prototype._itemSelectionDidChange):
1336
1337         * UserInterface/Views/MultipleScopeBarItem.js:
1338         (WI.MultipleScopeBarItem.prototype.set selectedScopeBarItem):
1339
1340         * UserInterface/Views/CanvasSidebarPanel.js:
1341         (WI.CanvasSidebarPanel.prototype._updateRecordingScopeBar):
1342         * UserInterface/Views/LogContentView.js:
1343         (WI.LogContentView):
1344         * UserInterface/Views/NetworkTableContentView.js:
1345         (WI.NetworkTableContentView):
1346         * UserInterface/Views/ResourceSidebarPanel.js:
1347         (WI.ResourceSidebarPanel):
1348         * UserInterface/Views/StorageSidebarPanel.js:
1349         (WI.StorageSidebarPanel):
1350
1351 2018-10-29  Nikita Vasilyev  <nvasilyev@apple.com>
1352
1353         Web Inspector: Flash views with red outline on initial layout
1354         https://bugs.webkit.org/show_bug.cgi?id=191048
1355
1356         Reviewed by Devin Rousso.
1357
1358         * UserInterface/Views/View.js:
1359         (WI.View.prototype._layoutSubtree):
1360         (WI.View.prototype._drawLayoutFlashingOutline):
1361
1362 2018-10-29  Devin Rousso  <drousso@apple.com>
1363
1364         Web Inspector: Canvas: show warning when path moves offscreen
1365         https://bugs.webkit.org/show_bug.cgi?id=191016
1366
1367         Reviewed by Joseph Pecoraro.
1368
1369         * UserInterface/Models/RecordingAction.js:
1370         (WI.RecordingAction):
1371         (WI.RecordingAction.deriveCurrentState):
1372         (WI.RecordingAction.prototype.get isVisual):
1373         (WI.RecordingAction.prototype.get warning): Added.
1374         (WI.RecordingAction.prototype.process.checkInvalidCurrentAxisPoint): Added.
1375         (WI.RecordingAction.prototype.process):
1376         (WI.RecordingAction.prototype.get hasVisibleEffect): Deleted.
1377         Replace `hasVisibleEffect` with a more general `warning` value, so that it can be used for
1378         more types of warnings.
1379
1380         * UserInterface/Views/RecordingActionTreeElement.js:
1381         (WI.RecordingActionTreeElement.prototype.onattach):
1382         * UserInterface/Views/RecordingActionTreeElement.css:
1383         (.item.action.visual.warning:not(.invalid) > .status > .warning): Added.
1384         (.item.action.visual.no-visible-effect:not(.invalid) > .status > .warning): Deleted.
1385
1386         * Localizations/en.lproj/localizedStrings.js:
1387
1388 2018-10-29  Devin Rousso  <drousso@apple.com>
1389
1390         Web Inspector: refactor code for getting properties via WI.RemoteObject
1391         https://bugs.webkit.org/show_bug.cgi?id=190989
1392
1393         Reviewed by Matt Baker.
1394
1395         * UserInterface/Protocol/RemoteObject.js:
1396         (WI.RemoteObject.prototype.getPropertyDescriptors): Added.
1397         (WI.RemoteObject.prototype.getPropertyDescriptorsAsObject): Added.
1398         (WI.RemoteObject.prototype.getOwnPropertyDescriptors): Deleted.
1399         (WI.RemoteObject.prototype.getAllPropertyDescriptors): Deleted.
1400         (WI.RemoteObject.prototype._getPropertyDescriptors): Deleted.
1401         (WI.RemoteObject.prototype.getOwnPropertyDescriptorsAsObject): Deleted.
1402
1403         * UserInterface/Views/ErrorObjectView.js:
1404         (WI.ErrorObjectView.prototype.update):
1405         * UserInterface/Views/ObjectTreePropertyTreeElement.js:
1406         (WI.ObjectTreePropertyTreeElement.prototype._updateChildren):
1407         * UserInterface/Views/ObjectTreeView.js:
1408         (WI.ObjectTreeView.prototype.update):
1409
1410 2018-10-29  Tim Horton  <timothy_horton@apple.com>
1411
1412         Modernize WebKit nibs and lprojs for localization's sake
1413         https://bugs.webkit.org/show_bug.cgi?id=190911
1414         <rdar://problem/45349466>
1415
1416         Reviewed by Dan Bernstein.
1417
1418         * WebInspectorUI.xcodeproj/project.pbxproj:
1419         English->en
1420
1421 2018-10-29  Devin Rousso  <drousso@apple.com>
1422
1423         Web Inspector: prevent Canvas tab from listening for "space" when not visibile
1424         https://bugs.webkit.org/show_bug.cgi?id=190988
1425
1426         Reviewed by Joseph Pecoraro.
1427
1428         * UserInterface/Views/CanvasTabContentView.js:
1429         (WI.CanvasTabContentView):
1430         (WI.CanvasTabContentView.prototype.shown):
1431         (WI.CanvasTabContentView.prototype.hidden): Added.
1432
1433 2018-10-27  Matt Baker  <mattbaker@apple.com>
1434
1435         Web Inspector: Table should support deleting rows
1436         https://bugs.webkit.org/show_bug.cgi?id=189803
1437         <rdar://problem/44655709>
1438
1439         Reviewed by Devin Rousso.
1440
1441         Add methods for removing rows from a Table without reloading the data
1442         source. This patch adds Table.prototype.removeRow for removing a single
1443         row, and Table.prototype.removeSelectedRows for removing the entire selection.
1444         The latter also attempts to select a new row, if possible, before removing
1445         the selection.
1446
1447         * UserInterface/Base/IndexSet.js:
1448         (WI.IndexSet.prototype.copy):
1449
1450         * UserInterface/Views/Table.js:
1451         (WI.Table):
1452         (WI.Table.prototype.get numberOfRows):
1453         Cache the number of rows in the table data source. Invalidate cached
1454         value whenever table data is reloaded. Removing rows immediately updates
1455         cached value, without incurring a potentially expensive reload.
1456
1457         (WI.Table.prototype.reloadData):
1458         (WI.Table.prototype.selectRow):
1459         (WI.Table.prototype.deselectRow):
1460         (WI.Table.prototype.removeRow):
1461         (WI.Table.prototype.removeSelectedRows):
1462         Remove the selected rows and select a new row, if possible.
1463         (WI.Table.prototype._updateVisibleRows):
1464         (WI.Table.prototype._handleKeyDown):
1465         (WI.Table.prototype._deselectAllAndSelect):
1466         Drive-by fix: should work when `rowToSelect` isn't already selected.
1467         (WI.Table.prototype._removeRows):
1468         Remove rows and adjust the indexes of rows that are shifted up as a result
1469         of preceding rows being removed.
1470
1471 2018-10-26  Devin Rousso  <drousso@apple.com>
1472
1473         Web Inspector: simplify some editing code checks
1474         https://bugs.webkit.org/show_bug.cgi?id=190970
1475
1476         Reviewed by Joseph Pecoraro.
1477
1478         * UserInterface/Base/Main.js:
1479         (WI._focusChanged):
1480
1481         * UserInterface/Base/Utilities.js:
1482
1483         * UserInterface/Views/EditingSupport.js:
1484         (WI.enclosingCodeMirror): Added.
1485         (WI.isBeingEdited):
1486         (WI.isEventTargetAnEditableField):
1487
1488         * UserInterface/Views/QuickConsole.js:
1489         (WI.QuickConsole):
1490
1491 2018-10-26  Devin Rousso  <drousso@apple.com>
1492
1493         Web Inspector: Uncaught Exception: undefined is not an object (evaluating 'this._classListContainer.children')
1494         https://bugs.webkit.org/show_bug.cgi?id=190966
1495
1496         Reviewed by Joseph Pecoraro.
1497
1498         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.js:
1499         (WI.GeneralStyleDetailsSidebarPanel.prototype.layout):
1500         (WI.GeneralStyleDetailsSidebarPanel.prototype._classToggleButtonClicked):
1501         (WI.GeneralStyleDetailsSidebarPanel.prototype._populateClassToggles):
1502         Don't try to reload the class toggles if the we haven't `layout` yet, as the element won't
1503         yet exist.
1504
1505 2018-10-25  Devin Rousso  <drousso@apple.com>
1506
1507         Web Inspector: Canvas Recording loading goes significantly slower when "Frame" tree element is expanded
1508         https://bugs.webkit.org/show_bug.cgi?id=190497
1509
1510         Reviewed by Joseph Pecoraro.
1511
1512         Save the `WI.TreeElement` that are in the DOM, and compare that with any `WI.TreeElement`
1513         that would be added to the DOM. If all of the following are true, don't edit the DOM:
1514          - no focused `WI.TreeElement` that isn't currently visible (we would scroll otherwise)
1515          - the set of previously visible `WI.TreeElement`s (e.g. not used for scroll padding) has at
1516            least one of the `WI.TreeElement`s that would be added from this update
1517             - this means that the user hasn't scrolled beyond the padding `WI.TreeElement`
1518          - there are no `WI.TreeElement`s that would be added from this update that were NOT added
1519            in a previous update
1520             - this covers the case that a `WI.TreeElement` is inserted in the visible area
1521
1522         * UserInterface/Base/Utilities.js:
1523
1524         * UserInterface/Views/TreeOutline.js:
1525         (WI.TreeOutline):
1526         (WI.TreeOutline.prototype.registerScrollVirtualizer):
1527         (WI.TreeOutline.prototype.updateVirtualizedElements.walk):
1528         (WI.TreeOutline.prototype.updateVirtualizedElements):
1529
1530 2018-10-25  Joseph Pecoraro  <pecoraro@apple.com>
1531
1532         JSContext Inspector: Broken frontend, DOMAgent is used but does not exist
1533         https://bugs.webkit.org/show_bug.cgi?id=190922
1534         <rdar://problem/45569827>
1535
1536         Reviewed by Devin Rousso.
1537
1538         * UserInterface/Controllers/DOMManager.js:
1539         (WI.DOMManager.prototype.requestDocument):
1540         Feature check for agents that may not exist in a JSContext.
1541
1542 2018-10-25  Devin Rousso  <drousso@apple.com>
1543
1544         Web Inspector: add corner rounding to the network timing "blocks"
1545         https://bugs.webkit.org/show_bug.cgi?id=190379
1546
1547         Reviewed by Timothy Hatcher.
1548
1549         * UserInterface/Views/NetworkTableContentView.css:
1550         (.waterfall .block):
1551         (body[dir=ltr] .waterfall .block): Added.
1552         (body[dir=rtl] .waterfall .block): Added.
1553         (.network-table .waterfall .block + .block): Added.
1554         (.network-table .waterfall .block.filler + .block, .network-table .waterfall .block:not(.request, .response) + :matches(.request, .response)): Added.
1555         (.network-table .waterfall .block:last-child): Added.
1556
1557 2018-10-25  Devin Rousso  <drousso@apple.com>
1558
1559         Web Inspector: display fullscreen enter/exit events in Timelines and Network node waterfalls
1560         https://bugs.webkit.org/show_bug.cgi?id=189874
1561         <rdar://problem/44700000>
1562
1563         Reviewed by Joseph Pecoraro.
1564
1565         * Localizations/en.lproj/localizedStrings.js:
1566
1567         * UserInterface/Protocol/DOMObserver.js:
1568         (WI.DOMObserver.prototype.didFireEvent):
1569         * UserInterface/Controllers/DOMManager.js:
1570         (WI.DOMManager.prototype.didFireEvent):
1571         Allow `data` to be passed to the frontend with `didFireEvent`.
1572
1573         * UserInterface/Models/DOMNode.js:
1574         (WI.DOMNode):
1575         (WI.DOMNode.getFullscreenDOMEvents): Added.
1576         (WI.DOMNode.prototype.didFireEvent):
1577         (WI.DOMNode.prototype._handleDOMNodeDidFireEvent): Added.
1578         (WI.DOMNode.prototype._addDOMEvent):
1579         (WI.DOMNode.prototype._shouldListenForEventListeners): Added.
1580         If an event is fired on an ancestor of this node, also record that event in this node's
1581         `domEvents`, including the `originator` node.
1582
1583         * UserInterface/Views/NetworkTableContentView.js:
1584         (WI.NetworkTableContentView.prototype._populateWaterfallGraph):
1585         * UserInterface/Views/NetworkTableContentView.css:
1586         (.network-table :not(.header) .cell.waterfall .waterfall-container > .dom-fullscreen): Added.
1587
1588         * UserInterface/Views/DOMEventsBreakdownView.js:
1589         (WI.DOMEventsBreakdownView.prototype.initialLayout):
1590         (WI.DOMEventsBreakdownView.prototype._populateTable):
1591         * UserInterface/Views/DOMEventsBreakdownView.css:
1592         (.dom-events-breakdown .graph > .area.fullscreen): Added.
1593         (.dom-events-breakdown .inherited > .name, .dom-events-breakdown .inherited > .graph > .point): Added.
1594         (.dom-events-breakdown:not(.has-inherited) .originator): Added.
1595
1596 2018-10-25  Devin Rousso  <drousso@apple.com>
1597
1598         Web Inspector: Network: more aggressively snap timing blocks together
1599         https://bugs.webkit.org/show_bug.cgi?id=190439
1600
1601         Reviewed by Timothy Hatcher.
1602
1603         * UserInterface/Views/NetworkTableContentView.js:
1604         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.appendBlock):
1605         (WI.NetworkTableContentView.prototype._populateWaterfallGraph):
1606         If the time difference between the end of the previous block and the start of this block
1607         would result in less than 2px of space, extend the next block back to the previous block.
1608
1609 2018-10-24  Devin Rousso  <drousso@apple.com>
1610
1611         Web Inspector: popovers for function source code are malformed
1612         https://bugs.webkit.org/show_bug.cgi?id=190859
1613
1614         Reviewed by Joseph Pecoraro.
1615
1616         Previously, the `WI.Popover` would be drawn twice: once when the
1617         `WI.CodeMirrorTokenTrackingController` determines that the user has hovered on a function
1618         token, and once again when the source for that function is formatted (after being retrieved).
1619         In the case that the formatter is able to return the prettified source within a frame (or
1620         two), the `WI.Popover` is still in the middle of animating to its new size, meaning that the
1621         changes made by the formatted `update` will be overridden on the next rAF (creates a flash).
1622
1623         * UserInterface/Views/Popover.js:
1624         (WI.Popover.prototype):
1625         (WI.Popover.prototype._animateFrame.drawBackground):
1626         (WI.Popover.prototype._drawBackground):
1627         Add a member variable to make sure that there is only ever one rAF firing at a time.
1628         Drive-by: rework the background code to only use one canvas.
1629
1630         * UserInterface/Views/SourceCodeTextEditor.js:
1631         (WI.SourceCodeTextEditor.prototype._showPopoverForFunction.didGetDetails):
1632         Don't show the `WI.Popover` until the formatter has finished prettifying the function's
1633         source code, as otherwise there is brief moment that the popover appears and is empty.
1634
1635 2018-10-24  Devin Rousso  <drousso@apple.com>
1636
1637         Web Inspector: REGRESSION (r237232): changing resources via up/down blurs the TreeOutline in Resources
1638         https://bugs.webkit.org/show_bug.cgi?id=190862
1639
1640         Reviewed by Matt Baker.
1641
1642         * UserInterface/Views/TextEditor.js:
1643         (WI.TextEditor.prototype.set selectedTextRange):
1644         Don't `focus` unless the `activeElement` is not a WebInspector element (e.g. <body>),
1645         meaning that the previously focused element has been removed from the DOM and no longer
1646         needs to keep the focus.
1647
1648 2018-10-24  Devin Rousso  <drousso@apple.com>
1649
1650         Web Inspector: CSP request payload on medium.com is unreadable, should be pretty-printed
1651         https://bugs.webkit.org/show_bug.cgi?id=190354
1652         <rdar://problem/45090894>
1653
1654         Reviewed by Joseph Pecoraro.
1655
1656         * UserInterface/Views/TextEditor.js:
1657         (WI.TextEditor.prototype.set string.update):
1658         (WI.TextEditor.prototype._attemptToDetermineMIMEType): Added.
1659         If the content doesn't already have a MIME type, attempt to determine one by trying to
1660         format it as "javascript" (e.g. request JSON that is simply missing a MIME type).
1661
1662         * UserInterface/Views/TextContentView.js:
1663         (WI.TextContentView):
1664         (WI.TextContentView.prototype._handleTextEditorMIMETypeChanged): Added.
1665         * UserInterface/Views/TextResourceContentView.js:
1666         (WI.TextResourceContentView):
1667         (WI.TextResourceContentView.prototype._handleTextEditorMIMETypeChanged): Added.
1668         * UserInterface/Views/ScriptContentView.js:
1669         (WI.ScriptContentView):
1670         (WI.ScriptContentView.prototype._handleTextEditorMIMETypeChanged): Added.
1671         Enable the "Pretty Print" navigation button if the MIME type changes to something that is
1672         able to be formatted.
1673         Drive-by: reorder the creation of the "Pretty Print" button so that it exists if
1674         `_attemptToDetermineMIMEType` finishes synchronously.
1675
1676 2018-10-23  Devin Rousso  <drousso@apple.com>
1677
1678         Uncaught Exception: TypeError: null is not an object (evaluating 'mouseBlock.addEventListener')
1679         https://bugs.webkit.org/show_bug.cgi?id=190766
1680
1681         Reviewed by Brian Burg.
1682
1683         * UserInterface/Views/NetworkTableContentView.js:
1684         (WI.NetworkTableContentView.prototype._populateWaterfallGraph):
1685         When creating the `mouseBlock`, if the `startTimestamp` and `endTimestamp` are equal, we
1686         don't create an element. If this is true for the total range of the `WI.Resouce` (meaning
1687         its `startTime` and `responseEnd`), don't even try to create blocks.
1688
1689 2018-10-23  Devin Rousso  <drousso@apple.com>
1690
1691         Web Inspector: "Queued NaNms" in Network tab
1692         https://bugs.webkit.org/show_bug.cgi?id=190767
1693         <rdar://problem/45420859>
1694
1695         Reviewed by Brian Burg.
1696
1697         * UserInterface/Models/ResourceTimingData.js:
1698         (WI.ResourceTimingData.prototype.get fetchStart):
1699         If the `WI.ResourceTimingData` has no `fetchStart` use the associated `WI.Resource`'s
1700         `requestSentTimestamp` (just like `startTime`).
1701
1702 2018-10-22  Joseph Pecoraro  <pecoraro@apple.com>
1703
1704         Web Inspector: Open Quickly dialog doesn't show named scripts that appear in the debugger sidebar
1705         https://bugs.webkit.org/show_bug.cgi?id=190649
1706
1707         Reviewed by Devin Rousso.
1708
1709         * UserInterface/Views/OpenResourceDialog.js:
1710         (WI.OpenResourceDialog.prototype.didPresentDialog):
1711         (WI.OpenResourceDialog.prototype._addResourcesForTarget):
1712         (WI.OpenResourceDialog.prototype._addScriptsForTarget):
1713         Include non-resource named scripts from the main target in
1714         the open quickly dialog.
1715
1716 2018-10-19  Joseph Pecoraro  <pecoraro@apple.com>
1717
1718         Web Inspector: Remove unused member variable of DebuggerSidebarPanel
1719         https://bugs.webkit.org/show_bug.cgi?id=190743
1720
1721         Reviewed by Devin Rousso.
1722
1723         * UserInterface/Views/DebuggerSidebarPanel.js:
1724         (WI.DebuggerSidebarPanel):
1725
1726 2018-10-17  Devin Rousso  <drousso@apple.com>
1727
1728         Web Inspector: Quickly Open to line/column does should have caret indicating where the position is
1729         https://bugs.webkit.org/show_bug.cgi?id=190643
1730
1731         Reviewed by Matt Baker.
1732
1733         * UserInterface/Views/TextEditor.js:
1734         (WI.TextEditor.prototype.set selectedTextRange):
1735         (WI.TextEditor.prototype.revealPosition):
1736         Ensure that CodeMirror is focused before attempting to `setSelection`.
1737         Drive-by: allow selections past the "end" of the line (since there is a `\n` or `\r`).
1738
1739         * UserInterface/Views/SourceCodeTextEditor.js:
1740         (WI.SourceCodeTextEditor.prototype.dialogWasDismissedWithRepresentedObject):
1741         Remove the extra `focus` call after dismissing the `WI.GoToLineDialog` since it is now
1742         handled by `WI.TextEditor` via `revealPosition`.
1743
1744 2018-10-16  Joseph Pecoraro  <pecoraro@apple.com>
1745
1746         Web Inspector: ⌃G to jump to line in CSS file wipes the line
1747         https://bugs.webkit.org/show_bug.cgi?id=190645
1748
1749         Reviewed by Devin Rousso.
1750
1751         * UserInterface/Base/Main.js:
1752         * UserInterface/Views/Dialog.js:
1753         (WI.Dialog.prototype.dismiss):
1754         * UserInterface/Views/SourceCodeTextEditor.js:
1755         (WI.SourceCodeTextEditor.prototype.dialogWasDismissed): Deleted.
1756         Rename the handler when dismissing a dialog with a value so that
1757         it is clear this is only on a successful value and not an invalid value.
1758         Dialog now only calls this delegate with a valid value. This addresses
1759         exceptions seen when the GoToLineDialog was dimissed via Escape and
1760         an unexpected `null` value was being handled in the delegate.
1761
1762         * UserInterface/Views/GoToLineDialog.js:
1763         (WI.GoToLineDialog.prototype._handleKeydownEvent):
1764         * UserInterface/Views/OpenResourceDialog.js:
1765         (WI.OpenResourceDialog.prototype._handleKeydownEvent):
1766         Prevent default on the event whenever we dismiss the dialog.
1767         Without this, the key event was also being sent to the editor.
1768         In this case, that meant an "Enter" key was replacing the new
1769         selection in the TextEditor with a newline!
1770
1771 2018-10-16  Devin Rousso  <drousso@apple.com>
1772
1773         Web Inspector: Canvas: capture previously saved states and add them to the recording payload
1774         https://bugs.webkit.org/show_bug.cgi?id=190473
1775
1776         Reviewed by Joseph Pecoraro.
1777
1778         Instead of sending a single object of the current state of the context, send an array of
1779         objects, one for each restore point. When replaying, recreate each restore point before
1780         applying the selected action(s).
1781
1782         * UserInterface/Models/Recording.js:
1783         (WI.Recording):
1784         (WI.Recording.fromPayload):
1785         (WI.Recording.prototype.toJSON):
1786         (WI.Recording.prototype.async._process):
1787         (WI.Recording.prototype.async._swizzleState): Added.
1788         * UserInterface/Models/RecordingAction.js:
1789         (WI.RecordingAction):
1790         (WI.RecordingAction.deriveCurrentState): Added.
1791         (WI.RecordingAction.prototype.get states): Added.
1792         (WI.RecordingAction.prototype.process):
1793         (WI.RecordingAction.prototype.get state): Deleted.
1794         Drive-by: when `process`ing, also check to see if any values in the current state changed
1795         outside of those expected in `_stateModifiers` (e.g. `restore` may modify some state values).
1796
1797         * UserInterface/Views/RecordingContentView.js:
1798         (WI.RecordingContentView.prototype._generateContentCanvas2D):
1799
1800         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
1801         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
1802         Default to showing the most recent (current) state.
1803
1804         * UserInterface/Views/CanvasTabContentView.js:
1805         (WI.CanvasTabContentView.prototype.initialLayout): Added.
1806         (WI.CanvasTabContentView.prototype._addCanvas):
1807         (WI.CanvasTabContentView.prototype._removeCanvas):
1808         (WI.CanvasTabContentView.prototype._addRecording): Added.
1809         (WI.CanvasTabContentView.prototype._recordingImportedOrStopped):
1810         (WI.CanvasTabContentView.prototype._recordingAdded): Deleted.
1811         * UserInterface/Controllers/CanvasManager.js:
1812         (WI.CanvasManager):
1813         (WI.CanvasManager.prototype.get importedRecordings): Added.
1814         (WI.CanvasManager.prototype.importRecording):
1815         Drive-by: store imported recordings on `WI.CanvasManager` so that if the Canvas tab is
1816         closed we can still show the list of imported recordings.
1817
1818 2018-10-16  Devin Rousso  <drousso@apple.com>
1819
1820         Web Inspector: Canvas recording sidebar scroll position lost after switching tabs
1821         https://bugs.webkit.org/show_bug.cgi?id=190482
1822
1823         Reviewed by Joseph Pecoraro.
1824
1825         * UserInterface/Views/Sidebar.js:
1826         (WI.Sidebar.prototype.removeSidebarPanel):
1827         (WI.Sidebar.prototype.set selectedSidebarPanel):
1828         Call `hidden` before setting `selected` to `false`, as that sets `display: none;` on the
1829         element, which sets the `scrollTop` to `0`.
1830
1831         * UserInterface/Views/SidebarPanel.js:
1832         (WI.SidebarPanel.prototype.shown):
1833         (WI.SidebarPanel.prototype.hidden):
1834         (WI.SidebarPanel.prototype.get scrollElement): Added.
1835         Allow subclasses to specify the scrolling element for saving/restoring the scroll position.
1836
1837         * UserInterface/Views/CanvasSidebarPanel.js:
1838         (WI.CanvasSidebarPanel.prototype.get scrollElement): Added.
1839         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
1840         (WI.RecordingStateDetailsSidebarPanel.prototype.get scrollElement): Added.
1841
1842 2018-10-16  Devin Rousso  <drousso@apple.com>
1843
1844         Web Inspector: Should be a way to go directly from an event in the overview view to the specialized timeline for that event
1845         https://bugs.webkit.org/show_bug.cgi?id=135307
1846         <rdar://problem/17273966>
1847
1848         Reviewed by Joseph Pecoraro.
1849
1850         When a `WI.TimelineRecordBar` is clicked, call up the delegate chain to the overview and
1851         adjust the currently selected `WI.TimelineRecordBar` among the `WI.TimelineOverviewGraph`s.
1852         Similarly, selecting a `WI.DataGridNode` in any `WI.TimelineView` subclass will use the same
1853         logic to select the corresponding `WI.TimelineRecordBar`.
1854
1855         * UserInterface/Views/TimelineOverview.js:
1856         (WI.TimelineOverview):
1857         (WI.TimelineOverview.prototype.reset):
1858         (WI.TimelineOverview.prototype._recordSelected):
1859
1860         * UserInterface/Views/TimelineOverviewGraph.js:
1861         (WI.TimelineOverviewGraph):
1862         (WI.TimelineOverviewGraph.prototype.set selectedRecord):
1863         (WI.TimelineOverviewGraph.prototype.get selectedRecordBar): Added.
1864         (WI.TimelineOverviewGraph.prototype.set selectedRecordBar): Added.
1865         (WI.TimelineOverviewGraph.prototype.timelineRecordBarClicked): Added.
1866         (WI.TimelineOverviewGraph.prototype._needsSelectedRecordLayout):
1867
1868         * UserInterface/Views/TimelineRecordBar.js:
1869         (WI.TimelineRecordBar):
1870         (WI.TimelineRecordBar.prototype.get selected): Added.
1871         (WI.TimelineRecordBar.prototype.set selected): Added.
1872         (WI.TimelineRecordBar.prototype._handleClick): Added.
1873         * UserInterface/Views/TimelineRecordBar.css:
1874         (.timeline-record-bar.selected > .segment): Added.
1875         Add a `delegate` that is notified whenever the element is clicked.
1876
1877         * UserInterface/Views/TimelineDataGridNode.js:
1878         (WI.TimelineDataGridNode.prototype.refreshGraph.createBar):
1879         * UserInterface/Views/LayoutTimelineOverviewGraph.js:
1880         (WI.LayoutTimelineOverviewGraph.prototype.updateSelectedRecord):
1881         (WI.LayoutTimelineOverviewGraph.prototype._updateRowLayout.createBar):
1882         * UserInterface/Views/NetworkTimelineOverviewGraph.js:
1883         (WI.NetworkTimelineOverviewGraph.prototype.layout.createBar):
1884         * UserInterface/Views/ScriptTimelineOverviewGraph.js:
1885         (WI.ScriptTimelineOverviewGraph.prototype.layout.createBar):
1886         (WI.ScriptTimelineOverviewGraph.prototype.updateSelectedRecord):
1887
1888         * UserInterface/Views/TimelineRecordingContentView.js:
1889         (WI.TimelineRecordingContentView.prototype.showTimelineViewForTimeline):
1890
1891 2018-10-16  Devin Rousso  <drousso@apple.com>
1892
1893         Web Inspector: sequences of spaces longer than 16 don't show a dot
1894         https://bugs.webkit.org/show_bug.cgi?id=190528
1895
1896         Reviewed by Matt Baker.
1897
1898         * UserInterface/Views/CodeMirrorAdditions.js:
1899         Create a new CSS rule and add it to a unique <style> whenever a whitespace sequence with
1900         a length is seen for the first time.
1901
1902         * UserInterface/Views/CodeMirrorOverrides.css:
1903         (.show-whitespace-characters .CodeMirror .cm-whitespace-1::before): Deleted.
1904         (.show-whitespace-characters .CodeMirror .cm-whitespace-2::before): Deleted.
1905         (.show-whitespace-characters .CodeMirror .cm-whitespace-3::before): Deleted.
1906         (.show-whitespace-characters .CodeMirror .cm-whitespace-4::before): Deleted.
1907         (.show-whitespace-characters .CodeMirror .cm-whitespace-5::before): Deleted.
1908         (.show-whitespace-characters .CodeMirror .cm-whitespace-6::before): Deleted.
1909         (.show-whitespace-characters .CodeMirror .cm-whitespace-7::before): Deleted.
1910         (.show-whitespace-characters .CodeMirror .cm-whitespace-8::before): Deleted.
1911         (.show-whitespace-characters .CodeMirror .cm-whitespace-9::before): Deleted.
1912         (.show-whitespace-characters .CodeMirror .cm-whitespace-10::before): Deleted.
1913         (.show-whitespace-characters .CodeMirror .cm-whitespace-11::before): Deleted.
1914         (.show-whitespace-characters .CodeMirror .cm-whitespace-12::before): Deleted.
1915         (.show-whitespace-characters .CodeMirror .cm-whitespace-13::before): Deleted.
1916         (.show-whitespace-characters .CodeMirror .cm-whitespace-14::before): Deleted.
1917         (.show-whitespace-characters .CodeMirror .cm-whitespace-15::before): Deleted.
1918         (.show-whitespace-characters .CodeMirror .cm-whitespace-16::before): Deleted.
1919
1920 2018-10-15  Charles Vazac  <cvazac@gmail.com>
1921
1922         Web Inspector: Expose Server Timing Response Headers in Network Tab
1923         https://bugs.webkit.org/show_bug.cgi?id=190440
1924
1925         Reviewed by Joseph Pecoraro.
1926
1927         * Localizations/en.lproj/localizedStrings.js: new key "Server Timing:"
1928         * UserInterface/Main.html: add reference to Models/ServerTimingEntry.js
1929         * UserInterface/Models/Resource.js:
1930         (WI.Resource.prototype.get serverTiming):
1931         (WI.Resource.prototype.updateForResponse):
1932         * UserInterface/Models/ServerTimingEntry.js: Added.
1933         (WI.ServerTimingEntry):
1934         (WI.ServerTimingEntry.parseHeaders): parse raw response headers into an array of ServerTimingEntry objects
1935         (WI.ServerTimingEntry.parseHeaders.consumeDelimiter):
1936         (WI.ServerTimingEntry.parseHeaders.consumeToken):
1937         (WI.ServerTimingEntry.):
1938         * UserInterface/Test.html: add reference to Models/ServerTimingEntry.js
1939         * UserInterface/Views/ResourceTimingBreakdownView.js:
1940         (WI.ResourceTimingBreakdownView.prototype._appendServerTimingRow): render a table row per ServerTimingEntry object
1941         (WI.ResourceTimingBreakdownView.prototype.initialLayout):
1942         (WI.ResourceTimingBreakdownView):
1943
1944 2018-10-15  Nikita Vasilyev  <nvasilyev@apple.com>
1945
1946         Web Inspector: Dark Mode: pseudo elements in DOM tree are too dark
1947         https://bugs.webkit.org/show_bug.cgi?id=190541
1948         <rdar://problem/45238443>
1949
1950         Reviewed by Matt Baker.
1951
1952         * UserInterface/Views/DOMTreeOutline.css:
1953         (@media (prefers-dark-interface)):
1954         (.tree-outline.dom .html-pseudo-element):
1955
1956 2018-10-15  Matt Baker  <mattbaker@apple.com>
1957
1958         Web Inspector: REGRESSION (r233824): execution highlight range missing/incorrect in pretty printed code
1959         https://bugs.webkit.org/show_bug.cgi?id=188082
1960         <rdar://problem/42640580>
1961
1962         Reviewed by Joseph Pecoraro.
1963
1964         * UserInterface/Views/SourceCodeTextEditor.js:
1965         (WI.SourceCodeTextEditor.prototype.textEditorExecutionHighlightRange):
1966         TextEditor expects positions returned by the delegate to be relative to
1967         the editor's text content, not the original source code content.
1968
1969         * UserInterface/Views/TextEditor.js:
1970         (WI.TextEditor.prototype._updateExecutionRangeHighlight):
1971         Convert positions to CodeMirror format here rather than in the delegate
1972         method, which is a layer removed from CodeMirror.
1973
1974 2018-10-15  Nikita Vasilyev  <nvasilyev@apple.com>
1975
1976         Web Inspector: Dark Mode: unreadable text when hovering CSS properties while holding Command
1977         https://bugs.webkit.org/show_bug.cgi?id=190548
1978         <rdar://problem/45242098>
1979
1980         Reviewed by Joseph Pecoraro.
1981
1982         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
1983         (.meta-key-pressed .spreadsheet-css-declaration:not(.locked) :matches(.name, .value):not(.editing):hover):
1984         In the light mode the color remained the same.
1985
1986 2018-10-15  Nikita Vasilyev  <nvasilyev@apple.com>
1987
1988         Web Inspector: Dark Mode: style editor warnings should not look like errors
1989         https://bugs.webkit.org/show_bug.cgi?id=190569
1990         <rdar://problem/45261689>
1991
1992         Reviewed by Matt Baker.
1993
1994         Make warnings in the style editor look the same as warnings in the content views.
1995         Unify warning and error background color variables.
1996
1997         * UserInterface/Views/LogContentView.css:
1998         (@media (prefers-dark-interface)):
1999         (.console-error-level):
2000         (.console-warning-level):
2001         * UserInterface/Views/SourceCodeTextEditor.css:
2002         (.source-code.text-editor > .CodeMirror .warning):
2003         (.source-code.text-editor > .CodeMirror .error):
2004         (.source-code.text-editor > .CodeMirror .issue-widget.warning):
2005         (.source-code.text-editor > .CodeMirror .issue-widget.inline.warning):
2006         (.source-code.text-editor > .CodeMirror .issue-widget.error):
2007         (.source-code.text-editor > .CodeMirror .issue-widget.inline.error):
2008         (@media (prefers-dark-interface)):
2009         (.source-code.text-editor > .CodeMirror .issue-widget):
2010         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
2011         (.spreadsheet-style-declaration-editor .property.has-warning):
2012         (.spreadsheet-style-declaration-editor .property.has-warning .warning):
2013         (@media (prefers-dark-interface)):
2014         (.spreadsheet-style-declaration-editor :matches(.name, .value).editing):
2015         * UserInterface/Views/Variables.css:
2016         (:root):
2017         (@media (prefers-dark-interface)):
2018
2019 2018-10-12  Devin Rousso  <drousso@apple.com>
2020
2021         Web Inspector: Canvas: previews aren't removed when the parent view is hidden
2022         https://bugs.webkit.org/show_bug.cgi?id=190525
2023
2024         Reviewed by Matt Baker.
2025
2026         * UserInterface/Views/CanvasTabContentView.js:
2027         (WI.CanvasTabContentView.prototype.attached):
2028
2029         * UserInterface/Controllers/CanvasManager.js:
2030         (WI.CanvasManager.prototype.get canvases):
2031         (WI.CanvasManager.prototype.get shaderPrograms):
2032         Drive-by: simplify these getters.
2033
2034 2018-10-12  Joseph Pecoraro  <pecoraro@apple.com>
2035
2036         Web Inspector: Dark Mode: Highlight text in Network Headers search is too dark
2037         https://bugs.webkit.org/show_bug.cgi?id=190510
2038
2039         Reviewed by Devin Rousso.
2040
2041         * UserInterface/Views/ResourceHeadersContentView.css:
2042         (.resource-headers.showing-find-banner .search-highlight):
2043         Use adaptive text-color.
2044
2045 2018-10-12  Nikita Vasilyev  <nvasilyev@apple.com>
2046
2047         Web Inspector: Dark Mode: wrong color used for "goto arrow" for selected DOM breakpoint tree element
2048         https://bugs.webkit.org/show_bug.cgi?id=190180
2049         <rdar://problem/44927654>
2050
2051         Reviewed by Matt Baker.
2052
2053         * UserInterface/Views/Main.css:
2054         (@media (prefers-dark-interface)):
2055         (:focus .selected .go-to-arrow):
2056
2057 2018-10-11  Devin Rousso  <drousso@apple.com>
2058
2059         Web Inspector: Network: detail view reverts to "Response" when new requests are added
2060         https://bugs.webkit.org/show_bug.cgi?id=190443
2061
2062         Reviewed by Joseph Pecoraro.
2063
2064         * UserInterface/Views/NetworkTableContentView.js:
2065         (WI.NetworkTableContentView.prototype._showDetailView):
2066         Return early if we are already showing a detail view for the selected object.
2067
2068 2018-10-11  Matt Baker  <mattbaker@apple.com>
2069
2070         Web Inspector: remove unused  TreeOutline style .force-focus
2071         https://bugs.webkit.org/show_bug.cgi?id=190480
2072         <rdar://problem/45203484>
2073
2074         Reviewed by Joseph Pecoraro.
2075
2076         * UserInterface/Views/CallFrameTreeElement.css:
2077         (.tree-outline:focus .item.call-frame.selected .status > .status-image):
2078         (.tree-outline:matches(:focus, .force-focus) .item.call-frame.selected .status > .status-image): Deleted.
2079
2080         * UserInterface/Views/CanvasSidebarPanel.css:
2081         (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline:focus .item.processing.selected .subtitle > progress):
2082         (.sidebar > .panel.navigation.canvas > .content > .recording-content > .tree-outline:matches(:focus, .force-focus) .item.processing.selected .subtitle > progress): Deleted.
2083
2084         * UserInterface/Views/DataGrid.css:
2085         (body[dir=ltr] .data-grid:focus tr.selected td:not(:last-child)):
2086         (body[dir=rtl] .data-grid:focus tr.selected td:not(:last-child)):
2087         (.data-grid:focus tr.parent.selected td.disclosure::before):
2088         (.data-grid:focus tr.parent.expanded.selected td.disclosure::before):
2089         (.data-grid:focus tr.selected):
2090         (.data-grid:focus tr.selected td .subtitle):
2091         (body:not(.window-inactive, .window-docked-inactive) .data-grid:focus tr.editable.selected .cell-content > input):
2092         (@media (prefers-dark-interface)):
2093         (body[dir=ltr] .data-grid:matches(:focus, .force-focus) tr.selected td:not(:last-child)): Deleted.
2094         (body[dir=rtl] .data-grid:matches(:focus, .force-focus) tr.selected td:not(:last-child)): Deleted.
2095         (.data-grid:matches(:focus, .force-focus) tr.parent.selected td.disclosure::before): Deleted.
2096         (.data-grid:matches(:focus, .force-focus) tr.parent.expanded.selected td.disclosure::before): Deleted.
2097         (.data-grid:matches(:focus, .force-focus) tr.selected): Deleted.
2098         (.data-grid:matches(:focus, .force-focus) tr.selected td .subtitle): Deleted.
2099         (body:not(.window-inactive, .window-docked-inactive) .data-grid:matches(:focus, .force-focus) tr.editable.selected .cell-content > input): Deleted.
2100
2101         * UserInterface/Views/Main.css:
2102         (:focus .selected .go-to-arrow):
2103         (:focus .selected .go-to-arrow:active):
2104         (:matches(:focus, .force-focus) .selected .go-to-arrow): Deleted.
2105         (:matches(:focus, .force-focus) .selected .go-to-arrow:active): Deleted.
2106
2107         * UserInterface/Views/ProfileView.css:
2108         (.profile > .data-grid:focus tr.selected td .location):
2109         (.profile > .data-grid:matches(:focus, .force-focus) tr.selected td .location): Deleted.
2110
2111         * UserInterface/Views/RecordingActionTreeElement.css:
2112         (.tree-outline:focus .item.action.selected:not(.initial-state, .invalid) > .icon):
2113         (body:not(.window-inactive, .window-docked-inactive) .tree-outline:focus .item.action.selected > .titles .parameter.swizzled,):
2114         (.tree-outline:matches(:focus, .force-focus) .item.action.selected:not(.initial-state, .invalid) > .icon): Deleted.
2115         (body:not(.window-inactive, .window-docked-inactive) .tree-outline:matches(:focus, .force-focus) .item.action.selected > .titles .parameter.swizzled,): Deleted.
2116
2117         * UserInterface/Views/ScriptDetailsTimelineView.css:
2118         (.tree-outline:focus .item.selected .alternate-subtitle):
2119         (.tree-outline:matches(:focus, .force-focus) .item.selected .alternate-subtitle): Deleted.
2120
2121         * UserInterface/Views/ShaderProgramTreeElement.css:
2122         (.tree-outline:focus .item.shader-program.selected .status > img):
2123         (.tree-outline:matches(:focus, .force-focus) .item.shader-program.selected .status > img): Deleted.
2124
2125         * UserInterface/Views/ThreadTreeElement.css:
2126         (.tree-outline:focus > .item.thread.selected .status-button.resume):
2127         (.tree-outline:matches(:focus, .force-focus) > .item.thread.selected .status-button.resume): Deleted.
2128
2129         * UserInterface/Views/TimelineRecordBar.css:
2130         (:focus .selected .timeline-record-bar > .segment):
2131         (:focus .selected .timeline-record-bar > .segment.inactive):
2132         (body[dir=ltr] :focus .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)):
2133         (body[dir=rtl] :focus .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)):
2134         (:matches(:focus, .force-focus) .selected .timeline-record-bar > .segment): Deleted.
2135         (:matches(:focus, .force-focus) .selected .timeline-record-bar > .segment.inactive): Deleted.
2136         (body[dir=ltr] :matches(:focus, .force-focus) .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)): Deleted.
2137         (body[dir=rtl] :matches(:focus, .force-focus) .selected .timeline-record-bar.has-inactive-segment > .segment:not(.inactive)): Deleted.
2138
2139         * UserInterface/Views/TreeElementStatusButton.css:
2140         (:focus .item.selected > .status > .status-button):
2141         (:matches(:focus, .force-focus) .item.selected > .status > .status-button): Deleted.
2142
2143         * UserInterface/Views/TreeOutline.css:
2144         (.tree-outline:focus .item.selected .disclosure-button):
2145         (.tree-outline:focus .item.selected.expanded .disclosure-button):
2146         (.tree-outline:focus .item.selected):
2147         (.tree-outline:focus .item.selected .subtitle):
2148         (.tree-outline:not(.large):focus .item.selected .status .indeterminate-progress-spinner):
2149         (.tree-outline:matches(:focus, .force-focus) .item.selected .disclosure-button): Deleted.
2150         (.tree-outline:matches(:focus, .force-focus) .item.selected.expanded .disclosure-button): Deleted.
2151         (.tree-outline:matches(:focus, .force-focus) .item.selected): Deleted.
2152         (.tree-outline:matches(:focus, .force-focus) .item.selected .subtitle): Deleted.
2153         (.tree-outline:not(.large):matches(:focus, .force-focus) .item.selected .status .indeterminate-progress-spinner): Deleted.
2154
2155 2018-10-11  Devin Rousso  <drousso@apple.com>
2156
2157         Web Inspector: detail view is not re-shown after sorting the Network table
2158         https://bugs.webkit.org/show_bug.cgi?id=190330
2159         <rdar://problem/45089607>
2160
2161         Reviewed by Matt Baker.
2162
2163         * UserInterface/Views/NetworkTableContentView.js:
2164         (WI.NetworkTableContentView.prototype._restoreSelectedRow):
2165
2166 2018-10-10  Devin Rousso  <drousso@apple.com>
2167
2168         Web Inspector: create special Network waterfall for media events
2169         https://bugs.webkit.org/show_bug.cgi?id=189773
2170         <rdar://problem/44626605>
2171
2172         Reviewed by Joseph Pecoraro.
2173
2174         * Localizations/en.lproj/localizedStrings.js:
2175         * UserInterface/Main.html:
2176         * UserInterface/Base/Utilities.js:
2177
2178         * UserInterface/Protocol/DOMObserver.js:
2179         (WI.DOMObserver.prototype.didFireEvent): Added.
2180         * UserInterface/Controllers/DOMManager.js:
2181         (WI.DOMManager.prototype.didFireEvent): Added.
2182         * UserInterface/Models/DOMNode.js:
2183         (WI.DOMNode):
2184         (WI.DOMNode.prototype.get domEvents): Added.
2185         (WI.DOMNode.prototype.didFireEvent): Added.
2186         (WI.DOMNode.prototype._addDOMEvent): Added.
2187
2188         * UserInterface/Views/NetworkTableContentView.js:
2189         (WI.NetworkTableContentView):
2190         (WI.NetworkTableContentView.prototype.shown):
2191         (WI.NetworkTableContentView.prototype.hidden):
2192         (WI.NetworkTableContentView.prototype.closed):
2193         (WI.NetworkTableContentView.prototype.reset):
2194         (WI.NetworkTableContentView.prototype.showRepresentedObject):
2195         (WI.NetworkTableContentView.prototype.networkDetailViewClose): Added.
2196         (WI.NetworkTableContentView.prototype.tableSortChanged):
2197         (WI.NetworkTableContentView.prototype.tableSelectionDidChange):
2198         (WI.NetworkTableContentView.prototype._populateNameCell):
2199         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.positionByStartOffset): Added.
2200         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.setWidthForDuration): Added.
2201         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.createDOMEventLine): Added.
2202         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.appendBlock):
2203         (WI.NetworkTableContentView.prototype._populateWaterfallGraph):
2204         (WI.NetworkTableContentView.prototype._processPendingEntries):
2205         (WI.NetworkTableContentView.prototype._rowIndexForRepresentedObject): Added.
2206         (WI.NetworkTableContentView.prototype._updateEntryForResource):
2207         (WI.NetworkTableContentView.prototype._hideDetailView): Added.
2208         (WI.NetworkTableContentView.prototype._showDetailView): Added.
2209         (WI.NetworkTableContentView.prototype._positionDetailView): Added.
2210         (WI.NetworkTableContentView.prototype._resourceTransferSizeDidChange):
2211         (WI.NetworkTableContentView.prototype._tryLinkResourceToDOMNode):
2212         (WI.NetworkTableContentView.prototype._handleNodeDidFireEvent): Added.
2213         (WI.NetworkTableContentView.prototype._updateFilteredEntries):
2214         (WI.NetworkTableContentView.prototype._typeFilterScopeBarSelectionChanged):
2215         (WI.NetworkTableContentView.prototype._urlFilterDidChange):
2216         (WI.NetworkTableContentView.prototype._restoreSelectedRow):
2217         (WI.NetworkTableContentView.prototype._waterfallPopoverContent): Added.
2218         (WI.NetworkTableContentView.prototype._waterfallPopoverContentForResourceEntry): Added.
2219         (WI.NetworkTableContentView.prototype._waterfallPopoverContentForNodeEntry): Added.
2220         (WI.NetworkTableContentView.prototype._handleResourceEntryMousedownWaterfall): Added.
2221         (WI.NetworkTableContentView.prototype._handleNodeEntryMousedownWaterfall): Added.
2222         (WI.NetworkTableContentView.prototype._handleMousedownWaterfall): Added.
2223         (WI.NetworkTableContentView.prototype.networkResourceDetailViewClose): Deleted.
2224         (WI.NetworkTableContentView.prototype._rowIndexForResource): Deleted.
2225         (WI.NetworkTableContentView.prototype._hideResourceDetailView): Deleted.
2226         (WI.NetworkTableContentView.prototype._showResourceDetailView): Deleted.
2227         (WI.NetworkTableContentView.prototype._waterfallPopoverContentForResource): Deleted.
2228         * UserInterface/Views/NetworkTableContentView.css:
2229         (.content-view.network .network-table): Added.
2230         (.network-table :not(.header) .cell.waterfall .waterfall-container > .dom-event): Added.
2231         (.network-table :not(.header) .cell.waterfall .waterfall-container > .dom-activity): Added.
2232         (.network-table :not(.header) .cell.waterfall .waterfall-container > .dom-activity.playing): Added.
2233
2234         * UserInterface/Views/NetworkDOMNodeDetailView.js: Added.
2235         (WI.NetworkDOMNodeDetailView):
2236         (WI.NetworkDOMNodeDetailView.prototype.initialLayout):
2237         (WI.NetworkDOMNodeDetailView.prototype.showContentViewForIdentifier):
2238
2239         * UserInterface/Views/NetworkResourceDetailView.css:
2240         (.content-view.resource-details):
2241         (.network-resource-detail): Deleted.
2242         (.network-resource-detail .navigation-bar): Deleted.
2243         (.network-resource-detail .item.close > .glyph): Deleted.
2244         (.network-resource-detail .item.close > .glyph:hover): Deleted.
2245         (.network-resource-detail .item.close > .glyph:active): Deleted.
2246         (.network .network-resource-detail .navigation-bar .item.radio.button.text-only): Deleted.
2247         (.network .network-resource-detail .navigation-bar .item.radio.button.text-only.selected): Deleted.
2248         (.network-resource-detail > .content-browser): Deleted.
2249         (@media (prefers-dark-interface)): Deleted.
2250         * UserInterface/Views/NetworkResourceDetailView.js:
2251         (WI.NetworkResourceDetailView):
2252         (WI.NetworkResourceDetailView.prototype.shown):
2253         (WI.NetworkResourceDetailView.prototype.headersContentViewGoToRequestData):
2254         (WI.NetworkResourceDetailView.prototype.sizesContentViewGoToHeaders):
2255         (WI.NetworkResourceDetailView.prototype.sizesContentViewGoToRequestBody):
2256         (WI.NetworkResourceDetailView.prototype.sizesContentViewGoToResponseBody):
2257         (WI.NetworkResourceDetailView.prototype.initialLayout):
2258         (WI.NetworkResourceDetailView.prototype.showContentViewForIdentifier):
2259         (WI.NetworkResourceDetailView.prototype.get resource): Deleted.
2260         (WI.NetworkResourceDetailView.prototype.hidden): Deleted.
2261         (WI.NetworkResourceDetailView.prototype.dispose): Deleted.
2262         (WI.NetworkResourceDetailView.prototype.willShowWithCookie): Deleted.
2263         (WI.NetworkResourceDetailView.prototype.initialLayout): Deleted.
2264         (WI.NetworkResourceDetailView.prototype._showPreferredContentView): Deleted.
2265         (WI.NetworkResourceDetailView.prototype._showContentViewForNavigationItem): Deleted.
2266         (WI.NetworkResourceDetailView.prototype._navigationItemSelected): Deleted.
2267         (WI.NetworkResourceDetailView.prototype._handleCloseButton): Deleted.
2268
2269         * UserInterface/Views/NetworkDetailView.js: Added.
2270         (WI.NetworkDetailView):
2271         (WI.NetworkDetailView.prototype.get representedObject):
2272         (WI.NetworkDetailView.prototype.shown):
2273         (WI.NetworkDetailView.prototype.hidden):
2274         (WI.NetworkDetailView.prototype.dispose):
2275         (WI.NetworkDetailView.prototype.willShowWithCookie):
2276         (WI.NetworkDetailView.prototype.initialLayout):
2277         (WI.NetworkDetailView.prototype.createDetailNavigationItem):
2278         (WI.NetworkDetailView.prototype.detailNavigationItemForIdentifier):
2279         (WI.NetworkDetailView.prototype.showContentViewForIdentifier):
2280         (WI.NetworkDetailView.prototype._showPreferredContentView):
2281         (WI.NetworkDetailView.prototype._navigationItemSelected):
2282         (WI.NetworkDetailView.prototype._handleCloseButton):
2283         * UserInterface/Views/NetworkDetailView.css: Added.
2284         (.network-detail):
2285         (.network-detail .navigation-bar):
2286         (.network-detail .item.close > .glyph):
2287         (.network-detail .item.close > .glyph:hover):
2288         (.network-detail .item.close > .glyph:active):
2289         (.network .network-detail .navigation-bar .item.radio.button.text-only):
2290         (.network .network-detail .navigation-bar .item.radio.button.text-only.selected):
2291         (.network-detail > .content-browser):
2292         (@media (prefers-dark-interface)):
2293         Create base class for detail views shown in the Network tab.
2294
2295         * UserInterface/Views/DOMNodeEventsContentView.js: Added.
2296         (WI.DOMNodeEventsContentView):
2297         (WI.DOMNodeEventsContentView.prototype.initialLayout):
2298         (WI.DOMNodeEventsContentView.prototype.closed):
2299         (WI.DOMNodeEventsContentView.prototype._handleDOMNodeDidFireEvent):
2300         * UserInterface/Views/DOMNodeEventsContentView.css: Added.
2301         (.dom-node-details.dom-events):
2302
2303         * UserInterface/Views/DOMEventsBreakdownView.js: Added.
2304         (WI.DOMEventsBreakdownView):
2305         (WI.DOMEventsBreakdownView.prototype.addEvent):
2306         (WI.DOMEventsBreakdownView.prototype.initialLayout):
2307         (WI.DOMEventsBreakdownView.prototype._populateTable.percentOfTotalTime):
2308         (WI.DOMEventsBreakdownView.prototype._populateTable):
2309         * UserInterface/Views/DOMEventsBreakdownView.css: Added.
2310         (.waterfall-popover-content .dom-events-breakdown):
2311         (.dom-events-breakdown):
2312         (.dom-events-breakdown table):
2313         (.dom-events-breakdown tr > :matches(th, td)):
2314         (.dom-events-breakdown tbody > tr):
2315         (.dom-events-breakdown .graph):
2316         (.dom-events-breakdown .graph > :matches(.point, .area)):
2317         (.dom-events-breakdown .graph > .point):
2318         (.dom-events-breakdown .time):
2319
2320         * UserInterface/Views/ResourceTimingBreakdownView.css:
2321         (.resource-timing-breakdown > table > tr.header:not(.total-row) > td): Added.
2322         (.popover.waterfall-popover): Deleted.
2323
2324 2018-10-10  Devin Rousso  <drousso@apple.com>
2325
2326         Web Inspector: REGRESSION(r236853): Uncaught Exception: undefined is not an object (evaluating 'entry.resource')
2327         https://bugs.webkit.org/show_bug.cgi?id=190442
2328
2329         Reviewed by Joseph Pecoraro.
2330
2331         * UserInterface/Views/NetworkTableContentView.js:
2332         (WI.NetworkTableContentView.prototype.reset):
2333         It's unnecessary to deselect rows in the `WI.Table` when we're about to remove them.
2334
2335 2018-10-10  Devin Rousso  <drousso@apple.com>
2336
2337         Web Inspector: REGRESSION: selection in network table is lost when new entries are added
2338         https://bugs.webkit.org/show_bug.cgi?id=190362
2339
2340         Reviewed by Matt Baker.
2341
2342         The `_selectedRows` list is cleared each time `reloadData` is called, meaning that
2343         `WI.Table` expects its "owner" to restore the selection (since it doesn't know how). As a
2344         result, `WI.NetworkTableContentView` needs to call `selectRow` _after_ `reloadData` is
2345         called, not before.
2346
2347         * UserInterface/Views/NetworkTableContentView.js:
2348         (WI.NetworkTableContentView.prototype.tableSortChanged):
2349         (WI.NetworkTableContentView.prototype._populateNameCell):
2350         (WI.NetworkTableContentView.prototype._processPendingEntries):
2351         (WI.NetworkTableContentView.prototype._insertResourceAndReloadTable):
2352         (WI.NetworkTableContentView.prototype._updateSort): Added.
2353         (WI.NetworkTableContentView.prototype._updateFilteredEntries):
2354         (WI.NetworkTableContentView.prototype._reloadTable): Added.
2355         (WI.NetworkTableContentView.prototype._resetFilters):
2356         (WI.NetworkTableContentView.prototype._typeFilterScopeBarSelectionChanged):
2357         (WI.NetworkTableContentView.prototype._handleGroupByDOMNodeCheckedDidChange):
2358         (WI.NetworkTableContentView.prototype._urlFilterDidChange):
2359         (WI.NetworkTableContentView.prototype._updateSortAndFilteredEntries): Deleted.
2360
2361         * UserInterface/Views/Table.js:
2362         (WI.Table.prototype.reloadData):
2363         Ensure that the `_selectedRowIndex` is also reset.
2364
2365 2018-10-10  Devin Rousso  <drousso@apple.com>
2366
2367         Web Inspector: notify the frontend when a canvas has started recording via console.record
2368         https://bugs.webkit.org/show_bug.cgi?id=190306
2369
2370         Reviewed by Brian Burg.
2371
2372         * UserInterface/Protocol/CanvasObserver.js:
2373         (WI.CanvasObserver.prototype.recordingStarted): Added.
2374
2375         * UserInterface/Protocol/CanvasManager.js:
2376         (WI.CanvasManager.prototype.recordingStarted): Added.
2377
2378         * UserInterface/Models/Canvas.js:
2379         (WI.Canvas.prototype.startRecording):
2380         (WI.Canvas.prototype.recordingStarted): Added.
2381         (WI.Canvas.prototype.recordingFinished):
2382
2383 2018-10-10  Devin Rousso  <drousso@apple.com>
2384
2385         Web Inspector: indent all network entries when "Group by Node" is checked
2386         https://bugs.webkit.org/show_bug.cgi?id=190388
2387
2388         Reviewed by Timothy Hatcher.
2389
2390         * UserInterface/Views/NetworkTableContentView.js:
2391         (WI.NetworkTableContentView.prototype._populateNameCell):
2392         (WI.NetworkTableContentView.prototype._handleGroupByDOMNodeCheckedDidChange):
2393
2394         * UserInterface/Views/NetworkTableContentView.css:
2395         (.network-table.grouped .data-container .cell.name): Added.
2396         (.network-table.grouped .data-container .cell:not(.parent).name): Added.
2397         (.network-table.grouped .data-container .cell.child.name): Added.
2398         (.network-table .cell.grouped-by-node.name): Deleted.
2399         (body[dir=ltr] .network-table .cell.grouped-by-node.name): Deleted.
2400         (body[dir=rtl] .network-table .cell.grouped-by-node.name): Deleted.
2401         Apply a padding to all nodes when the `WI.Table` is grouped.
2402
2403 2018-10-09  Devin Rousso  <drousso@apple.com>
2404
2405         Web Inspector: show redirect requests in Network and Timelines tabs
2406         https://bugs.webkit.org/show_bug.cgi?id=150005
2407         <rdar://problem/5378164>
2408
2409         Reviewed by Joseph Pecoraro.
2410
2411         * Localizations/en.lproj/localizedStrings.js:
2412         * UserInterface/Views/Variables.css:
2413         * UserInterface/Main.html:
2414         * UserInterface/Test.html:
2415
2416         * UserInterface/Controllers/NetworkManager.js:
2417         (WI.NetworkManager.prototype.resourceRequestWillBeSent):
2418
2419         * UserInterface/Models/Resource.js:
2420         (WI.Resource):
2421         (WI.Resource.prototype.get redirects): Added.
2422         (WI.Resource.prototype.get lastRedirectReceivedTimestamp):
2423         (WI.Resource.prototype.updateForRedirectResponse):
2424         Save each redirect in an array instead of just remembering the last timestamp.
2425
2426         * UserInterface/Models/ResourceTimingData.js:
2427         (WI.ResourceTimingData):
2428         (WI.ResourceTimingData.fromPayload.offsetToTimestamp):
2429         (WI.ResourceTimingData.fromPayload):
2430         (WI.ResourceTimingData.prototype.get redirectStart): Added.
2431         (WI.ResourceTimingData.prototype.get redirectEnd): Added.
2432         (WI.ResourceTimingData.prototype.get fetchStart): Added.
2433         Add missing fields for `Network.types.ResourceTiming`.
2434
2435         * UserInterface/Models/Redirect.js: Added.
2436         (WI.Redirect):
2437         (WI.Redirect.prototype.get url):
2438         (WI.Redirect.prototype.get requestMethod):
2439         (WI.Redirect.prototype.get requestHeaders):
2440         (WI.Redirect.prototype.get responseStatusCode):
2441         (WI.Redirect.prototype.get responseStatusText):
2442         (WI.Redirect.prototype.get responseHeaders):
2443         (WI.Redirect.prototype.get timestamp):
2444         (WI.Redirect.prototype.get urlComponents):
2445
2446         * UserInterface/Views/ResourceHeadersContentView.js:
2447         (WI.ResourceHeadersContentView):
2448         (WI.ResourceHeadersContentView.prototype.initialLayout):
2449         (WI.ResourceHeadersContentView.prototype.layout):
2450         (WI.ResourceHeadersContentView.prototype._refreshRedirectHeadersSections): Added.
2451         (WI.ResourceHeadersContentView.prototype._resourceRequestHeadersDidChange):
2452         * UserInterface/Views/ResourceHeadersContentView.css:
2453         (body[dir] .resource-headers > section.summary > .details): Added.
2454         (body[dir] .resource-headers > section:matches(.redirect, .headers) > .details): Added.
2455         (.resource-headers .details .key):
2456         (.resource-headers .summary .key):
2457         (body[dir] .resource-headers > section > .details): Deleted.
2458         (body[dir] .resource-headers > section.headers > .details): Deleted.
2459         (.resource-headers .value): Deleted.
2460         Add a request/response header section for each redirect.
2461
2462         * UserInterface/Views/NetworkTableContentView.js:
2463         (WI.NetworkTableContentView.prototype._populateWaterfallGraph.appendBlock):
2464         (WI.NetworkTableContentView.prototype._populateWaterfallGraph):
2465         (WI.NetworkTableContentView.prototype._checkURLFilterAgainstResource):
2466         (WI.NetworkTableContentView.prototype._waterfallPopoverContentForResource):
2467         * UserInterface/Views/NetworkTableContentView.css:
2468         (.waterfall .block.redirect): Added.
2469         (.waterfall .block.queue):
2470         * UserInterface/Views/ResourceTimelineDataGridNode.js:
2471         (WI.ResourceTimelineDataGridNode.prototype._mouseoverRecordBar):
2472         * UserInterface/Views/ResourceTimingBreakdownView.js:
2473         (WI.ResourceTimingBreakdownView.prototype.initialLayout):
2474         Add timeline/waterfall entries for total redirect time.
2475
2476 2018-10-09  Devin Rousso  <drousso@apple.com>
2477
2478         Web Inspector: Canvas Tab: grayed out Record button in navigator is nearly invisible
2479         https://bugs.webkit.org/show_bug.cgi?id=190365
2480         <rdar://problem/45097739>
2481
2482         Reviewed by Brian Burg.
2483
2484         * UserInterface/Views/CanvasSidebarPanel.css:
2485         (@media (prefers-dark-interface)): Added.
2486         (.sidebar > .panel.navigation.canvas > .navigation-bar > .item.record-start-stop.disabled): Added.
2487
2488 2018-10-09  Devin Rousso  <drousso@apple.com>
2489
2490         Web Inspector: REGRESSION: fix canvas test failures after r236952 and r236954
2491         https://bugs.webkit.org/show_bug.cgi?id=190403
2492
2493         Reviewed by Joseph Pecoraro.
2494
2495         * UserInterface/Controllers/CanvasManager.js:
2496         (WI.CanvasManager.prototype._removeCanvas):
2497         Clear the `shaderProgramCollection` when a `WI.Canvas` is removed so that a remove event is
2498         fired for each `WI.ShaderProgram`.
2499
2500 2018-10-08  Justin Fan  <justin_fan@apple.com>
2501
2502         WebGPU: Rename old WebGPU prototype to WebMetal
2503         https://bugs.webkit.org/show_bug.cgi?id=190325
2504         <rdar://problem/44990443>
2505
2506         Reviewed by Dean Jackson.
2507
2508         Rename WebGPU prototype files to WebMetal in preparation for implementing the new (Oct 2018) WebGPU interface.
2509         For WebInspector, add WebMetal to valid enums for canvas types.
2510
2511         * UserInterface/Models/Canvas.js:
2512         (WI.Canvas.fromPayload):
2513         (WI.Canvas.displayNameForContextType):
2514
2515 2018-10-08  Devin Rousso  <drousso@apple.com>
2516
2517         Web Inspector: Dark Mode: canvas recording glyph is black on gray
2518         https://bugs.webkit.org/show_bug.cgi?id=190367
2519         <rdar://problem/45099304>
2520
2521         Reviewed by Joseph Pecoraro.
2522
2523         * UserInterface/Views/CanvasOverviewContentView.css:
2524         (.content-view.canvas-overview .content-view.canvas > footer .view-recording): Added.
2525         (.content-view.canvas-overview .content-view.canvas > footer > .recordings::before): Deleted.
2526
2527 2018-10-08  Devin Rousso  <drousso@apple.com>
2528
2529         Web Inspector: allow multiple canvases to be recorded at the same time
2530         https://bugs.webkit.org/show_bug.cgi?id=190305
2531
2532         Reviewed by Brian Burg.
2533
2534         Moved the logic for maintaining whether a canvas is actively recording from
2535         `WI.CanvasManager` to `WI.Canvas`, meaning that each canvas can now record independently of
2536         every other canvas in the page. If multiple recordings are all finished simultaneously, only
2537         show the first one to be recieved by the frontend.
2538
2539         * UserInterface/Controllers/CanvasManager.js:
2540         (WI.CanvasManager):
2541         (WI.CanvasManager.prototype.recordingProgress):
2542         (WI.CanvasManager.prototype.recordingFinished):
2543         (WI.CanvasManager.prototype.programCreated):
2544         (WI.CanvasManager.prototype.programDeleted):
2545         (WI.CanvasManager.prototype._removeCanvas):
2546         (WI.CanvasManager.prototype._mainResourceDidChange):
2547         (WI.CanvasManager.prototype.get recordingCanvas): Deleted.
2548         (WI.CanvasManager.prototype.startRecording): Deleted.
2549         (WI.CanvasManager.prototype.stopRecording): Deleted.
2550         (WI.CanvasManager.prototype._dispatchShaderProgramRemoved): Deleted.
2551
2552         * UserInterface/Models/Canvas.js:
2553         (WI.Canvas.prototype.get recordingFrameCount): Added.
2554         (WI.Canvas.prototype.get recordingBufferUsed): Added.
2555         (WI.Canvas.prototype.get recordingActive): Added.
2556         (WI.Canvas.prototype.get isRecording): Deleted.
2557         (WI.Canvas.prototype.startRecording): Added.
2558         (WI.Canvas.prototype.stopRecording): Added.
2559         (WI.Canvas.prototype.recordingProgress): Added.
2560         (WI.Canvas.prototype.recordingFinished): Added.
2561
2562         * UserInterface/Views/CanvasTabContentView.js:
2563         (WI.CanvasTabContentView.prototype.attached):
2564         (WI.CanvasTabContentView.prototype.detached):
2565         (WI.CanvasTabContentView.prototype._recordingImportedOrStopped):
2566         (WI.CanvasTabContentView.prototype._handleSpace):
2567         (WI.CanvasTabContentView):
2568
2569         * UserInterface/Views/CanvasOverviewContentView.css:
2570         (.content-view.canvas-overview .content-view.canvas.recording-active): Added.
2571         (.content-view.canvas-overview .content-view.canvas.recording-active > header): Added.
2572         (.content-view.canvas-overview .content-view.canvas.recording-active > header > .titles > .title): Added.
2573         (.content-view.canvas-overview .content-view.canvas.recording-active > header > .titles > .subtitle): Added.
2574         (.content-view.canvas-overview .content-view.canvas.recording-active > header > .navigation-bar > .item): Added.
2575         (.content-view.canvas-overview .content-view.canvas:matches(:hover, .recording-active) > header > .navigation-bar): Added.
2576         (.content-view.canvas-overview .content-view.canvas:not(.recording-active) > header > .navigation-bar > .item.record-start-stop.disabled): Added.
2577         (.content-view.canvas-overview .content-view.canvas:not(.recording-active) > header > .navigation-bar > .item.record-start-stop:not(.disabled):hover): Added.
2578         (.content-view.canvas-overview .content-view.canvas:not(.recording-active) > header > .navigation-bar > .item.record-start-stop:not(.disabled):active): Added.
2579         (.content-view.canvas-overview .content-view.canvas.recording-active > .progress-vie): Added.
2580         (.content-view.canvas-overview .content-view.canvas.recording-active > .preview): Added.
2581         (.content-view.canvas-overview .content-view.canvas.recording-active): Added.
2582         (.content-view.canvas-overview .content-view.canvas.recording-active > header): Added.
2583         (.content-view.canvas-overview .content-view.canvas.recording-active > header > .titles > .subtitle): Added.
2584         (.content-view.canvas-overview .content-view.canvas.is-recording): Deleted.
2585         (.content-view.canvas-overview .content-view.canvas.is-recording > header): Deleted.
2586         (.content-view.canvas-overview .content-view.canvas.is-recording > header > .titles > .title): Deleted.
2587         (.content-view.canvas-overview .content-view.canvas.is-recording > header > .titles > .subtitle): Deleted.
2588         (.content-view.canvas-overview .content-view.canvas.is-recording > header > .navigation-bar > .item): Deleted.
2589         (.content-view.canvas-overview .content-view.canvas:matches(:hover, .is-recording) > header > .navigation-bar): Deleted.
2590         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop.disabled): Deleted.
2591         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop:not(.disabled):hover): Deleted.
2592         (.content-view.canvas-overview .content-view.canvas:not(.is-recording) > header > .navigation-bar > .item.record-start-stop:not(.disabled):active): Deleted.
2593         (.content-view.canvas-overview .content-view.canvas.is-recording > .progress-vie): Deleted.
2594         (.content-view.canvas-overview .content-view.canvas.is-recording > .preview): Deleted.
2595         (.content-view.canvas-overview .content-view.canvas.is-recording): Deleted.
2596         (.content-view.canvas-overview .content-view.canvas.is-recording > header): Deleted.
2597         (.content-view.canvas-overview .content-view.canvas.is-recording > header > .titles > .subtitle): Deleted.
2598
2599         * UserInterface/Views/CanvasContentView.js:
2600         (WI.CanvasContentView.prototype.attached):
2601         (WI.CanvasContentView.prototype.detached):
2602         (WI.CanvasContentView.prototype._toggleRecording):
2603         (WI.CanvasContentView.prototype._recordingProgress):
2604         (WI.CanvasContentView.prototype._recordingStopped):
2605         (WI.CanvasContentView.prototype._shaderProgramAdded):
2606         (WI.CanvasContentView.prototype._shaderProgramRemoved):
2607         (WI.CanvasContentView.prototype._updateRecordNavigationItem):
2608         (WI.CanvasContentView.prototype._updateProgressView):
2609
2610         * UserInterface/Views/CanvasSidebarPanel.js:
2611         (WI.CanvasSidebarPanel):
2612         (WI.CanvasSidebarPanel.prototype.set canvas):
2613         (WI.CanvasSidebarPanel.prototype._toggleRecording):
2614         (WI.CanvasSidebarPanel.prototype._updateRecordNavigationItem):
2615
2616         * UserInterface/Views/CanvasTreeElement.js:
2617         (WI.CanvasTreeElement):
2618         (WI.CanvasTreeElement.prototype._updateStatus):
2619
2620 2018-10-08  Devin Rousso  <drousso@apple.com>
2621
2622         Web Inspector: replace Range.svg icon
2623         https://bugs.webkit.org/show_bug.cgi?id=190372
2624
2625         Reviewed by Joseph Pecoraro.
2626
2627         * UserInterface/Images/Range.svg:
2628         * UserInterface/Images/RangeLarge.svg: Added.
2629
2630         * UserInterface/Models/Resource.js:
2631         (WI.Resource.classNameForResource): Added.
2632         Create a static function for specializing the `className` of `WI.Resource` objects.
2633
2634         * UserInterface/Views/NetworkTableContentView.js:
2635         (WI.NetworkTableContentView.prototype._populateNameCell):
2636
2637         * UserInterface/Views/ResourceTreeElement.js:
2638         (WI.ResourceTreeElement):
2639
2640         * UserInterface/Views/ResourceIcons.css:
2641         (.resource-icon.resource-type-ping .icon, .resource-icon.resource-type-beacon .icon, .large .resource-icon.resource-type-ping .icon, .large .resource-icon.resource-type-beacon .icon):
2642         (.resource-icon.resource-type-range .icon):
2643         (.large .resource-icon.resource-type-range .icon): Added.
2644         Drive-by: added `.large` versions of `ping` and `beacon` icons for the
2645         `WI.OpenResourceDialog` elements.
2646
2647 2018-10-08  Devin Rousso  <drousso@apple.com>
2648
2649         Web Inspector: group media network entries by the node that triggered the request
2650         https://bugs.webkit.org/show_bug.cgi?id=189606
2651         <rdar://problem/44438527>
2652
2653         Reviewed by Brian Burg.
2654
2655         Introduces a `WI.NavigationItem` for changing whether network entries are grouped by the
2656         node that initiated the load (if applicable). When grouped by node, a tree-like layout of
2657         the table cells (including expand/collapse) is used for resources that share the same
2658         initiator node. The values for the node's cell are based on it's initated resources.
2659
2660         * Localizations/en.lproj/localizedStrings.js:
2661         * UserInterface/Base/Setting.js:
2662
2663         * UserInterface/Controllers/DOMManager.js:
2664         (WI.DOMManager):
2665         (WI.DOMManager.prototype._mainResourceDidChange): Added.
2666         Whenever the frame navigates, re-request the document so that `NetworkAgent` is able to send
2667         valid `nodeId` for each request's `initiatorNode`. This means that the document should
2668         always be available.
2669
2670         * UserInterface/Views/NetworkTableContentView.js:
2671         (WI.NetworkTableContentView):
2672         (WI.NetworkTableContentView.prototype.get filterNavigationItems):
2673         (WI.NetworkTableContentView.prototype.closed):
2674         (WI.NetworkTableContentView.prototype.reset):
2675         (WI.NetworkTableContentView.prototype.tableSortChanged):
2676         (WI.NetworkTableContentView.prototype.tableSelectedRowChanged):
2677         (WI.NetworkTableContentView.prototype.tablePopulateCell):
2678         (WI.NetworkTableContentView.prototype._populateNameCell.createIconElement): Added.
2679         (WI.NetworkTableContentView.prototype._populateNameCell):
2680         (WI.NetworkTableContentView.prototype._populateDomainCell.createIconAndText): Added.
2681         (WI.NetworkTableContentView.prototype._populateDomainCell):
2682         (WI.NetworkTableContentView.prototype._populateInitiatorCell):
2683         (WI.NetworkTableContentView.prototype._populateTransferSizeCell):
2684         (WI.NetworkTableContentView.prototype._generateSortComparator):
2685         (WI.NetworkTableContentView.prototype._processPendingEntries):
2686         (WI.NetworkTableContentView.prototype._updateEntryForResource.updateExistingEntry): Added.
2687         (WI.NetworkTableContentView.prototype._updateEntryForResource):
2688         (WI.NetworkTableContentView.prototype._insertResourceAndReloadTable):
2689         (WI.NetworkTableContentView.prototype._entryForDOMNode): Added.
2690         (WI.NetworkTableContentView.prototype._tryLinkResourceToDOMNode): Added.
2691         (WI.NetworkTableContentView.prototype._uniqueValuesForDOMNodeEntry): Added.
2692         (WI.NetworkTableContentView.prototype._updateFilteredEntries):
2693         (WI.NetworkTableContentView.prototype._handleGroupByDOMNodeCheckedDidChange): Added.
2694         * UserInterface/Views/NetworkTableContentView.css:
2695         (.network-table .cell.dom-node.name .icon): Added.
2696         (.network-table .cell.dom-node.name .disclosure): Added.
2697         (body[dir=rtl] .network-table .cell.dom-node.name .disclosure): Added.
2698         (.network-table:focus li.selected .cell.dom-node.name .disclosure): Added.
2699         (.network-table .cell.dom-node.name .disclosure.expanded): Added.
2700         (.network-table:focus li.selected .cell.node.name .disclosure.expanded): Added.
2701         (.network-table .cell.grouped-by-node.name): Added.
2702         (body[dir=ltr] .network-table .cell.grouped-by-node.name): Added.
2703         (body[dir=rtl] .network-table .cell.grouped-by-node.name): Added.
2704         (.network-table li:not(.selected) .cell:matches(.cache-type, .multiple)): Added.
2705         (.network-table li.selected .cell.domain > .lock): Added.
2706         (.network-table .cache-type): Deleted.
2707         When two resources are added that share the same `initiatorNode`, insert a node entry into
2708         the `WI.Table` before the first resource entry for that node (based on the current sort).
2709         This node entry is added after the resource entries are filtered, so they won't appear in
2710         the default entries list.
2711
2712         * UserInterface/Models/Resource.js:
2713         (WI.Resource):
2714         (WI.Resource.prototype.initiatorNode): Added.
2715         (WI.Resource.prototype.requestedByteRange): Added.
2716         * UserInterface/Controllers/NetworkManager.js:
2717         (WI.NetworkManager.prototype.resourceRequestWillBeSent):
2718         (WI.NetworkManager.prototype.resourceRequestWasServedFromMemoryCache):
2719         (WI.NetworkManager.prototype._initiatorNodeFromPayload): Added.
2720
2721         * UserInterface/Images/Range.svg: Added.
2722         * UserInterface/Views/ResourceIcons.css:
2723         (.resource-icon.resource-type-range .icon): Added.
2724
2725 2018-10-08  Devin Rousso  <drousso@apple.com>
2726
2727         Web Inspector: clicking initiator link in Network Tab table doesn't automatically switch to Preview section
2728         https://bugs.webkit.org/show_bug.cgi?id=190286
2729
2730         Reviewed by Brian Burg.
2731
2732         * UserInterface/Views/NetworkResourceDetailView.js:
2733         (WI.NetworkResourceDetailView.prototype.shown):
2734         (WI.NetworkResourceDetailView.prototype._showContentViewForNavigationItem):
2735
2736 2018-10-08  Devin Rousso  <drousso@apple.com>
2737
2738         Web Inspector: be more specific as to what types of WI.Collection are allowed for the Resources tab
2739         https://bugs.webkit.org/show_bug.cgi?id=190304
2740
2741         Reviewed by Brian Burg.
2742
2743         * UserInterface/Base/Main.js:
2744         (WI.tabContentViewClassForRepresentedObject):
2745         * UserInterface/Views/ResourcesTabContentView.js:
2746         (WI.ResourcesTabContentView.prototype.canShowRepresentedObject):
2747
2748 2018-10-08  Devin Rousso  <drousso@apple.com>
2749
2750         Web Inspector: Open Resource Dialog should show path to resource (to disambiguate resources with same name)
2751         https://bugs.webkit.org/show_bug.cgi?id=178153
2752         <rdar://problem/34925686>
2753
2754         Reviewed by Brian Burg.
2755
2756         * UserInterface/Views/OpenResourceDialog.js:
2757         (WI.OpenResourceDialog.prototype._populateResourceTreeOutline):
2758         * UserInterface/Views/OpenResourceDialog.css:
2759         (.open-resource-dialog .tree-outline.large .item .titles[data-path]): Added.
2760         (.open-resource-dialog .tree-outline.large .item .titles[data-path]::after): Added.
2761         (.open-resource-dialog .tree-outline.large .item .titles .title): Added.
2762         (.open-resource-dialog .tree-outline.large .item .titles .subtitle): Added.
2763         (.open-resource-dialog .tree-outline.large .item .titles): Deleted.
2764
2765 2018-10-05  Devin Rousso  <drousso@apple.com>
2766
2767         Web Inspector: add WebVTT MIME/file type mappings to the frontend
2768         https://bugs.webkit.org/show_bug.cgi?id=190288
2769
2770         Reviewed by Brian Burg.
2771
2772         * UserInterface/Base/MIMETypeUtilities.js:
2773         (WI.mimeTypeForFileExtension):
2774         (WI.fileExtensionForMIMEType):
2775
2776         * UserInterface/Views/NetworkTableContentView.js:
2777         (WI.NetworkTableContentView.displayNameForResource):
2778         Also attempt to use the mime-type-to-extension when the `WI.Resource` is of type `Other`.
2779
2780 2018-10-05  Devin Rousso  <drousso@apple.com>
2781
2782         Web Inspector: refactor constructor of WI.Resource
2783         https://bugs.webkit.org/show_bug.cgi?id=190318
2784
2785         Reviewed by Joseph Pecoraro.
2786
2787         Reworked constructor of `WI.Resource` to use an optional object for any non-essential arguments.
2788
2789         Drive-by: moved some simple getters to the top of the class to save space.
2790
2791         * UserInterface/Models/Resource.js:
2792         (WI.Resource):
2793
2794         * UserInterface/Models/SourceMapResource.js:
2795         (WI.SourceMapResource):
2796
2797         * UserInterface/Models/WebSocketResource.js:
2798         (WI.WebSocketResource):
2799
2800         * UserInterface/Controllers/NetworkManager.js:
2801         (WI.NetworkManager.prototype.frameDidNavigate):
2802         (WI.NetworkManager.prototype.resourceRequestWillBeSent):
2803         (WI.NetworkManager.prototype.webSocketWillSendHandshakeRequest):
2804         (WI.NetworkManager.prototype.resourceRequestWasServedFromMemoryCache):
2805         (WI.NetworkManager.prototype.resourceRequestDidReceiveResponse):
2806         (WI.NetworkManager.prototype._addNewResourceToFrameOrTarget):
2807         (WI.NetworkManager.prototype._createFrame):
2808         (WI.NetworkManager.prototype._createResource):
2809
2810 2018-10-05  Devin Rousso  <drousso@apple.com>
2811
2812         Web Inspector: use iframe's name attribute for FrameTreeElement
2813         https://bugs.webkit.org/show_bug.cgi?id=190275
2814
2815         Reviewed by Joseph Pecoraro.
2816
2817         * UserInterface/Views/FrameTreeElement.js:
2818         (WI.FrameTreeElement.prototype.get mainTitleText): Added.
2819
2820         * UserInterface/Views/ResourceTreeElement.js:
2821         (WI.ResourceTreeElement.prototype.get mainTitleText): Added.
2822         (WI.ResourceTreeElement.prototype._updateTitles):
2823         Provide a way for subclasses to override what is used for the `mainTitle`.
2824
2825         * UserInterface/Views/QuickConsole.js:
2826         (WI.QuickConsole.prototype._createExecutionContextPathComponentFromFrame):
2827         Update the execution context picker to match what `WI.FrameTreeElement`s show.
2828
2829 2018-10-04  Matt Baker  <mattbaker@apple.com>
2830
2831         Web Inspector: REGRESSION (r236766): Storage tab no longer updates after main frame navigation
2832         https://bugs.webkit.org/show_bug.cgi?id=190298
2833
2834         Reviewed by Joseph Pecoraro.
2835
2836         Handle Cleared events from storage managers separately, so that successive
2837         events during page load does not cause the Storage tab to destroy newly
2838         created tree elements.
2839
2840         * UserInterface/Views/StorageSidebarPanel.js:
2841         (WI.StorageSidebarPanel):
2842         (WI.StorageSidebarPanel.prototype._closeContentViewForTreeElement):
2843         (WI.StorageSidebarPanel.prototype._domStorageCleared):
2844         (WI.StorageSidebarPanel.prototype._applicationCacheCleared):
2845         (WI.StorageSidebarPanel.prototype._indexedDatabaseCleared):
2846         (WI.StorageSidebarPanel.prototype._databaseCleared):
2847         (WI.StorageSidebarPanel.prototype._storageCleared): Deleted.
2848
2849 2018-10-04  Matt Baker  <mattbaker@apple.com>
2850
2851         Web Inspector: Table should support multiple selection and Cmd-click behavior
2852         https://bugs.webkit.org/show_bug.cgi?id=189705
2853         <rdar://problem/44571170>
2854
2855         Reviewed by Devin Rousso.
2856
2857         Add multiple row selection to Table, with new methods for programmatic
2858         selection (deselectRow, deselectAll), and Command-click support for
2859         selecting/deselecting Table rows.
2860
2861         * UserInterface/Base/IndexSet.js: Added.
2862         (WI.IndexSet):
2863         (WI.IndexSet.prototype.get size):
2864         (WI.IndexSet.prototype.get firstIndex):
2865         (WI.IndexSet.prototype.get lastIndex):
2866         (WI.IndexSet.prototype.add):
2867         (WI.IndexSet.prototype.delete):
2868         (WI.IndexSet.prototype.has):
2869         (WI.IndexSet.prototype.clear):
2870         (WI.IndexSet.prototype.indexGreaterThan):
2871         (WI.IndexSet.prototype.indexLessThan):
2872         (WI.IndexSet.prototype.Symbol.iterator):
2873         (WI.IndexSet.prototype._indexClosestTo):
2874         (WI.IndexSet.prototype._validateIndex):
2875         Helper container for managing an ordered sequence of unique positive
2876         integers, with set semantics, backed by a sorted array. Used by Table,
2877         and eventually by TreeOutline.
2878
2879         * UserInterface/Main.html:
2880         * UserInterface/Test.html:
2881         * UserInterface/Test/Test.js:
2882         New files and stubs to make Table layout tests possible.
2883
2884         * UserInterface/Views/NetworkTableContentView.js:
2885         (WI.NetworkTableContentView.prototype.reset):
2886         (WI.NetworkTableContentView.prototype.showRepresentedObject):
2887         (WI.NetworkTableContentView.prototype.networkResourceDetailViewClose):
2888         (WI.NetworkTableContentView.prototype.tableSelectionDidChange):
2889         (WI.NetworkTableContentView.prototype._restoreSelectedRow):
2890         (WI.NetworkTableContentView.prototype.tableSelectedRowChanged): Deleted.
2891         Replace uses of `clearSelectedRow` with `deselectAll`, and updated
2892         selection changed delegate.
2893
2894         * UserInterface/Views/Table.css:
2895         (.table > .data-container > .data-list > li):
2896         (.table > .data-container > .data-list > li.selected):
2897         (@media (prefers-dark-interface)):
2898         (.table,): Deleted.
2899         Removed styles that are no longer needed after https://webkit.org/b/189766,
2900         and provide a visual separation between adjacent selected rows.
2901
2902         * UserInterface/Views/Table.js:
2903         (WI.Table):
2904         (WI.Table.prototype.get selectedRows):
2905         (WI.Table.prototype.get allowsMultipleSelection):
2906         (WI.Table.prototype.set allowsMultipleSelection):
2907         (WI.Table.prototype.reloadData):
2908         (WI.Table.prototype.selectRow):
2909         (WI.Table.prototype.deselectRow):
2910         (WI.Table.prototype.deselectAll):
2911         (WI.Table.prototype._getOrCreateRow):
2912         (WI.Table.prototype._handleMouseDown):
2913         (WI.Table.prototype._deselectAllAndSelect):
2914         (WI.Table.prototype._isRowSelected):
2915         (WI.Table.prototype._notifySelectionDidChange):
2916         (WI.Table.prototype.clearSelectedRow): Deleted.
2917         Table now tracks selected rows using an IndexSet. selectRow accepts an
2918         optional parameter, `extendSelection`, for adding rows to the selection.
2919         _selectedRowIndex is now used to track the most recently selected row.
2920         This will be the only selected row unless multiple selection is enabled,
2921         in which case it is the row that has the "focus", for purposes of selecting
2922         a new row using the up or down arrow keys.
2923
2924 2018-10-04  Devin Rousso  <drousso@apple.com>
2925
2926         Web Inspector: REGRESSION(r236540): Uncaught Exception: TypeError: pauseReasonBreakpointTreeElement.removeStatusImage is not a function.
2927         https://bugs.webkit.org/show_bug.cgi?id=190230
2928
2929         Reviewed by Matt Baker.
2930
2931         * UserInterface/Views/DebuggerSidebarPanel.js:
2932         (WI.DebuggerSidebarPanel._removeBreakpoint):
2933         Leverage existing `status` getter/setter for creating/removing the breakpoint icon element.
2934
2935         * UserInterface/Views/BreakpointTreeElement.js:
2936         (WI.BreakpointTreeElement):
2937         (WI.BreakpointTreeElement.prototype.populateContextMenu):
2938         (WI.BreakpointTreeElement.prototype._updateStatus):
2939         (WI.BreakpointTreeElement.prototype.removeStatusImage): Deleted.
2940
2941         * UserInterface/Views/DOMBreakpointTreeElement.js:
2942         (WI.DOMBreakpointTreeElement):
2943         (WI.DOMBreakpointTreeElement.prototype.onattach):
2944         (WI.DOMBreakpointTreeElement.prototype.ondetach):
2945         (WI.DOMBreakpointTreeElement.prototype._updateStatus):
2946
2947         * UserInterface/Views/EventBreakpointTreeElement.js:
2948         (WI.EventBreakpointTreeElement):
2949         (WI.EventBreakpointTreeElement.prototype.onattach):
2950         (WI.EventBreakpointTreeElement.prototype.ondetach):
2951         (WI.EventBreakpointTreeElement.prototype._updateStatus):
2952
2953         * UserInterface/Views/XHRBreakpointTreeElement.js:
2954         (WI.XHRBreakpointTreeElement):
2955         (WI.XHRBreakpointTreeElement.prototype.onattach):
2956         (WI.XHRBreakpointTreeElement.prototype.ondetach):
2957         (WI.XHRBreakpointTreeElement.prototype._updateStatus):
2958
2959 2018-10-04  Dan Bernstein  <mitz@apple.com>
2960
2961         WebInspectorUI part of [Xcode] Update some build settings as recommended by Xcode 10
2962         https://bugs.webkit.org/show_bug.cgi?id=190250
2963
2964         Reviewed by Andy Estes.
2965
2966         * Configurations/Base.xcconfig: Enabled CLANG_WARN_COMMA, CLANG_WARN_INFINITE_RECURSION,
2967           CLANG_WARN_SUSPICIOUS_MOVE, CLANG_WARN_DEPRECATED_OBJC_IMPLEMENTATIONS, and
2968           CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF.
2969
2970         * WebInspectorUI.xcodeproj/project.pbxproj: Let Xcode update LastUpgradeCheck.
2971
2972 2018-10-04  Devin Rousso  <drousso@apple.com>
2973
2974         Web Inspector: merge ProbeManager into DebuggerManager
2975         https://bugs.webkit.org/show_bug.cgi?id=190225
2976
2977         Reviewed by Joseph Pecoraro.
2978
2979         * UserInterface/Main.html:
2980         * UserInterface/Base/Main.js:
2981         (WI.loaded):
2982         * UserInterface/Test.html:
2983         * UserInterface/Test/Test.js:
2984         (WI.loaded):
2985
2986         * UserInterface/Controllers/DebuggerManager.js:
2987         (WI.DebuggerManager.prototype.get probeSets): Added.
2988         (WI.DebuggerManager.prototype.probeForIdentifier): Added.
2989         (WI.DebuggerManager.prototype.addBreakpoint):
2990         (WI.DebuggerManager.prototype.removeBreakpoint):
2991         (WI.DebuggerManager.prototype.didSampleProbe): Added.
2992         (WI.DebuggerManager.prototype._handleBreakpointActionsDidChange): Added.
2993         (WI.DebuggerManager.prototype._addProbesForBreakpoint): Added.
2994         (WI.DebuggerManager.prototype._removeProbesForBreakpoint): Added.
2995         (WI.DebuggerManager.prototype._updateProbesForBreakpoint): Added.
2996         (WI.DebuggerManager.prototype._probeSetForBreakpoint): Added.
2997         * UserInterface/Controllers/ProbeManager.js: Removed.
2998
2999         * UserInterface/Protocol/DebuggerObserver.js:
3000         (WI.DebuggerObserver.prototype.didSampleProbe):
3001
3002         * UserInterface/Controllers/TimelineManager.js:
3003         (WI.TimelineManager.prototype._processRecord):
3004
3005         * UserInterface/Views/BreakpointTreeElement.js:
3006         (WI.BreakpointTreeElement.prototype.onattach):
3007
3008         * UserInterface/Views/ProbeDetailsSidebarPanel.js:
3009         (WI.ProbeDetailsSidebarPanel.prototype.closed):
3010         (WI.ProbeDetailsSidebarPanel.prototype.initialLayout):
3011
3012         * UserInterface/Views/TextResourceContentView.js:
3013         (WI.TextResourceContentView):
3014         (WI.TextResourceContentView.prototype.get supplementalRepresentedObjects):
3015         (WI.TextResourceContentView.prototype.closed):
3016
3017 2018-10-04  Devin Rousso  <drousso@apple.com>
3018
3019         Web Inspector: some files not listed in OpenResourceDialog
3020         https://bugs.webkit.org/show_bug.cgi?id=190272
3021
3022         Reviewed by Joseph Pecoraro.
3023
3024         * UserInterface/Controllers/ResourceQueryController.js:
3025         (WI.ResourceQueryController.prototype._findQueryMatches):
3026         Allow the `searchIndex` to go past the end of the `searchString` to allow for backtracking
3027         if the last character of `searchString` is not found in `query`.
3028
3029 2018-10-04  Devin Rousso  <drousso@apple.com>
3030
3031         Web Inspector: REGRESSION(r236783): Uncaught Exception: Can't find variable: sourceMapURL
3032         https://bugs.webkit.org/show_bug.cgi?id=190276
3033
3034         Reviewed by Joseph Pecoraro.
3035
3036         * UserInterface/Controllers/NetworkManager.js:
3037         (WI.NetworkManager.prototype._sourceMapLoadAndParseFailed):
3038
3039 2018-10-02  Devin Rousso  <drousso@apple.com>
3040
3041         Web Inspector: merge SourceMapManager into NetworkManager
3042         https://bugs.webkit.org/show_bug.cgi?id=190224
3043
3044         Reviewed by Joseph Pecoraro.
3045
3046         * UserInterface/Main.html:
3047         * UserInterface/Base/Main.js:
3048         (WI.loaded):
3049         * UserInterface/Test.html:
3050         * UserInterface/Test/Test.js:
3051         (WI.loaded):
3052
3053         * UserInterface/Controllers/NetworkManager.js:
3054         (WI.NetworkManager):
3055         (WI.NetworkManager.prototype.downloadSourceMap): Added.
3056         (WI.NetworkManager.prototype.resourceRequestWasServedFromMemoryCache):
3057         (WI.NetworkManager.prototype.resourceRequestDidFinishLoading):
3058         (WI.NetworkManager.prototype._createResource):
3059         (WI.NetworkManager.prototype._loadAndParseSourceMap): Added.
3060         (WI.NetworkManager.prototype._sourceMapLoadAndParseFailed): Added.
3061         (WI.NetworkManager.prototype._sourceMapLoadAndParseSucceeded): Added.
3062         (WI.NetworkManager.prototype._handleFrameMainResourceDidChange): Added.
3063         * UserInterface/Controllers/SourceMapManager.js: Removed.
3064
3065         * UserInterface/Models/Script.js:
3066         (WI.Script):
3067
3068         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj:
3069         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj.filters:
3070
3071 2018-10-02  Nikita Vasilyev  <nvasilyev@apple.com>
3072
3073         Web Inspector: Styles: start editing property name/value on mouseup instead of mousedown
3074         https://bugs.webkit.org/show_bug.cgi?id=190114
3075         <rdar://problem/44891030>
3076
3077         Reviewed by Matt Baker.
3078
3079         This change only affects the experimental multiple properties selection.
3080
3081         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
3082         (WI.SpreadsheetCSSStyleDeclarationSection):
3083         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
3084         (.multiple-properties-selection .spreadsheet-style-declaration-editor :matches(.name, .value):not(.editing)):
3085         Without this code, the focus outline flickers on click (after mousedown but before mouseup event).
3086
3087         * UserInterface/Views/SpreadsheetTextField.js:
3088         (WI.SpreadsheetTextField):
3089         (WI.SpreadsheetTextField.prototype._handleMouseUp):
3090
3091 2018-10-02  Devin Rousso  <drousso@apple.com>
3092
3093         Web Inspector: prevent layer events from firing until the layer information is re-requested
3094         https://bugs.webkit.org/show_bug.cgi?id=190159
3095
3096         Reviewed by Joseph Pecoraro.
3097
3098         * UserInterface/Controllers/LayerTreeManager.js:
3099         (WI.LayerTreeManager):
3100         (WI.LayerTreeManager.prototype.get supported):
3101         Remove `supported` member variable in favor of re-evaluating its value.
3102
3103         * UserInterface/Protocol/LayerTreeObserver.js:
3104         (WI.LayerTreeObserver.prototype.layerTreeDidChange):
3105
3106 2018-10-02  Devin Rousso  <drousso@apple.com>
3107
3108         Web Inspector: REGRESSION(r236766): WI.IssueManager no longer exists
3109         https://bugs.webkit.org/show_bug.cgi?id=190226
3110
3111         Reviewed by Joseph Pecoraro.
3112
3113         * UserInterface/Controllers/ConsoleManager.js:
3114         (WI.ConsoleManager.prototype.issuesForSourceCode):
3115
3116 2018-10-02  Devin Rousso  <drousso@apple.com>
3117
3118         Web Inspector: rename frontend managers to be more consistent with backend agents
3119         https://bugs.webkit.org/show_bug.cgi?id=190160
3120
3121         Reviewed by Joseph Pecoraro.
3122
3123         * UserInterface/Test.html:
3124         * UserInterface/Test/Test.js:
3125         * UserInterface/Main.html:
3126         * UserInterface/Base/Main.js:
3127         * UserInterface/Base/DOMUtilities.js:
3128         * UserInterface/Controllers/ApplicationCacheManager.js:
3129         * UserInterface/Controllers/CSSManager.js: Renamed from Source/WebInspectorUI/UserInterface/Controllers/CSSStyleManager.js.
3130         * UserInterface/Controllers/ConsoleManager.js: Renamed from Source/WebInspectorUI/UserInterface/Controllers/LogManager.js.
3131         * UserInterface/Controllers/DOMDebuggerManager.js:
3132         * UserInterface/Controllers/DOMManager.js: Renamed from Source/WebInspectorUI/UserInterface/Controllers/DOMTreeManager.js.
3133         * UserInterface/Controllers/DOMStorageManager.js: Renamed from Source/WebInspectorUI/UserInterface/Controllers/StorageManager.js.
3134         * UserInterface/Controllers/DashboardManager.js: Removed.
3135         * UserInterface/Controllers/DatabaseManager.js: Copied from Source/WebInspectorUI/UserInterface/Controllers/DOMStorageManager.js.
3136         * UserInterface/Controllers/HARBuilder.js:
3137         * UserInterface/Controllers/IndexedDBManager.js: Copied from Source/WebInspectorUI/UserInterface/Controllers/DOMStorageManager.js.
3138         * UserInterface/Controllers/IssueManager.js: Removed.
3139         * UserInterface/Controllers/JavaScriptLogViewController.js:
3140         * UserInterface/Controllers/NetworkManager.js: Renamed from Source/WebInspectorUI/UserInterface/Controllers/FrameResourceManager.js.
3141         * UserInterface/Controllers/SourceMapManager.js:
3142         * UserInterface/Controllers/TimelineManager.js:
3143         * UserInterface/Debug/UncaughtExceptionReporter.js:
3144         * UserInterface/Models/CSSProperty.js:
3145         * UserInterface/Models/CSSSelector.js:
3146         * UserInterface/Models/CallFrame.js:
3147         * UserInterface/Models/Canvas.js:
3148         * UserInterface/Models/ConsoleMessage.js:
3149         * UserInterface/Models/DOMBreakpoint.js:
3150         * UserInterface/Models/DOMNode.js:
3151         * UserInterface/Models/DOMNodeStyles.js:
3152         * UserInterface/Models/DOMTree.js:
3153         * UserInterface/Models/DefaultDashboard.js:
3154         * UserInterface/Models/Script.js:
3155         * UserInterface/Models/ScriptTimelineRecord.js:
3156         * UserInterface/Models/SourceMapResource.js:
3157         * UserInterface/Models/TimelineRecording.js:
3158         * UserInterface/Protocol/CSSObserver.js:
3159         * UserInterface/Protocol/ConsoleObserver.js:
3160         * UserInterface/Protocol/DOMObserver.js:
3161         * UserInterface/Protocol/DOMStorageObserver.js:
3162         * UserInterface/Protocol/DatabaseObserver.js:
3163         * UserInterface/Protocol/InspectorFrontendAPI.js:
3164         * UserInterface/Protocol/InspectorObserver.js:
3165         * UserInterface/Protocol/MainTarget.js:
3166         * UserInterface/Protocol/NetworkObserver.js:
3167         * UserInterface/Protocol/PageObserver.js:
3168         * UserInterface/Protocol/RemoteObject.js:
3169         * UserInterface/Protocol/RuntimeObserver.js:
3170         * UserInterface/Protocol/WorkerTarget.js:
3171         * UserInterface/Views/BoxModelDetailsSectionRow.js:
3172         * UserInterface/Views/CanvasOverviewContentView.js:
3173         * UserInterface/Views/CanvasTreeElement.js:
3174         * UserInterface/Views/ContentView.js:
3175         * UserInterface/Views/ContextMenuUtilities.js:
3176         * UserInterface/Views/CookieStorageContentView.js:
3177         * UserInterface/Views/DOMDetailsSidebarPanel.js:
3178         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
3179         * UserInterface/Views/DOMNodeTreeElement.js:
3180         * UserInterface/Views/DOMTreeContentView.js:
3181         * UserInterface/Views/DOMTreeDataGrid.js:
3182         * UserInterface/Views/DOMTreeElement.js:
3183         * UserInterface/Views/DOMTreeElementPathComponent.js:
3184         * UserInterface/Views/DOMTreeOutline.js:
3185         * UserInterface/Views/DOMTreeUpdater.js:
3186         * UserInterface/Views/DebuggerSidebarPanel.js:
3187         * UserInterface/Views/ElementsTabContentView.js:
3188         * UserInterface/Views/EventBreakpointPopover.js:
3189         * UserInterface/Views/EventBreakpointTreeElement.js:
3190         * UserInterface/Views/EventListenerSectionGroup.js:
3191         * UserInterface/Views/FormattedValue.js:
3192         * UserInterface/Views/FrameTreeElement.js:
3193         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.js:
3194         * UserInterface/Views/IndexedDatabaseObjectStoreContentView.js:
3195         * UserInterface/Views/LayerDetailsSidebarPanel.js:
3196         * UserInterface/Views/LayerTreeDataGridNode.js:
3197         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
3198         * UserInterface/Views/Layers3DContentView.js:
3199         * UserInterface/Views/LogContentView.js:
3200         * UserInterface/Views/NetworkTableContentView.js:
3201         * UserInterface/Views/ObjectTreeBaseTreeElement.js:
3202         * UserInterface/Views/ObjectTreeView.js:
3203         * UserInterface/Views/OpenResourceDialog.js:
3204         * UserInterface/Views/ResourceSidebarPanel.js:
3205         * UserInterface/Views/SearchSidebarPanel.js:
3206         * UserInterface/Views/SettingsTabContentView.js:
3207         * UserInterface/Views/SourceCodeTextEditor.js:
3208         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
3209         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
3210         * UserInterface/Views/StorageSidebarPanel.js:
3211         * UserInterface/Views/StyleDetailsPanel.js:
3212         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj:
3213         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj.filters:
3214
3215 2018-10-02  Devin Rousso  <drousso@apple.com>
3216
3217         Web Inspector: Canvas: replace constant numbers with their associated name on WebGL contexts
3218         https://bugs.webkit.org/show_bug.cgi?id=190026
3219
3220         Reviewed by Joseph Pecoraro.
3221
3222         * UserInterface/Models/RecordingAction.js:
3223         (WI.RecordingAction.constantNameForParameter): Added.
3224         (WI.RecordingAction.prototype.getColorParameters):
3225         (WI.RecordingAction.prototype.getImageParameters):
3226         Drive-by: add additional swatches to color/image arguments for WebGL actions.
3227
3228         * UserInterface/Views/CanvasSidebarPanel.js:
3229         (WI.CanvasSidebarPanel.prototype._treeOutlineSelectionDidChange):
3230         Drive-by: ensure that the `WI.RecordingContentView` is showing before applying the action.
3231
3232         * UserInterface/Views/RecordingActionTreeElement.js:
3233         (WI.RecordingActionTreeElement._generateDOM.createParameterElement):
3234         (WI.RecordingActionTreeElement._generateDOM):
3235         * UserInterface/Views/RecordingActionTreeElement.css:
3236         (.item.action > .titles .parameter.constant): Added.
3237
3238 2018-10-01  Joseph Pecoraro  <pecoraro@apple.com>
3239
3240         Web Inspector: Fix a typo for execution context identifier
3241         https://bugs.webkit.org/show_bug.cgi?id=190185
3242
3243         Reviewed by Matt Baker.
3244
3245         * UserInterface/Protocol/MainTarget.js:
3246         (WI.MainTarget):
3247         * UserInterface/Protocol/WorkerTarget.js:
3248         (WI.WorkerTarget):
3249
3250 2018-10-01  Devin Rousso  <drousso@apple.com>
3251
3252         Web Inspector: remove analyzer manager
3253         https://bugs.webkit.org/show_bug.cgi?id=190162
3254
3255         Reviewed by Joseph Pecoraro.
3256
3257         * UserInterface/Main.html:
3258         * UserInterface/Base/Main.js:
3259         (WI.loaded):
3260
3261         * UserInterface/Controllers/AnalyzerManager.js: Removed.
3262         * UserInterface/Models/AnalyzerMessage.js: Removed.
3263
3264         * Scripts/copy-user-interface-resources.pl:
3265         * UserInterface/External/ESLint/LICENSE: Removed.
3266         * UserInterface/External/ESLint/eslint.js: Removed.
3267
3268 2018-10-01  Nikita Vasilyev  <nvasilyev@apple.com>
3269
3270         Web Inspector: Styles: add an experimental setting for multi-property selection
3271         https://bugs.webkit.org/show_bug.cgi?id=190053
3272         <rdar://problem/44842787>
3273
3274         Reviewed by Matt Baker.
3275
3276         This patch only adds a setting. It doesn't change property selection behavior.
3277
3278         * Localizations/en.lproj/localizedStrings.js:
3279         * UserInterface/Base/Setting.js:
3280         * UserInterface/Views/SettingsTabContentView.js:
3281         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3282
3283 2018-10-01  Nikita Vasilyev  <nvasilyev@apple.com>
3284
3285         Web Inspector: Dark Mode: use the same CSS variables for dark and light modes
3286         https://bugs.webkit.org/show_bug.cgi?id=189766
3287         <rdar://problem/44619650>
3288
3289         Use --text-color and --background-color CSS variables for both dark and light modes.
3290
3291         Reviewed by Matt Baker.
3292
3293         * UserInterface/Views/BreakpointPopoverController.css:
3294         (.popover .edit-breakpoint-popover-content > label.toggle):
3295         Color of the label matches the color of the popover, no need to specify it.
3296
3297         (.edit-breakpoint-popover-condition):
3298         (@media (prefers-dark-interface)):
3299         (.popover .edit-breakpoint-popover-content > table > tr > th):
3300         * UserInterface/Views/CompletionSuggestionsView.css:
3301         (.completion-suggestions-container > .item):
3302         (@media (prefers-dark-interface)):
3303         (.completion-suggestions):
3304         * UserInterface/Views/ComputedStyleDetailsPanel.css:
3305         (.details-section:matches(.computed-style-properties, .computed-style-box-model):not(.collapsed) > :matches(.header, .content)):
3306         (.computed-style-properties .property:hover .go-to-arrow):
3307         (@media (prefers-dark-interface)): Deleted.
3308         (.computed-style-properties.details-section): Deleted.
3309         (.details-section.style-box-model:not(.collapsed) > :matches(.header, .content)): Deleted.
3310         * UserInterface/Views/DOMTreeOutline.css:
3311         (.tree-outline.dom):
3312         (@media (prefers-dark-interface)):
3313         * UserInterface/Views/DataGrid.css:
3314         (.data-grid th):
3315         (body:not(.window-inactive, .window-docked-inactive) .data-grid:matches(:focus, .force-focus) tr.editable.selected .cell-content > input):
3316         (@media (prefers-dark-interface)):
3317         * UserInterface/Views/GeneralStyleDetailsSidebarPanel.css:
3318         (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle):
3319         (@media (prefers-dark-interface)):
3320         (.sidebar > .panel.details.css-style > .content ~ .options-container > .new-rule):
3321         * UserInterface/Views/InlineSwatch.css:
3322         (.inline-swatch):
3323         (.inline-swatch-variable-popover .CodeMirror pre):
3324         (@media (prefers-dark-interface)): Deleted.
3325         * UserInterface/Views/NetworkResourceDetailView.css:
3326         (.network-resource-detail):
3327         (.network .network-resource-detail .navigation-bar .item.radio.button.text-only.selected):
3328         (@media (prefers-dark-interface)):
3329         (.resource-headers .value): Deleted.
3330         Move this rule to ResourceHeadersContentView.css.
3331
3332         * UserInterface/Views/ObjectPreviewView.css:
3333         (.object-preview):
3334         (@media (prefers-dark-interface)):
3335         (.object-preview .name):
3336         * UserInterface/Views/ObjectTreeView.css:
3337         (.object-tree):
3338         (.object-tree-property :matches(.formatted-string, .formatted-regexp)):
3339         (@media (prefers-dark-interface)): Deleted.
3340         (.object-tree,): Deleted.
3341
3342         (.object-preview .name): Deleted.
3343         (.object-preview > .size): Deleted.
3344         Move these rules to ObjectPreviewView.css.
3345
3346         * UserInterface/Views/QuickConsole.css:
3347         (.quick-console):
3348         (@media (prefers-dark-interface)):
3349         * UserInterface/Views/ResourceHeadersContentView.css:
3350         (.resource-headers .value):
3351         (.resource-headers.showing-find-banner .search-highlight):
3352         (@media (prefers-dark-interface)): Deleted.
3353         * UserInterface/Views/ResourceTimingBreakdownView.css:
3354         (.resource-timing-breakdown > table > tr.header:not(.total-row) > td):
3355         (@media (prefers-dark-interface)):
3356         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
3357         (.spreadsheet-style-declaration-editor .property:not(.disabled) .value):
3358         (.spreadsheet-style-declaration-editor .property:matches(.invalid-name, .other-vendor, .overridden):not(.disabled) .content > *):
3359         (@media (prefers-dark-interface)):
3360         (.spreadsheet-style-declaration-editor .property.has-warning .warning):
3361         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
3362         (.spreadsheet-css-declaration .media-label):
3363         (.spreadsheet-css-declaration .selector:focus,):
3364         (@media (prefers-dark-interface)):
3365         (.spreadsheet-css-declaration .origin .go-to-link,):
3366         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.css:
3367         (.sidebar > .panel.details.css-style > .content > .rules .section-header .node-link:hover):
3368         (@media (prefers-dark-interface)):
3369         (.sidebar > .panel.details.css-style > .content > .rules .section-header):
3370         * UserInterface/Views/SyntaxHighlightingDefaultTheme.css:
3371         (.cm-s-default,):
3372         (@media (prefers-dark-interface)):
3373         (.syntax-highlighted,): Deleted.
3374         * UserInterface/Views/Table.css:
3375         (.table):
3376         (.table > .header):
3377         * UserInterface/Views/TimelineOverview.css:
3378         (.timeline-overview > .navigation-bar.timelines):
3379         (@media (prefers-dark-interface)):
3380         * UserInterface/Views/TimelineRecordingContentView.css:
3381         (.content-view.timeline-recording > .content-browser > .navigation-bar > .item.scope-bar.default-item-selected > .multiple):
3382         (.content-view.timeline-recording > .content-browser > .navigation-bar > .item.scope-bar.default-item-selected > .multiple .arrows):
3383         (.content-view.timeline-recording > .content-browser .recording-progress > .status > .indeterminate-progress-spinner):
3384         (@media (prefers-dark-interface)): Deleted.
3385         * UserInterface/Views/Variables.css:
3386         (:root):
3387         (@media (prefers-dark-interface)):
3388         * UserInterface/Views/XHRBreakpointPopover.css:
3389         (.popover .xhr-breakpoint-content > .editor-wrapper > .editor):
3390         (@media (prefers-dark-interface)):
3391
3392 2018-09-28  Andy Estes  <aestes@apple.com>
3393
3394         REGRESSION (r236091): CSSKeywordCompletions.js has "checkout" instead of "check-out" as a value for -apple-pay-button-type
3395         https://bugs.webkit.org/show_bug.cgi?id=190096
3396
3397         Reviewed by Ryosuke Niwa.
3398
3399         I changed "checkout" to "check-out" in r235754, but it somehow got flipped back to "checkout" in r236091.
3400
3401         * UserInterface/Models/CSSKeywordCompletions.js:
3402
3403 2018-09-28  Andy Estes  <aestes@apple.com>
3404
3405         [Apple Pay] Remove the "in-store" button type
3406         https://bugs.webkit.org/show_bug.cgi?id=190079
3407
3408         Reviewed by Tim Horton.
3409
3410         * UserInterface/Models/CSSKeywordCompletions.js:
3411
3412 2018-09-28  Devin Rousso  <drousso@apple.com>
3413
3414         Web Inspector: image resources without content are still shown when the Images folder is selected
3415         https://bugs.webkit.org/show_bug.cgi?id=190072
3416
3417         Reviewed by Matt Baker.
3418
3419         * UserInterface/Views/ResourceContentView.js:
3420         (WI.ResourceContentView.prototype.showGenericNoContentMessage):
3421         Treat paths that result in a "Resource has no content" message as a "content error".
3422
3423 2018-09-26  Devin Rousso  <drousso@apple.com>
3424
3425         Web Inspector: Hide DOM and XHR breakpoint sections when they are empty
3426         https://bugs.webkit.org/show_bug.cgi?id=182406
3427         <rdar://problem/37131512>
3428
3429         Reviewed by Joseph Pecoraro.
3430
3431         Combine all breakpoint sections (e.g. DOM, XHR, and Event) into the main "Breakpoints"
3432         section, including all the various "+" buttons for creating different types of breakpoints.
3433
3434         Global breakpoints (except "All Exceptions" and "Uncaught Exceptions") are now deletable,
3435         and can be re-added via the "+" button of the "Breakpoints" section. Deletable global
3436         breakpoints (e.g. "Assertion Failures" and "All Requests") are able to remain visible while
3437         disabled, and will only be hidden when the user specifically deletes them.
3438
3439         * Localizations/en.lproj/localizedStrings.js:
3440         * UserInterface/Base/Setting.js:
3441         * UserInterface/Main.html:
3442
3443         * UserInterface/Controllers/DOMBreakpointTreeController.js: Removed.
3444         * UserInterface/Controllers/EventBreakpointTreeController.js: Removed.
3445         * UserInterface/Controllers/XHRBreakpointTreeController.js: Removed.
3446
3447         * UserInterface/Controllers/DebuggerManager.js:
3448         (WI.DebuggerManager.prototype.get uncaughtExceptionsBreakpoint): Added.
3449         (WI.DebuggerManager.prototype.get assertionFailuresBreakpoint): Added.
3450         (WI.DebuggerManager.prototype.isBreakpointRemovable):
3451         (WI.DebuggerManager.prototype.isBreakpointSpecial): Added.
3452         (WI.DebuggerManager.prototype.isBreakpointEditable):
3453         (WI.DebuggerManager.prototype.addBreakpoint):
3454         (WI.DebuggerManager.prototype.removeBreakpoint):
3455         (WI.DebuggerManager.prototype.initializeTarget):
3456         (WI.DebuggerManager.prototype._breakpointDisabledStateDidChange):
3457         (WI.DebuggerManager.prototype._updateBreakOnExceptionsState):
3458         (WI.DebuggerManager.prototype.get allUncaughtExceptionsBreakpoint): Deleted.
3459         (WI.DebuggerManager.prototype.get assertionsBreakpoint): Deleted.
3460         * UserInterface/Controllers/DOMDebuggerManager.js:
3461         (WI.DOMDebuggerManager.prototype.isBreakpointSpecial): Added.
3462         (WI.DOMDebuggerManager.prototype.addDOMBreakpoint):
3463         (WI.DOMDebuggerManager.prototype.removeDOMBreakpoint):
3464         (WI.DOMDebuggerManager.prototype.addEventBreakpoint):
3465         (WI.DOMDebuggerManager.prototype.removeEventBreakpoint):
3466         (WI.DOMDebuggerManager.prototype.addXHRBreakpoint):
3467         (WI.DOMDebuggerManager.prototype.removeXHRBreakpoint):
3468         (WI.DOMDebuggerManager.prototype.isBreakpointRemovable): Deleted.
3469         Always fire add/remove events, including for special breakpoints, so that any listeners will
3470         be able to adjust accordingly. Even though special breakpoints don't get stored in the lists
3471         held by each manager, we are still able to enable/disable them, and that should be reported.
3472
3473         * UserInterface/Views/DebuggerSidebarPanel.js:
3474         (WI.DebuggerSidebarPanel):
3475         (WI.DebuggerSidebarPanel.prototype.closed):
3476         (WI.DebuggerSidebarPanel.prototype.saveStateToCookie):
3477         (WI.DebuggerSidebarPanel.prototype.restoreStateFromCookie.revealAndSelect):
3478         (WI.DebuggerSidebarPanel.prototype.restoreStateFromCookie):
3479         (WI.DebuggerSidebarPanel.prototype.willDismissPopover):
3480         (WI.DebuggerSidebarPanel.prototype._addBreakpoint):
3481         (WI.DebuggerSidebarPanel.prototype._removeBreakpoint): Added.
3482         (WI.DebuggerSidebarPanel.prototype._addTreeElementForSourceCodeToTreeOutline):
3483         (WI.DebuggerSidebarPanel.prototype._mainResourceDidChange):
3484         (WI.DebuggerSidebarPanel.prototype._breakpointRemoved):
3485         (WI.DebuggerSidebarPanel.prototype._removeDebuggerTreeElement):
3486         (WI.DebuggerSidebarPanel.prototype._treeSelectionDidChange):
3487         (WI.DebuggerSidebarPanel.prototype._addTreeElement.comparator): Added.
3488         (WI.DebuggerSidebarPanel.prototype._addTreeElement): Added.
3489         (WI.DebuggerSidebarPanel.prototype._updatePauseReasonSection):
3490         (WI.DebuggerSidebarPanel.prototype._domBreakpointResolvedStateDidChange): Added.
3491         (WI.DebuggerSidebarPanel.prototype._handleBreakpointElementAddedOrRemoved): Added.
3492         (WI.DebuggerSidebarPanel.prototype._handleCreateBreakpointClicked): Added.
3493         (WI.DebuggerSidebarPanel.prototype._compareTopLevelTreeElements.isSpecialBreakpoint): Deleted.
3494         (WI.DebuggerSidebarPanel.prototype._compareTopLevelTreeElements): Deleted.
3495         (WI.DebuggerSidebarPanel.prototype._domBreakpointAddedOrRemoved): Deleted.
3496         (WI.DebuggerSidebarPanel.prototype._eventBreakpointAddedOrRemoved): Deleted.
3497         (WI.DebuggerSidebarPanel.prototype._addEventBreakpointButtonClicked): Deleted.
3498         (WI.DebuggerSidebarPanel.prototype._addXHRBreakpointButtonClicked): Deleted.
3499         * UserInterface/Views/DebuggerSidebarPanel.css:
3500         (.sidebar > .panel.navigation.debugger .details-section.dom-breakpoints .item.dom-node .titles): Deleted.
3501         (.sidebar > .panel.navigation.debugger .details-section.dom-breakpoints .item.dom-node .icon): Deleted.
3502         (.sidebar > .panel.navigation.debugger .details-section.dom-breakpoints .item.dom-node:not(:hover, .selected) .status .go-to-arrow): Deleted.
3503         (.sidebar > .panel.navigation.debugger .details-section.xhr-breakpoints .item.breakpoint .subtitle): Deleted.
3504         Unify the logic for adding/removing breakpoints of all types.
3505
3506         * UserInterface/Views/BreakpointTreeElement.js:
3507         (WI.BreakpointTreeElement):
3508         (WI.BreakpointTreeElement.prototype.ondelete):
3509         * UserInterface/Views/DOMBreakpointTreeElement.js:
3510         (WI.DOMBreakpointTreeElement):
3511         (WI.DOMBreakpointTreeElement.prototype.ondelete):
3512         * UserInterface/Views/DOMNodeTreeElement.js:
3513         (WI.DOMNodeTreeElement):
3514         (WI.DOMNodeTreeElement.prototype.ondelete):
3515         (WI.DOMNodeTreeElement.prototype.populateContextMenu):
3516         * UserInterface/Views/EventBreakpointTreeElement.js:
3517         (WI.EventBreakpointTreeElement):
3518         (WI.EventBreakpointTreeElement.prototype.ondelete):
3519         (WI.EventBreakpointTreeElement.prototype.populateContextMenu):
3520         * UserInterface/Views/XHRBreakpointTreeElement.js:
3521         (WI.XHRBreakpointTreeElement):
3522         (WI.XHRBreakpointTreeElement.prototype.ondelete):
3523         (WI.XHRBreakpointTreeElement.prototype.populateContextMenu):
3524         * UserInterface/Views/XHRBreakpointTreeElement.css: Added.
3525         (.breakpoint.xhr .subtitle):
3526         Add/remove checks for whether the associated breakpoint can be deleted.
3527
3528         * UserInterface/Views/DOMNodeTreeElement.css: Added.
3529         (.tree-outline .item.dom-node .titles):
3530         (.tree-outline .item.dom-node .icon):
3531         (.tree-outline .item.dom-node:not(:hover, .selected) .status .go-to-arrow):
3532
3533         * UserInterface/Views/ContextMenuUtilities.js:
3534         (WI.appendContextMenuItemsForDOMNode):
3535         (WI.appendContextMenuItemsForDOMNodeBreakpoints): Added.
3536         * UserInterface/Views/DOMTreeElement.js:
3537         (WI.DOMTreeElement.prototype._statusImageContextmenu):
3538
3539         * UserInterface/Views/XHRBreakpointPopover.js:
3540         (WI.XHRBreakpointPopover):
3541         (WI.XHRBreakpointPopover.prototype.get breakpoint): Added.
3542         (WI.XHRBreakpointPopover.prototype.show):
3543         (WI.XHRBreakpointPopover.prototype.dismiss): Added.
3544         (WI.XHRBreakpointPopover.prototype._createEditor):
3545         (WI.XHRBreakpointPopover.prototype._updateEditor):
3546         (WI.XHRBreakpointPopover.prototype.get result): Deleted.
3547         (WI.XHRBreakpointPopover.prototype.get type): Deleted.
3548         (WI.XHRBreakpointPopover.prototype.get value): Deleted.
3549         Drive-by: remove the erroneous usage of `WI.InputPopover.Result`.
3550
3551 2018-09-26  Devin Rousso  <drousso@apple.com>
3552
3553         Web Inspector: determine hasVisibleEffect for each RecordingAction as it's processed
3554         https://bugs.webkit.org/show_bug.cgi?id=189860
3555
3556         Reviewed by Joseph Pecoraro.
3557
3558         * Localizations/en.lproj/localizedStrings.js:
3559         * UserInterface/Base/Setting.js:
3560         * UserInterface/Base/Utilities.js:
3561
3562         * UserInterface/Models/RecordingAction.js:
3563         (WI.RecordingAction.prototype.process.getContent):
3564         (WI.RecordingAction.prototype.process):
3565
3566         * UserInterface/Views/RecordingActionTreeElement.js:
3567         (WI.RecordingActionTreeElement.prototype.onattach):
3568
3569         * UserInterface/Views/SettingsTabContentView.js:
3570         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3571
3572         * UserInterface/Views/RecordingContentView.js:
3573         (WI.RecordingContentView.prototype._updateImageGrid):
3574         Drive-by: don't attempt to show the image grid if we haven't called initialized yet.
3575
3576         * UserInterface/Views/CanvasSidebarPanel.js:
3577         (WI.CanvasSidebarPanel.prototype._treeOutlineSelectionDidChange):
3578         Drive-by: ensure that the `WI.RecordingContentView` is showing before applying the action.
3579
3580 2018-09-26  Nikita Vasilyev  <nvasilyev@apple.com>
3581
3582         Web Inspector: Dark Mode: new watch expression popover has light background
3583         https://bugs.webkit.org/show_bug.cgi?id=190013
3584         <rdar://problem/44810000>
3585
3586         Reviewed by Matt Baker.
3587
3588         Make the background dark to match the CodeMirror editor background.
3589
3590         * UserInterface/Views/ScopeChainDetailsSidebarPanel.css:
3591         (@media (prefers-dark-interface)):
3592         (.watch-expression-editor):
3593
3594 2018-09-21  Nikita Vasilyev  <nvasilyev@apple.com>
3595
3596         REGRESSION(r236237): Web Inspector: DarkMode: white background in Elements and Timelines
3597         https://bugs.webkit.org/show_bug.cgi?id=189852
3598
3599         Reviewed by Joseph Pecoraro.
3600
3601         * UserInterface/Views/Main.css:
3602         (body):
3603         (#main):
3604
3605 2018-09-21  Brian Burg  <bburg@apple.com>
3606
3607         Web Inspector: remove unnecessary WI.Platform.version checks
3608         https://bugs.webkit.org/show_bug.cgi?id=189845
3609
3610         Reviewed by Matt Baker.
3611
3612         * UserInterface/Base/Platform.js:
3613         (osVersionMatch): Add name for macOS Mojave.
3614
3615         * UserInterface/Base/Main.js:
3616         * UserInterface/Views/Popover.js:
3617         Remove old logic that's no longer needed.
3618
3619 2018-09-21  Devin Rousso  <drousso@apple.com>
3620
3621         Web Inspector: remove setting for Sources tab
3622         https://bugs.webkit.org/show_bug.cgi?id=189817
3623
3624         Reviewed by Joseph Pecoraro.
3625
3626         * Localizations/en.lproj/localizedStrings.js:
3627         * UserInterface/Base/Setting.js:
3628         * UserInterface/Main.html:
3629         * UserInterface/Base/Main.js:
3630         (WI.contentLoaded):
3631         (WI._debuggerDidPause):
3632         (WI.isShowingSourcesTab): Removed.
3633         (WI.showSourcesTab): Removed.
3634
3635         * UserInterface/Views/SourcesSidebarPanel.css: Removed.
3636         * UserInterface/Views/SourcesSidebarPanel.js: Removed.
3637         * UserInterface/Views/SourcesTabContentView.js: Removed.
3638
3639         * UserInterface/Views/ContextMenuUtilities.js:
3640         (WI.appendContextMenuItemsForURL):
3641
3642         * UserInterface/Views/SettingsTabContentView.js:
3643         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3644
3645         * UserInterface/Views/SourceCodeTextEditor.js:
3646         (WI.SourceCodeTextEditor.prototype.textEditorGutterContextMenu):
3647
3648 2018-09-20  Simon Fraser  <simon.fraser@apple.com>
3649
3650         Make "overflow: overlay" a synonym for "overflow: auto"
3651         https://bugs.webkit.org/show_bug.cgi?id=189811
3652
3653         Reviewed by Zalan Bujtas.
3654         
3655         Remove "overlay" from the overflow values.
3656
3657         * UserInterface/Models/CSSKeywordCompletions.js:
3658         * UserInterface/Views/VisualStyleDetailsPanel.js:
3659         (WI.VisualStyleDetailsPanel.prototype._populateDisplaySection):
3660
3661 2018-09-21  Devin Rousso  <drousso@apple.com>
3662
3663         Web Inspector: hide Accessibility Audit Tab setting
3664         https://bugs.webkit.org/show_bug.cgi?id=189816
3665
3666         Reviewed by Joseph Pecoraro.
3667
3668         Considering that this tab doesn't exist, there's no reason to have a setting/UI for it.
3669
3670         * UserInterface/Base/Setting.js:
3671         * UserInterface/Views/SettingsTabContentView.js:
3672         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3673
3674 2018-09-21  Devin Rousso  <drousso@apple.com>
3675
3676         Web Inspector: remove Legacy Style Editor
3677         https://bugs.webkit.org/show_bug.cgi?id=189808
3678
3679         Reviewed by Joseph Pecoraro.
3680
3681         The Legacy Style Editor has been hidden behind an "experimental" setting for almost a year.
3682         It's time that we remove it, especially since the new Style Editor is at a similar, if not
3683         more advanced, state.
3684
3685         * .eslintrc:
3686         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj:
3687         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj.filters:
3688         * Localizations/en.lproj/localizedStrings.js:
3689         * Tools/PrettyPrinting/index.html:
3690         * UserInterface/Main.html:
3691         * UserInterface/Test.html:
3692         * UserInterface/Base/Setting.js:
3693
3694         * UserInterface/Base/TextUtilities.js: Removed.
3695         * UserInterface/Base/Utilities.js:
3696
3697         * UserInterface/Views/RulesStyleDetailsPanel.css: Removed.
3698         * UserInterface/Views/RulesStyleDetailsPanel.js: Removed.
3699         * UserInterface/Views/CSSStyleDeclarationSection.css: Removed.
3700         * UserInterface/Views/CSSStyleDeclarationSection.js: Removed.
3701         * UserInterface/Views/CSSStyleDeclarationTextEditor.css: Removed.
3702         * UserInterface/Views/CSSStyleDeclarationTextEditor.js: Removed.
3703
3704         * UserInterface/Models/CSSProperty.js:
3705         (WI.CSSProperty.prototype.get text):
3706         (WI.CSSProperty.prototype.get synthesizedText): Deleted.
3707
3708         * UserInterface/Models/CSSStyleDeclaration.js:
3709         (WI.CSSStyleDeclaration):
3710         (WI.CSSStyleDeclaration.prototype.set text):
3711         (WI.CSSStyleDeclaration.prototype.resetText): Deleted.
3712         (WI.CSSStyleDeclaration.prototype.get modified): Deleted.
3713         (WI.CSSStyleDeclaration.prototype.generateCSSRuleString): Deleted.
3714         (WI.CSSStyleDeclaration.prototype.isInspectorRule): Deleted.
3715
3716         * UserInterface/Models/CSSSelector.js:
3717         (WI.CSSSelector.prototype.isGreaterThan): Deleted.
3718
3719         * UserInterface/Models/CSSRule.js:
3720         (WI.CSSRule.prototype.update):
3721         (WI.CSSRule.prototype.get matchedSelectors): Deleted.
3722         (WI.CSSRule.prototype.get matchedSelectorText): Deleted.
3723         (WI.CSSRule.prototype.hasMatchedPseudoElementSelector): Deleted.
3724         (WI.CSSRule.prototype.get mediaText): Deleted.
3725         (WI.CSSRule.prototype.get mostSpecificSelector): Deleted.
3726         (WI.CSSRule.prototype.selectorIsGreater): Deleted.
3727         (WI.CSSRule.prototype._determineMostSpecificSelector): Deleted.
3728
3729         * UserInterface/Models/DOMNodeStyles.js:
3730         (WI.DOMNodeStyles.prototype.changeRule.changeCompleted): Deleted.
3731         (WI.DOMNodeStyles.prototype.changeRule.styleChanged): Deleted.
3732         (WI.DOMNodeStyles.prototype.changeRule.changeText): Deleted.
3733         (WI.DOMNodeStyles.prototype.changeRule.ruleSelectorChanged): Deleted.
3734         (WI.DOMNodeStyles.prototype.changeRule): Deleted.
3735
3736         * UserInterface/Models/CSSCompletions.js:
3737         (WI.CSSCompletions.prototype.isValidPropertyName):
3738         (WI.CSSCompletions):
3739         (WI.CSSCompletions.prototype.keySet): Deleted.
3740         (WI.CSSCompletions.prototype.propertyRequiresWebkitPrefix): Deleted.
3741         (WI.CSSCompletions.prototype.getClosestPropertyName): Deleted.
3742
3743         * UserInterface/Views/ComputedStyleDetailsPanel.js:
3744         (WI.ComputedStyleDetailsPanel.prototype.cssStyleDeclarationTextEditorStartEditingAdjacentRule): Deleted.
3745
3746         * UserInterface/Views/RulesStyleDetailsSidebarPanel.js:
3747         (WI.RulesStyleDetailsSidebarPanel):
3748
3749         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
3750         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.spreadsheetStylePropertyFocusMoved):
3751
3752         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
3753         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.spreadsheetCSSStyleDeclarationEditorStartEditingRuleSelector): Added.
3754         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.cssStyleDeclarationTextEditorStartEditingRuleSelector): Deleted.
3755
3756         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
3757         (WI.SpreadsheetRulesStyleDetailsPanel):
3758         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.css:
3759         (.sidebar > .panel.details.css-style .rules): Added.
3760         (.sidebar > .panel.details.css-style > .content > .rules .section-header): Added.
3761         (.sidebar > .panel.details.css-style > .content > .rules .section-header .node-link): Added.
3762         (.sidebar > .panel.details.css-style > .content > .rules .section-header .node-link:hover): Added.
3763         (.sidebar > .panel.details.css-style > .content > .rules > .message-text-view): Added.
3764         (.sidebar > .panel.details.css-style > .content > .rules:not(.filter-non-matching) > .message-text-view): Added.
3765         (@media (prefers-dark-interface)):
3766         (.sidebar > .panel.details.css-style > .content > .rules .section-header): Added.
3767         (.sidebar > .panel.details.css-style > .content > .rules .section-header .node-link:hover): Added.
3768         (.spreadsheet-style-panel .section-header): Deleted.
3769         (.spreadsheet-style-panel .section-header .node-link): Deleted.
3770         (.spreadsheet-style-panel .section-header .node-link:hover): Deleted.
3771         (.spreadsheet-style-panel .section-header): Deleted.
3772         (.spreadsheet-style-panel .section-header .node-link:hover): Deleted.
3773
3774         * UserInterface/Views/CodeMirrorAdditions.js:
3775         (extendedCSSRuleStartState): Removed.
3776         * UserInterface/Views/CodeMirrorFormatters.js:
3777         Remove "css-rule" CodeMirror mode.
3778
3779         * UserInterface/Views/CodeMirrorTextMarkers.js:
3780         (createCodeMirrorVariableTextMarkers): Deleted.
3781
3782         * UserInterface/Views/SettingsTabContentView.js:
3783         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3784
3785 2018-09-21  Mike Gorse  <mgorse@suse.com>
3786
3787         Build tools should work when the /usr/bin/python is python3
3788         https://bugs.webkit.org/show_bug.cgi?id=156674
3789
3790         Reviewed by Michael Catanzaro.
3791
3792         * Scripts/copy-user-interface-resources.pl: Use $PYTHON if set
3793         in the environment.
3794
3795 2018-09-20  Devin Rousso  <drousso@apple.com>
3796
3797         Web Inspector: remove Visual Style CSS details sidebar panel
3798         https://bugs.webkit.org/show_bug.cgi?id=189807
3799
3800         Reviewed by Joseph Pecoraro.
3801
3802         The Visual Style CSS details sidebar panel has been hidden behind an "experimental" setting
3803         for almost a year.  It's time that we remove it.
3804
3805         * Localizations/en.lproj/localizedStrings.js:
3806         * UserInterface/Base/Setting.js:
3807         * UserInterface/Main.html:
3808
3809         * UserInterface/Views/ElementsTabContentView.js:
3810         (WI.ElementsTabContentView):
3811         * UserInterface/Views/SettingsTabContentView.js:
3812         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
3813
3814         * UserInterface/Images/AnimationPlayStatePaused.svg: Removed.
3815         * UserInterface/Images/AnimationPlayStateRunning.svg: Removed.
3816         * UserInterface/Images/ClearBoth.svg: Removed.
3817         * UserInterface/Images/ClearLeft.svg: Removed.
3818         * UserInterface/Images/ClearRight.svg: Removed.
3819         * UserInterface/Images/FloatLeft.svg: Removed.
3820         * UserInterface/Images/FloatRight.svg: Removed.
3821         * UserInterface/Images/FontStyleItalic.svg: Removed.
3822         * UserInterface/Images/FontStyleNormal.svg: Removed.
3823         * UserInterface/Images/ListStylePositionInside.svg: Removed.
3824         * UserInterface/Images/ListStylePositionOutside.svg: Removed.
3825         * UserInterface/Images/TextAlignCenter.svg: Removed.
3826         * UserInterface/Images/TextAlignJustify.svg: Removed.
3827         * UserInterface/Images/TextAlignLeft.svg: Removed.
3828         * UserInterface/Images/TextAlignRight.svg: Removed.
3829         * UserInterface/Images/TextDecorationLineThrough.svg: Removed.
3830         * UserInterface/Images/TextDecorationOverline.svg: Removed.
3831         * UserInterface/Images/TextDecorationUnderline.svg: Removed.
3832         * UserInterface/Images/TextTransformCapitalize.svg: Removed.
3833         * UserInterface/Images/TextTransformLowercase.svg: Removed.
3834         * UserInterface/Images/TextTransformUppercase.svg: Removed.
3835         * UserInterface/Images/VisualStyleNone.svg: Removed.
3836         * UserInterface/Images/VisualStylePropertyLinked.svg: Removed.
3837         * UserInterface/Images/VisualStylePropertyUnlinked.svg: Removed.
3838
3839         * UserInterface/Views/VisualStyleBackgroundPicker.css: Removed.
3840         * UserInterface/Views/VisualStyleBackgroundPicker.js: Removed.
3841         * UserInterface/Views/VisualStyleBasicInput.js: Removed.
3842         * UserInterface/Views/VisualStyleColorPicker.css: Removed.
3843         * UserInterface/Views/VisualStyleColorPicker.js: Removed.
3844         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.css: Removed.
3845         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.js: Removed.
3846         * UserInterface/Views/VisualStyleDetailsPanel.css: Removed.
3847         * UserInterface/Views/VisualStyleDetailsPanel.js: Removed.
3848         * UserInterface/Views/VisualStyleDetailsSidebarPanel.js: Removed.
3849         * UserInterface/Views/VisualStyleFontFamilyListEditor.js: Removed.
3850         * UserInterface/Views/VisualStyleFontFamilyTreeElement.js: Removed.
3851         * UserInterface/Views/VisualStyleKeywordCheckbox.css: Removed.