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