0e7e1b62767c13eca297848d2371d54a060eb85f
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2017-09-27  Matt Baker  <mattbaker@apple.com>
2
3         Web Inspector: Create ResourceCollectionContentView and make CollectionContentView easier to extend
4         https://bugs.webkit.org/show_bug.cgi?id=177419
5
6         Reviewed by Devin Rousso.
7
8         CollectionContentView should be generic, work with any represented object
9         Collection, and not perform any type checking. It should just map items
10         to ContentViews using the provided ContentView constructor.
11
12         The behavior when clicking a ContentView in the collection has been extended.
13         If selection is enabled, clicking a ContentView will cause a "selected" class
14         to be applied to its element, and a SupplementalRepresentedObjectsDidChange
15         event is dispatched.
16
17         * Localizations/en.lproj/localizedStrings.js:
18         * UserInterface/Main.html:
19         New file, move CollectionContentView above subclasses.
20
21         * UserInterface/Models/ResourceCollection.js:
22         (WI.ResourceCollection.prototype.get resourceType):
23         Make resource type publicly available.
24
25         * UserInterface/Views/CollectionContentView.js:
26         Move type checking of the collection out of the base class and assert
27         that ContentViews are created when invoking `contentViewConstructor`.
28         (WI.CollectionContentView):
29         (WI.CollectionContentView.titleForCollection):
30         (WI.CollectionContentView.prototype.get supplementalRepresentedObjects):
31         (WI.CollectionContentView.prototype.get selectionEnabled):
32         (WI.CollectionContentView.prototype.set selectionEnabled):
33         (WI.CollectionContentView.prototype.addContentViewForItem):
34         (WI.CollectionContentView.prototype.removeContentViewForItem):
35         (WI.CollectionContentView.prototype.contentViewAdded):
36         (WI.CollectionContentView.prototype.contentViewRemoved):
37         (WI.CollectionContentView.prototype.initialLayout):
38         (WI.CollectionContentView.prototype.attached):
39         (WI.CollectionContentView.prototype.detached):
40         (WI.CollectionContentView.prototype._handleItemAdded):
41         (WI.CollectionContentView.prototype._handleItemRemoved):
42         (WI.CollectionContentView.prototype._selectItem):
43         (WI.CollectionContentView.prototype._addContentViewForItem): Deleted.
44         (WI.CollectionContentView.prototype._removeContentViewForItem): Deleted.
45
46         * UserInterface/Views/ContentView.js:
47         (WI.ContentView.createFromRepresentedObject):
48         Create a ResourceCollectionContentView. In the future, additional
49         Collection types can be mapped to their associated CollectionContentView.
50
51         * UserInterface/Views/ResourceCollectionContentView.js: Added.
52         New class for resource-specific logic previously in CollectionContentView.
53         (WI.ResourceCollectionContentView):
54         (WI.ResourceCollectionContentView.prototype.contentViewAdded):
55         (WI.ResourceCollectionContentView.prototype._handleContentError):
56         Remove ContentView without removing the resource from its collection.
57
58 2017-09-27  Ross Kirsling  <ross.kirsling@sony.com>
59
60         Web Inspector: Fix Layers tab sidebar popover.
61         https://bugs.webkit.org/show_bug.cgi?id=177477
62
63         Reviewed by Matt Baker.
64
65         * UserInterface/Views/LayerDetailsSidebarPanel.js:
66         (WI.LayerDetailsSidebarPanel.prototype.willDismissPopover): Added.
67         (WI.LayerDetailsSidebarPanel.prototype._buildDataGrid):
68         (WI.LayerDetailsSidebarPanel.prototype._sortDataGrid):
69         (WI.LayerDetailsSidebarPanel.prototype._dataGridSelectedNodeChanged):
70         (WI.LayerDetailsSidebarPanel.prototype._dataGridFocused):
71         (WI.LayerDetailsSidebarPanel.prototype._dataGridBlurred):
72         (WI.LayerDetailsSidebarPanel.prototype._showPopoverForSelectedNode): Refactored.
73         (WI.LayerDetailsSidebarPanel.prototype._presentPopover):
74         (WI.LayerDetailsSidebarPanel.prototype._dataGridClicked): Deleted -- not actually desired behavior.
75         (WI.LayerDetailsSidebarPanel.prototype._updatePopoverForSelectedNode): Deleted -- code simplification.
76         (WI.LayerDetailsSidebarPanel.prototype._hidePopover): Deleted -- no longer needed.
77
78 2017-09-27  Fujii Hironori  <Hironori.Fujii@sony.com>
79
80         [GTK] Web Inspector: Add Canvas2D.svg and Canvas3D.svg
81         https://bugs.webkit.org/show_bug.cgi?id=175364
82
83         Reviewed by Carlos Garcia Campos.
84
85         Add more free icons.
86
87         * UserInterface/Images/gtk/Canvas2D.svg: Copied from Source/WebInspectorUI/UserInterface/Images/gtk/Canvas.svg.
88         * UserInterface/Images/gtk/Canvas3D.svg: Added.
89
90 2017-09-26  Nikita Vasilyev  <nvasilyev@apple.com>
91
92         Web Inspector: Styles Redesign: Style unused, overridden, and invalid properties differently
93         https://bugs.webkit.org/show_bug.cgi?id=177461
94
95         Reviewed by Matt Baker.
96
97         Style properties the same way as in the current styles sidebar with two minor changes:
98         - Commented out properties are never strikethrough.
99         - Non-inherited properties of inherited rules are no longer strikethrough (but still semi-transparent).
100
101         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
102         (.spreadsheet-style-declaration-editor .property:matches(.invalid, .other-vendor, .overridden):not(.disabled)):
103         Use the same styles as in the old sidebar, with exception of `-webkit-text-stroke-width: 0.000000000000001px`
104         hack, which was replaced by -webkit-text-decoration-color.
105
106         (.spreadsheet-style-declaration-editor .property.invalid:not(.disabled)):
107         (.spreadsheet-style-declaration-editor .property.not-inherited):
108         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
109         (WI.SpreadsheetStyleProperty):
110         (WI.SpreadsheetStyleProperty.prototype._update):
111
112 2017-09-26  Joseph Pecoraro  <pecoraro@apple.com>
113
114         Web Inspector: Improve Table scrolling performance
115         https://bugs.webkit.org/show_bug.cgi?id=177468
116
117         Reviewed by Brian Burg.
118
119         This reduces work during scrolling updates in two ways.
120
121         1. Avoid recalculating the width/height of the Table on scroll.
122           - We only need to recalculate sizes if the view changes size.
123         2. Avoid resetting sizes on all cells if the sizes did not change.
124           - Enumerating and setting style.width values was showing up in profiles.
125
126         * UserInterface/Views/Table.js:
127         (WI.Table):
128         New member variables for a cached width/height of the scrollable region.
129         _cachedWidth is the same as _cachedScrollableHeight but they could be
130         different so I just kept them separate for now. Also switch to
131         getBoundingClientRect which gets us a better value then
132         offsetWidth/offsetHeight.
133
134         (WI.Table.prototype.resize):
135         Clear cached size and relayout.
136
137         (WI.Table.prototype.layout):
138         If we did not resize, layout without recalculating sizes.
139
140         (WI.Table.prototype.resizerDragging):
141         (WI.Table.prototype._getOrCreateRow):
142         When column widths change increment the width generation. This will let
143         us quickly check if a row's cells are appropriately sized or not.
144
145         (WI.Table.prototype._resizeColumnsAndFiller):
146         Cache width values after recalculating. Provide a fast path if values
147         have not changed.
148
149         (WI.Table.prototype._updateVisibleRows):
150         (WI.Table.prototype._updateFillerRowWithNewHeight):
151         Factor out updating the filler row into a function.
152         
153         (WI.Table.prototype._applyColumnWidths):
154         Always update the width generation of a row after setting its cell widths.
155
156         (WI.Table.prototype._applyColumnWidthsToColumnsIfNeeded):
157         Fast path only updates row cell widths if they need to change.
158
159 2017-09-25  Devin Rousso  <webkit@devinrousso.com>
160
161         Web Inspector: move Console.addInspectedNode to DOM.setInspectedNode
162         https://bugs.webkit.org/show_bug.cgi?id=176827
163
164         Reviewed by Joseph Pecoraro.
165
166         * UserInterface/Controllers/DOMTreeManager.js:
167         (WI.DOMTreeManager):
168         (WI.DOMTreeManager.prototype.setInspectedNode):
169
170         * UserInterface/Views/DOMTreeContentView.js:
171         (WI.DOMTreeContentView.prototype._selectedNodeDidChange):
172
173 2017-09-25  Joseph Pecoraro  <pecoraro@apple.com>
174
175         Web Inspector: Add loading indicator next to resources in the Network Tab
176         https://bugs.webkit.org/show_bug.cgi?id=177469
177
178         Reviewed by Matt Baker.
179
180         * UserInterface/Models/Resource.js:
181         (WI.Resource.prototype.isLoading):
182         Provide a useful accessor to check if the Resource is considered loading or not.
183
184         * UserInterface/Views/NetworkGridContentView.js:
185         (WI.NetworkGridContentView.prototype._networkTimelineRecordAdded):
186         * UserInterface/Views/ResourceTimelineDataGridNode.js:
187         (WI.ResourceTimelineDataGridNode.prototype._updateStatus):
188         * UserInterface/Views/ResourceTreeElement.js:
189         (WI.ResourceTreeElement.prototype._updateStatus):
190         Switch existing code to use the new isLoading() function and make the similiar
191         code more consistent.
192
193         * UserInterface/Views/NetworkTableContentView.css:
194         (body[dir=ltr] .content-view.network .table .cell.name > .status):
195         (body[dir=rtl] .content-view.network .table .cell.name > .status):
196         (.content-view.network .table .cell.name > .status .indeterminate-progress-spinner):
197         * UserInterface/Views/NetworkTableContentView.js:
198         (WI.NetworkTableContentView.prototype._populateNameCell):
199         Add a loading indicator to the Name column in the Network tab.
200         It is sized the same as the loading indicator in the Resource tab.
201
202 2017-09-25  Ross Kirsling  <ross.kirsling@sony.com>
203
204         Web Inspector: Elements tab's Layers sidebar should disappear when Layers tab is present.
205         https://bugs.webkit.org/show_bug.cgi?id=177476
206
207         Reviewed by Devin Rousso.
208
209         * UserInterface/Views/ElementsTabContentView.js:
210         (WI.ElementsTabContentView):
211
212 2017-09-25  Devin Rousso  <webkit@devinrousso.com>
213
214         Web Inspector: Add autocompletion suggestions for CSS attr based on the selected element's attributes
215         https://bugs.webkit.org/show_bug.cgi?id=177346
216
217         Reviewed by Joseph Pecoraro.
218
219         * UserInterface/Controllers/CodeMirrorCompletionController.js:
220         (WI.CodeMirrorCompletionController.prototype._generateCSSCompletions):
221         Provide a way for delegates to add completion items for CSS functions based on the name of
222         the function.
223
224         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
225         (WI.CSSStyleDeclarationTextEditor.prototype.completionControllerCSSFunctionValuesNeeded):
226         If the function name is "attr", also return a list of the names of all the selected node's
227         attributes.
228
229 2017-09-25  Joseph Pecoraro  <pecoraro@apple.com>
230
231         Unreviewed follow-up to r222470.
232
233         * UserInterface/Main.html:
234         Remove reference to css file that doesn't exist yet.
235
236 2017-09-22  Joseph Pecoraro  <pecoraro@apple.com>
237
238         Web Inspector: Include a table in New Network Tab
239         https://bugs.webkit.org/show_bug.cgi?id=177206
240
241         Reviewed by Matt Baker and Brian Burg.
242
243         This includes an initial implementation of the NetworkTableContentView,
244         and a generic Table / TableColumn implementation ported from DataGrid.
245
246         * Localizations/en.lproj/localizedStrings.js:
247         * UserInterface/Main.html:
248         New strings and files.
249
250         * UserInterface/Views/NetworkGridContentView.css:
251         (.content-view:matches(.network, .network-grid) > .data-grid .cache-type):
252         (.cache-type): Deleted.
253         * UserInterface/Views/ResourceDetailsSidebarPanel.css:
254         (.sidebar > .panel.resource-details .cache-type):
255         Make the .cache-type selector more specific for the legacy cases.
256
257         * UserInterface/Views/NetworkTabContentView.css: Copied from Source/WebInspectorUI/UserInterface/Views/NetworkGridContentView.css.
258         (.content-view.network > .content-browser):
259         * UserInterface/Views/NetworkTabContentView.js:
260         (WI.NetworkTabContentView.prototype.shown):
261         (WI.NetworkTabContentView.prototype.hidden):
262         (WI.NetworkTabContentView.prototype.closed):
263         NetworkTabContentView has a ContentBrowser so it should be passing
264         ContentBrowser lifecycle events (shown, hidden, closed) through to
265         the sub-content browser.
266
267         * UserInterface/Views/TableColumn.js: Added.
268         (WI.TableColumn.prototype.get identifier):
269         (WI.TableColumn.prototype.get name):
270         (WI.TableColumn.prototype.get width):
271         (WI.TableColumn.prototype.get minWidth):
272         (WI.TableColumn.prototype.get maxWidth):
273         (WI.TableColumn.prototype.get hidden):
274         (WI.TableColumn.prototype.get defaultHidden):
275         (WI.TableColumn.prototype.get sortable):
276         (WI.TableColumn.prototype.get align):
277         (WI.TableColumn.prototype.get locked):
278         (WI.TableColumn.prototype.get flexible):
279         (WI.TableColumn.prototype.setWidth):
280         (WI.TableColumn.prototype.setHidden):
281         Model object for a column. Values are getter only. Columns may express
282         size constraints (min width / max width) that are respected as much as
283         possible. When a column is resized it dispatches an event.
284
285         * UserInterface/Views/Table.js: Added.
286         (WI.Table):
287         (WI.Table.prototype.get element):
288         (WI.Table.prototype.get identifier):
289         (WI.Table.prototype.get dataSource):
290         (WI.Table.prototype.get delegate):
291         (WI.Table.prototype.get rowHeight):
292         (WI.Table.prototype.get selectedRow):
293         (WI.Table.prototype.get sortOrder):
294         (WI.Table.prototype.set sortOrder):
295         (WI.Table.prototype.get sortColumnIdentifier):
296         (WI.Table.prototype.set sortColumnIdentifier):
297         (WI.Table.prototype.resize):
298         (WI.Table.prototype.reloadData):
299         (WI.Table.prototype.reloadDataAddedToEndOnly):
300         (WI.Table.prototype.reloadRow):
301         (WI.Table.prototype.reloadCell):
302         (WI.Table.prototype.selectRow):
303         (WI.Table.prototype.clearSelectedRow):
304         (WI.Table.prototype.columnWithIdentifier):
305         (WI.Table.prototype.addColumn):
306         (WI.Table.prototype.showColumn):
307         (WI.Table.prototype.hideColumn):
308         (WI.Table.prototype.restoreScrollPosition):
309         (WI.Table.prototype.initialLayout):
310         (WI.Table.prototype.layout):
311         (WI.Table.prototype.resizerDragStarted):
312         (WI.Table.prototype.resizerDragging.growableSize):
313         (WI.Table.prototype.resizerDragging.shrinkableSize):
314         (WI.Table.prototype.resizerDragging.canGrow):
315         (WI.Table.prototype.resizerDragging.canShrink):
316         (WI.Table.prototype.resizerDragging.columnToResize):
317         (WI.Table.prototype.resizerDragging):
318         (WI.Table.prototype.resizerDragEnded):
319         (WI.Table.prototype._needsLayout):
320         (WI.Table.prototype._createHeaderCell):
321         (WI.Table.prototype._createFillerCell):
322         (WI.Table.prototype._createCell):
323         (WI.Table.prototype._getOrCreateRow):
324         (WI.Table.prototype._populatedCellForColumnAndRow):
325         (WI.Table.prototype._populateRow):
326         (WI.Table.prototype._resizeColumnsAndFiller.distributeRemainingPixels):
327         (WI.Table.prototype._resizeColumnsAndFiller.bestFit):
328         (WI.Table.prototype._resizeColumnsAndFiller):
329         (WI.Table.prototype._updateVisibleRows):
330         (WI.Table.prototype._applyColumnWidths):
331         (WI.Table.prototype._positionResizerElements):
332         (WI.Table.prototype._isRowVisible):
333         (WI.Table.prototype._indexToInsertColumn):
334         (WI.Table.prototype._handleScroll):
335         (WI.Table.prototype._handleKeyDown):
336         (WI.Table.prototype._handleClick):
337         (WI.Table.prototype._handleContextMenu):
338         (WI.Table.prototype._handleHeaderCellClicked):
339         (WI.Table.prototype._handleHeaderContextMenu):
340         Table is mostly a re-implementation of DataGrid. Much of its functionality
341         was a direct copy that was then modified and simplified for a smaller
342         and simpler feature set.
343         
344         Table behaves more like Cocoa's NSTableView. A datasource supplies the
345         number of rows, which Table uses to resize appropriately. A delegate is
346         then called to populate cells in a row when they become visible. Table
347         does minimal caching, and in the event of data source changes
348         (resorting, adding rows, modifying rows, etc) the visible rows are
349         simply recreated from scratch. Clients should therefore make generating
350         a cell's contents as simple and performant as possible.
351
352         Unlike DataGrid, rows are just an <li> with a bunch of cells. Since the
353         number of rows are limited to (roughly) those that are visible, most
354         operations, like resizing, creates / modifies each of the visible cells.
355
356         Finally, Table's resizing operations behave more like flexible content
357         than DataGrid's neighbor only approach. This makes resizing the table
358         generally easier to do, but may need refinement to decide which columns
359         we would prefer to distribute columns during resizing.
360
361         * UserInterface/Views/Table.css: Added.
362         (.table):
363         (.table > .header):
364         (.table > .header > .sortable:active):
365         (.table > .header > :matches(.sort-ascending, .sort-descending)):
366         (.table > .header > :matches(.sort-ascending, .sort-descending)::after):
367         (body[dir=ltr] .table > .header > :matches(.sort-ascending, .sort-descending)):
368         (body[dir=rtl] .table > .header > :matches(.sort-ascending, .sort-descending)):
369         (body[dir=ltr] .table > .header > :matches(.sort-ascending, .sort-descending)::after):
370         (body[dir=rtl] .table > .header > :matches(.sort-ascending, .sort-descending)::after):
371         (.table > .header > .sort-ascending::after):
372         (.table > .header > .sort-descending::after):
373         (.table > .data-container):
374         (.table > .data-container.not-scrollable):
375         (.table > .data-container > .data-list):
376         (.table > .data-container > .data-list.odd-first-zebra-stripe):
377         (.table > .data-container > .data-list > li):
378         (.table > .data-container > .data-list > li.selected):
379         (.table:focus > .data-container > .data-list li.selected):
380         (.table .cell):
381         (body[dir=ltr] .table .cell:not(:last-child)):
382         (body[dir=rtl] .table .cell:not(:last-child)):
383         (body[dir=ltr] .table .cell:first-child):
384         (body[dir=rtl] .table .cell:first-child):
385         (.table :not(.header) .cell:first-of-type):
386         (.table .cell.align-right):
387         (.table .cell.align-left):
388         (.table .cell.align-center):
389         Styles mostly taken from DataGrid with a few minor tweaks.
390
391         * UserInterface/Views/NetworkTableContentView.css: Copied from Source/WebInspectorUI/UserInterface/Views/NetworkGridContentView.css.
392         (.content-view.network .table .icon):
393         (body[dir=ltr] .content-view.network .table .icon):
394         (body[dir=rtl] .content-view.network .table .icon):
395         (.content-view.network .table li:not(.filler) .cell.name):
396         (.content-view.network .table .cache-type):
397         (.content-view.network .table .error):
398         * UserInterface/Views/NetworkTableContentView.js:
399         (WI.NetworkTableContentView):
400         (WI.NetworkTableContentView.shortDisplayNameForResourceType):
401         (WI.NetworkTableContentView.prototype.get navigationItems):
402         (WI.NetworkTableContentView.prototype.shown):
403         (WI.NetworkTableContentView.prototype.closed):
404         (WI.NetworkTableContentView.prototype.reset):
405         (WI.NetworkTableContentView.prototype.tableNumberOfRows):
406         (WI.NetworkTableContentView.prototype.tableSortChanged):
407         (WI.NetworkTableContentView.prototype.tableCellClicked):
408         (WI.NetworkTableContentView.prototype.tableCellContextMenuClicked):
409         (WI.NetworkTableContentView.prototype.tableSelectedRowChanged):
410         (WI.NetworkTableContentView.prototype.tablePopulateCell):
411         (WI.NetworkTableContentView.prototype._populateNameCell):
412         (WI.NetworkTableContentView.prototype._populateTransferSizeCell):
413         (WI.NetworkTableContentView.prototype._generateSortComparator):
414         (WI.NetworkTableContentView.prototype.initialLayout):
415         (WI.NetworkTableContentView.prototype.layout):
416         (WI.NetworkTableContentView.prototype._processPendingEntries):
417         (WI.NetworkTableContentView.prototype._rowIndexForResource):
418         (WI.NetworkTableContentView.prototype._updateEntryForResource):
419         (WI.NetworkTableContentView.prototype._mainResourceDidChange):
420         (WI.NetworkTableContentView.prototype._resourceLoadingDidFinish):
421         (WI.NetworkTableContentView.prototype._resourceLoadingDidFail):
422         (WI.NetworkTableContentView.prototype._resourceTransferSizeDidChange):
423         (WI.NetworkTableContentView.prototype._networkTimelineRecordAdded):
424         (WI.NetworkTableContentView.prototype._isDefaultSort):
425         (WI.NetworkTableContentView.prototype._insertResourceAndReloadTable):
426         (WI.NetworkTableContentView.prototype._displayType):
427         (WI.NetworkTableContentView.prototype._entryForResource):
428         (WI.NetworkTableContentView.prototype._passFilter):
429         (WI.NetworkTableContentView.prototype._updateSortAndFilteredEntries):
430         (WI.NetworkTableContentView.prototype._updateFilteredEntries):
431         (WI.NetworkTableContentView.prototype._generateTypeFilter):
432         (WI.NetworkTableContentView.prototype._areFilterListsIdentical):
433         (WI.NetworkTableContentView.prototype._typeFilterScopeBarSelectionChanged):
434         (WI.NetworkTableContentView.prototype._tableNameColumnDidChangeWidth):
435         The NetworkTableContentView has a Table and it is the table's data source
436         and delegate. It contains a complete list of entries, and a filtered list
437         of entries, which is the backing list of rows for the table. As entries
438         are created, updated, or filters modified, this generally modifies
439         entries, sorts, filters, and reloads the table. As much as possible it
440         batches operations in the usual layout loop.
441
442 2017-09-24  Joseph Pecoraro  <pecoraro@apple.com>
443
444         Web Inspector: Reduce work during resizing
445         https://bugs.webkit.org/show_bug.cgi?id=177402
446
447         Reviewed by Matt Baker.
448
449         * UserInterface/Views/ConsolePrompt.js:
450         (WI.ConsolePrompt.prototype.layout):
451         In the most common case there is no text so avoid doing work in CodeMirror.
452
453 2017-09-22  Matt Baker  <mattbaker@apple.com>
454
455         Web Inspector: Remove SidebarPanel show/hide and added/removed
456         https://bugs.webkit.org/show_bug.cgi?id=177387
457
458         Reviewed by Devin Rousso.
459
460         * UserInterface/Views/DebuggerTabContentView.js:
461         (WI.DebuggerTabContentView.prototype.showDetailsSidebarPanels):
462         * UserInterface/Views/SearchSidebarPanel.js:
463         (WI.SearchSidebarPanel.prototype.focusSearchField):
464         * UserInterface/Views/Sidebar.js:
465         (WI.Sidebar.prototype.insertSidebarPanel):
466         (WI.Sidebar.prototype.removeSidebarPanel):
467         * UserInterface/Views/SidebarPanel.js:
468         (WI.SidebarPanel.prototype.show): Deleted.
469         (WI.SidebarPanel.prototype.hide): Deleted.
470         (WI.SidebarPanel.prototype.added): Deleted.
471         (WI.SidebarPanel.prototype.removed): Deleted.
472
473 2017-09-22  Matt Baker  <mattbaker@apple.com>
474
475         Web Inspector: View should automatically layout when it becomes attached to the DOM
476         https://bugs.webkit.org/show_bug.cgi?id=177189
477
478         Reviewed by Devin Rousso.
479
480         This guarantees that a layout is always scheduled as soon as a view is
481         attached to the DOM. Now that nearly all views are created lazily, it
482         is safe to make this change even without having a visibility concept in
483         the View class that would prevent layouts for background views.
484
485         * UserInterface/Views/View.js:
486         (WI.View):
487         Remove `this._needsLayoutWhenAttachedToRoot` flag, which is now implicit.
488         This was set if a layout was requested before the view had been attached
489         to the DOM.
490
491         (WI.View.prototype.get element):
492         (WI.View.prototype.get layoutPending):
493         (WI.View.prototype.get parentView):
494         (WI.View.prototype.get subviews):
495         (WI.View.prototype.get isAttached):
496         (WI.View.prototype.insertSubviewBefore):
497         (WI.View.prototype.removeSubview):
498         (WI.View.prototype.removeAllSubviews):
499         (WI.View.prototype.attached):
500         (WI.View.prototype.detached):
501         Hooks for subclasses to define behavior added or removed from the DOM.
502         (WI.View.prototype._didMoveToParent):
503         (WI.View.prototype._didMoveToWindow):
504         (WI.View._scheduleLayoutForView):
505         (WI.View.prototype.didMoveToWindow): Deleted.
506         (WI.View.prototype.didMoveToParent): Deleted.
507         These were only used by View, and have been made private.
508
509 2017-09-22  Nikita Vasilyev  <nvasilyev@apple.com>
510
511         Web Inspector: Styles Redesign: support toggling properties
512         https://bugs.webkit.org/show_bug.cgi?id=176643
513
514         Reviewed by Joseph Pecoraro.
515
516         Add a primitive UI to make CSS property names and values editable. Autocomplete, syntax highlighting,
517         and proper keyboard navigation will be added later.
518
519         Display !important when it's specified. Before this patch !important wasn't shown in the redesigned
520         styles sidebar.
521
522         * UserInterface/Models/CSSProperty.js:
523         (WI.CSSProperty.prototype.update):
524         (WI.CSSProperty.prototype.get name):
525         (WI.CSSProperty.prototype.set name):
526         (WI.CSSProperty.prototype.get value):
527         (WI.CSSProperty.prototype.get rawValue):
528         (WI.CSSProperty.prototype.set rawValue):
529         CSSProperty.prototype.value returns the same value as before. !important remains stripped.
530         CSSProperty.prototype.rawValue returns a raw value from the payload. It may include !important.
531
532         (WI.CSSProperty.prototype._updateStyle):
533         (WI.CSSProperty.prototype._updateOwnerStyleText):
534         (WI.CSSProperty):
535         * UserInterface/Models/DOMNodeStyles.js:
536         (WI.DOMNodeStyles.prototype._parseStylePropertyPayload):
537         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
538         (.spreadsheet-style-declaration-editor :matches(.name, .value):focus):
539         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
540         (WI.SpreadsheetStyleProperty.prototype._update):
541         (WI.SpreadsheetStyleProperty.prototype._handleNameChange):
542         (WI.SpreadsheetStyleProperty.prototype._handleValueChange):
543         (WI.SpreadsheetStyleProperty):
544
545 2017-09-22  Matt Baker  <mattbaker@apple.com>
546
547         Web Inspector: NavigationBar should coalesce consecutive dividers when items are hidden
548         https://bugs.webkit.org/show_bug.cgi?id=177379
549
550         Reviewed by Joseph Pecoraro.
551
552         * UserInterface/Views/NavigationBar.js:
553         (WI.NavigationBar.prototype.layout):
554
555 2017-09-22  Tim Horton  <timothy_horton@apple.com>
556
557         Add env() as an alias of constant()
558         https://bugs.webkit.org/show_bug.cgi?id=177371
559
560         Reviewed by Simon Fraser.
561
562         * UserInterface/Models/CSSKeywordCompletions.js:
563         (WI.CSSKeywordCompletions.forProperty):
564         (WI.CSSKeywordCompletions.forFunction):
565         Add autocomplete support for env().
566
567 2017-09-21  Joseph Pecoraro  <pecoraro@apple.com>
568
569         Web Inspector: Add autocompletion suggestions for CSS functions (constant(), linear-gradient(), etc)
570         https://bugs.webkit.org/show_bug.cgi?id=177264
571
572         Reviewed by Matt Baker.
573
574         * UserInterface/Controllers/CodeMirrorCompletionController.js:
575         (WI.CodeMirrorCompletionController.prototype._generateCSSCompletions):
576         Detect when we are inside of functions and provide completion suggestions
577         for the relevant function.
578
579         * UserInterface/Models/CSSCompletions.js:
580         Syntax highlight "constant()" like we do for "var()".
581
582         * UserInterface/Models/CSSKeywordCompletions.js:
583         (WI.CSSKeywordCompletions.forProperty):
584         Always suggest "constant()" everywhere, like we do for "var()".
585
586         (WI.CSSKeywordCompletions.forFunction):
587         Provide suggestions for some CSS functions.
588
589 2017-09-21  Joseph Pecoraro  <pecoraro@apple.com>
590
591         Web Inspector: Remove support for CSS Regions
592         https://bugs.webkit.org/show_bug.cgi?id=177287
593
594         Reviewed by Matt Baker.
595
596         * UserInterface/Protocol/CSSObserver.js:
597         (WI.CSSObserver.prototype.namedFlowCreated):
598         (WI.CSSObserver.prototype.namedFlowRemoved):
599         (WI.CSSObserver.prototype.regionLayoutUpdated):
600         (WI.CSSObserver.prototype.regionOversetChanged):
601         (WI.CSSObserver.prototype.registeredNamedFlowContentElement):
602         (WI.CSSObserver.prototype.unregisteredNamedFlowContentElement):
603         Leave observer functions in for older backends that will send
604         these messages, but we just ignore them.
605
606         * UserInterface/Base/Main.js:
607         * UserInterface/Controllers/DOMTreeManager.js:
608         (WI.DOMTreeManager):
609         (WI.DOMTreeManager.prototype._unbind):
610         (WI.DOMTreeManager._flowPayloadHashKey): Deleted.
611         (WI.DOMTreeManager.prototype._createContentFlowFromPayload): Deleted.
612         (WI.DOMTreeManager.prototype._updateContentFlowFromPayload): Deleted.
613         (WI.DOMTreeManager.prototype.getNamedFlowCollection.onNamedFlowCollectionAvailable): Deleted.
614         (WI.DOMTreeManager.prototype.getNamedFlowCollection): Deleted.
615         (WI.DOMTreeManager.prototype.namedFlowCreated): Deleted.
616         (WI.DOMTreeManager.prototype.namedFlowRemoved): Deleted.
617         (WI.DOMTreeManager.prototype._sendNamedFlowUpdateEvents): Deleted.
618         (WI.DOMTreeManager.prototype.regionOversetChanged): Deleted.
619         (WI.DOMTreeManager.prototype.registeredNamedFlowContentElement): Deleted.
620         (WI.DOMTreeManager.prototype._removeContentNodeFromFlowIfNeeded): Deleted.
621         (WI.DOMTreeManager.prototype.unregisteredNamedFlowContentElement): Deleted.
622         (WI.DOMTreeManager.prototype._coerceRemoteArrayOfDOMNodes.nodeRequested): Deleted.
623         (WI.DOMTreeManager.prototype._coerceRemoteArrayOfDOMNodes): Deleted.
624         (WI.DOMTreeManager.prototype.getNodeContentFlowInfo.regionNodesAvailable): Deleted.
625         (WI.DOMTreeManager.prototype.getNodeContentFlowInfo.remoteObjectPropertiesAvailable): Deleted.
626         (WI.DOMTreeManager.prototype.getNodeContentFlowInfo.inspectedPage_node_getFlowInfo.getComputedProperty): Deleted.
627         (WI.DOMTreeManager.prototype.getNodeContentFlowInfo.inspectedPage_node_getFlowInfo.getContentFlowName): Deleted.
628         (WI.DOMTreeManager.prototype.getNodeContentFlowInfo): Deleted.
629         * UserInterface/Images/ContentFlow.svg: Removed.
630         * UserInterface/Images/gtk/ContentFlow.svg: Removed.
631         * UserInterface/Main.html:
632         * UserInterface/Models/Collection.js:
633         * UserInterface/Models/ContentFlow.js: Removed.
634         * UserInterface/Models/DOMTree.js:
635         (WI.DOMTree):
636         (WI.DOMTree.prototype.get frame):
637         (WI.DOMTree.prototype._framePageExecutionContextChanged):
638         (WI.DOMTree.prototype.get contentFlowCollection): Deleted.
639         (WI.DOMTree.prototype.requestContentFlowList): Deleted.
640         (WI.DOMTree.prototype._isContentFlowInCurrentDocument): Deleted.
641         (WI.DOMTree.prototype._contentFlowListWasUpdated): Deleted.
642         (WI.DOMTree.prototype._contentFlowWasAdded): Deleted.
643         (WI.DOMTree.prototype._contentFlowWasRemoved): Deleted.
644         * UserInterface/Test.html:
645         * UserInterface/Views/CollectionContentView.js:
646         (WI.CollectionContentView):
647         * UserInterface/Views/ComputedStyleDetailsPanel.css:
648         (.details-section > .content > .group > .row.simple.content-flow-link > .value > span > .icon): Deleted.
649         * UserInterface/Views/ComputedStyleDetailsPanel.js:
650         (WI.ComputedStyleDetailsPanel.prototype.refresh):
651         (WI.ComputedStyleDetailsPanel.prototype.initialLayout):
652         (WI.ComputedStyleDetailsPanel.prototype._handleVariablesSectionCollapsedStateChanged):
653         (WI.ComputedStyleDetailsPanel):
654         (WI.ComputedStyleDetailsPanel.prototype.get regionFlow): Deleted.
655         (WI.ComputedStyleDetailsPanel.prototype.set regionFlow): Deleted.
656         (WI.ComputedStyleDetailsPanel.prototype.get contentFlow): Deleted.
657         (WI.ComputedStyleDetailsPanel.prototype.set contentFlow): Deleted.
658         (WI.ComputedStyleDetailsPanel.prototype.get containerRegions): Deleted.
659         (WI.ComputedStyleDetailsPanel.prototype.set containerRegions): Deleted.
660         (WI.ComputedStyleDetailsPanel.prototype.sizeDidChange): Deleted.
661         (WI.ComputedStyleDetailsPanel.prototype._updateFlowNamesSectionVisibility): Deleted.
662         (WI.ComputedStyleDetailsPanel.prototype._resetFlowDetails): Deleted.
663         (WI.ComputedStyleDetailsPanel.prototype._refreshFlowDetails.contentFlowInfoReady): Deleted.
664         (WI.ComputedStyleDetailsPanel.prototype._refreshFlowDetails): Deleted.
665         (WI.ComputedStyleDetailsPanel.prototype._goToRegionFlowArrowWasClicked): Deleted.
666         (WI.ComputedStyleDetailsPanel.prototype._goToContentFlowArrowWasClicked): Deleted.
667         * UserInterface/Views/ContentFlowDOMTreeContentView.js: Removed.
668         * UserInterface/Views/ContentFlowIcon.css: Removed.
669         * UserInterface/Views/ContentFlowTreeElement.js: Removed.
670         * UserInterface/Views/ContentView.js:
671         (WI.ContentView.createFromRepresentedObject):
672         (WI.ContentView.isViewable):
673         * UserInterface/Views/FrameTreeElement.js:
674         (WI.FrameTreeElement.prototype.onpopulate):
675         (WI.FrameTreeElement.prototype.onexpand):
676         (WI.FrameTreeElement.prototype._childContentFlowWasAdded): Deleted.
677         (WI.FrameTreeElement.prototype._childContentFlowWasRemoved): Deleted.
678         (WI.FrameTreeElement.prototype._rootDOMNodeInvalidated): Deleted.
679         * UserInterface/Views/ResourceSidebarPanel.js:
680         (WI.ResourceSidebarPanel.prototype._treeSelectionDidChange):
681         * UserInterface/Views/ResourcesTabContentView.js:
682         (WI.ResourcesTabContentView):
683         (WI.ResourcesTabContentView.prototype.canShowRepresentedObject):
684
685 2017-09-21  Ross Kirsling  <ross.kirsling@sony.com>
686
687         Web Inspector: Add details sidebar to Layers tab.
688         https://bugs.webkit.org/show_bug.cgi?id=177115
689
690         Reviewed by Devin Rousso.
691
692         * Localizations/en.lproj/localizedStrings.js:
693         * UserInterface/Main.html:
694         * UserInterface/Views/LayerDetailsSidebarPanel.css: Added.
695         * UserInterface/Views/LayerDetailsSidebarPanel.js: Added.
696         New files and strings for sidebar.
697
698         * UserInterface/Base/Utilities.js:
699         Add global identifier for "×" character.
700         
701         * UserInterface/Models/Layer.js: Added.
702         Add a model class for layers so that we can instanceof-check them.
703
704         * UserInterface/Controllers/LayerTreeManager.js:
705         (WI.LayerTreeManager.prototype.layersForNode):
706         Utilize model class WI.Layer.
707
708         * UserInterface/Views/Layers3DContentView.js:
709         (WI.Layers3DContentView):
710         (WI.Layers3DContentView.prototype.get supplementalRepresentedObjects):
711         (WI.Layers3DContentView.prototype.layout):
712         (WI.Layers3DContentView.prototype._addLayer):
713         Pass layer data to sidebar and utilize model class WI.Layer.
714
715         * UserInterface/Views/LayersTabContentView.js:
716         (WI.LayersTabContentView):
717         Attach details sidebar.
718
719 2017-09-21  Brian Burg  <bburg@apple.com>
720
721         Web Inspector: keyboard shortcut for "Reload page from origin" doesn't match Safari, and doesn't work
722         https://bugs.webkit.org/show_bug.cgi?id=177010
723         <rdar://problem/33134548>
724
725         Reviewed by Joseph Pecoraro.
726
727         I seem to have broken reload from origin via Web Inspector in a previous
728         patch, because the parameter is 'ignoreCache' instead of 'shouldIgnoreCache'.
729
730         * Localizations/en.lproj/localizedStrings.js:
731         Modernize tooltip text.
732
733         * UserInterface/Base/Main.js:
734         (WI.contentLoaded):
735         Disambiguate two locals with the same name. Modernize the tooltip.
736         Make the shortcut Cmd-Opt-R to match Safari. Fix wrong parameter usage.
737
738         * UserInterface/Test/FrontendTestHarness.js:
739         (FrontendTestHarness.prototype.reloadPage):
740         Fix wrong parameter.
741
742 2017-09-19  Joseph Pecoraro  <pecoraro@apple.com>
743
744         Web Inspector: Adopt named groups in complex regexes
745         https://bugs.webkit.org/show_bug.cgi?id=177117
746
747         Reviewed by Matt Baker.
748
749         * UserInterface/Base/URLUtilities.js:
750         (parseSecurityOrigin):
751         (parseDataURL):
752         (parseURL):
753         * UserInterface/Models/Color.js:
754         (WI.Color.fromString):
755
756 2017-09-19  Joseph Pecoraro  <pecoraro@apple.com>
757
758         REGRESSION(r214494): Web Inspector: Ignore cache button does not work in Network tab
759         https://bugs.webkit.org/show_bug.cgi?id=177114
760         <rdar://problem/34505265>
761
762         Reviewed by Brian Burg.
763
764         * UserInterface/Base/Main.js:
765         (WI.loaded):
766         We need to register the settings change handler regardless of what the
767         initial value of the setting is.
768
769 2017-09-18  Matt Baker  <mattbaker@apple.com>
770
771         Web Inspector: RemoteObject.resolveNode should return a Promise
772         https://bugs.webkit.org/show_bug.cgi?id=177042
773
774         Reviewed by Joseph Pecoraro.
775
776         Update RemoteObject.resolveNode to return a promise instead of taking a
777         callback. If the promise is fulfilled, `remoteObject` will be non-null.
778
779         * UserInterface/Controllers/DOMTreeManager.js:
780         (WI.DOMTreeManager.prototype.inspectNodeObject.nodeAvailable):
781         (WI.DOMTreeManager.prototype.inspectNodeObject):
782         (WI.DOMTreeManager.prototype.getNodeContentFlowInfo.domNodeResolved): Deleted.
783
784         * UserInterface/Models/DOMNode.js:
785         (WI.DOMNode.prototype.toggleClass.WI.RemoteObject.resolveNode.then):
786         (WI.DOMNode.prototype.toggleClass):
787         (WI.DOMNode.prototype.scrollIntoView.WI.RemoteObject.resolveNode.then):
788         (WI.DOMNode.prototype.scrollIntoView):
789         (WI.DOMNode.prototype.toggleClass.resolvedNode.inspectedPage_node_toggleClass): Deleted.
790         (WI.DOMNode.prototype.toggleClass.resolvedNode): Deleted.
791         (WI.DOMNode.prototype.scrollIntoView.resolvedNode.inspectedPage_node_scrollIntoView): Deleted.
792         (WI.DOMNode.prototype.scrollIntoView.resolvedNode): Deleted.
793
794         * UserInterface/Protocol/RemoteObject.js:
795         (WI.RemoteObject.resolveNode):
796
797         * UserInterface/Views/BoxModelDetailsSectionRow.js:
798         (WI.BoxModelDetailsSectionRow.prototype._applyUserInput.WI.RemoteObject.resolveNode.then):
799         (WI.BoxModelDetailsSectionRow.prototype._applyUserInput):
800         (WI.BoxModelDetailsSectionRow.prototype._applyUserInput.resolvedNode.toggleInlineStyleProperty): Deleted.
801         (WI.BoxModelDetailsSectionRow.prototype._applyUserInput.resolvedNode.didToggle): Deleted.
802         (WI.BoxModelDetailsSectionRow.prototype._applyUserInput.resolvedNode): Deleted.
803         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
804
805         * UserInterface/Views/ContextMenuUtilities.js:
806         (WI.appendContextMenuItemsForDOMNode):
807
808         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
809         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshProperties.nodeResolved.inspectedPage_node_collectPrototypes): Deleted.
810         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshProperties.nodeResolved): Deleted.
811         (WI.DOMNodeDetailsSidebarPanel.prototype._refreshProperties.nodePrototypesReady): Deleted.
812
813         * UserInterface/Views/DOMTreeElement.js:
814         (WI.DOMTreeElement.prototype._createTooltipForNode.WI.RemoteObject.resolveNode.then):
815         (WI.DOMTreeElement.prototype._createTooltipForNode):
816         (WI.DOMTreeElement.prototype._createTooltipForNode.resolvedNode.dimensions): Deleted.
817         (WI.DOMTreeElement.prototype._createTooltipForNode.resolvedNode): Deleted.
818
819         * UserInterface/Views/DOMTreeOutline.js:
820         (WI.DOMTreeOutline.prototype._hideElement.injectStyleAndToggleClass):
821         (WI.DOMTreeOutline.prototype._hideElement):
822         (WI.DOMTreeOutline):
823         (WI.DOMTreeOutline.prototype._hideElement.resolvedNode.injectStyleAndToggleClass): Deleted.
824         (WI.DOMTreeOutline.prototype._hideElement.resolvedNode): Deleted.
825
826 2017-09-18  Brian Burg  <bburg@apple.com>
827
828         Web Inspector: introduce an AppController class and shared instance of it
829         https://bugs.webkit.org/show_bug.cgi?id=177024
830
831         Reviewed by Matt Baker.
832
833         WebInspectorUI currently has an app controller singleton that's distributed
834         among many properties on the WI object, which also serves as a namespace for
835         classes, enums, and other frontend objects. The singleton should be a proper
836         class so that we can think more easily about what state is global.
837
838         In the process of moving pieces of Main.js into AppController, I intend to move
839         most UI related code into a view controller class for the top level view.
840         AppController really shouldn't be doing anything to the view hierarchy or DOM.
841         It is yet to be determined how responsibility for global DOM events, such as
842         those for keyboard shortcuts, will be handled.
843
844         This larger refactoring project will let us more easily do things like connect
845         to multiple debuggables in the same Inspector instance, and switch between views
846         of different debuggable targets. Even if this never comes to pass, the code will
847         be a lot easier to reason about and maintain in the future.
848
849         For the first patch, introduce {AppController, TestAppController} <: AppControllerBase.
850         Shared code goes in the base class. In the Main.html and Test.html files, first
851         construct the AppController and then call .initialize() to avoid cyclic dependencies
852         on the global singleton WI.sharedApp.
853
854         * UserInterface/Main.html:
855         * UserInterface/Test.html:
856         * UserInterface/Test/Test.js:
857         (WI.loaded):
858         * UserInterface/Base/Main.js:
859         (WI.loaded):
860         Move some shared code out of here into AppControllerBase.constructor.
861         Eventually WI.loaded should not exist, and its code will move elsewhere.
862
863         (WI.contentLoaded):
864         Adopt global reference.
865
866         * UserInterface/Controllers/AppControllerBase.js: Copied from Source/WebInspectorUI/UserInterface/Protocol/MainTarget.js.
867         (WI.AppControllerBase):
868         (WI.AppControllerBase.prototype.get hasExtraDomains):
869         (WI.AppControllerBase.prototype.get debuggableType):
870         (WI.AppControllerBase.prototype.initialize):
871
872         * UserInterface/Controllers/AppController.js: New.
873         (WI.AppController):
874         (WI.AppController.prototype.get hasExtraDomains):
875         (WI.AppController.prototype.get debuggableType):
876         (WI.AppController.prototype.activateExtraDomains):
877
878         * UserInterface/Test/TestAppController.js: New.
879         (WI.TestAppController):
880         (WI.TestAppController.prototype.get hasExtraDomains):
881         (WI.TestAppController.prototype.get debuggableType):
882
883         * UserInterface/Controllers/TimelineManager.js:
884         (WI.TimelineManager.defaultTimelineTypes):
885         (WI.TimelineManager.availableTimelineTypes):
886         (WI.TimelineManager.prototype.scriptProfilerProgrammaticCaptureStarted):
887         (WI.TimelineManager.prototype.scriptProfilerProgrammaticCaptureStopped):
888         (WI.TimelineManager.prototype.scriptProfilerTrackingCompleted):
889         * UserInterface/Models/TimelineRecording.js:
890         (WI.TimelineRecording.sourceCodeTimelinesSupported):
891         * UserInterface/Protocol/InspectorObserver.js:
892         (WI.InspectorObserver.prototype.inspect):
893         (WI.InspectorObserver.prototype.activateExtraDomains):
894         (WI.InspectorObserver):
895         * UserInterface/Protocol/MainTarget.js:
896         (WI.MainTarget):
897         (WI.MainTarget.prototype.get displayName):
898         * UserInterface/Views/ResourceSidebarPanel.js:
899         (WI.ResourceSidebarPanel):
900         (WI.ResourceSidebarPanel.prototype.initialLayout):
901         (WI.ResourceSidebarPanel.prototype._addScript):
902         (WI.ResourceSidebarPanel.prototype._extraDomainsActivated):
903         * UserInterface/Views/Toolbar.js:
904         Use WI.sharedApp.{debuggableType, hasExtraDomains}.
905
906 2017-09-18  Matt Baker  <mattbaker@apple.com>
907
908         Web Inspector: console.assert messages shouldn't end in an exclamation point
909         https://bugs.webkit.org/show_bug.cgi?id=177054
910
911         Reviewed by Joseph Pecoraro.
912
913         * UserInterface/Base/EventListener.js:
914         * UserInterface/Base/EventListenerSet.js:
915         (WI.EventListenerSet.prototype.register):
916         Drive-by: make assertions the same in both.
917
918         * UserInterface/Views/LayoutTimelineView.js:
919         (WI.LayoutTimelineView.prototype._processPendingRecords):
920
921         * UserInterface/Views/Resizer.js:
922         (WI.Resizer.prototype._currentPosition):
923
924 2017-09-18  Devin Rousso  <webkit@devinrousso.com>
925
926         Web Inspector: REGRESSION(r221901): Single frame recordings don't reset the recording navigation item
927         https://bugs.webkit.org/show_bug.cgi?id=176893
928
929         Reviewed by Matt Baker.
930
931         * UserInterface/Controllers/CanvasManager.js:
932         (WI.CanvasManager.prototype.recordingFinished):
933         Set the `_recordingCanvas` to null whenever a recording has finished and been sent to the
934         frontend. It is also necessary to do this inside `stopRecording`, as it is possible for the
935         user to start and stop a recording before any actions are recorded, meaning that no
936         recording would be sent to the frontend and this function will never get called.
937
938 2017-09-17  Nikita Vasilyev  <nvasilyev@apple.com>
939
940         Web Inspector: Styles Redesign: support toggling properties
941         https://bugs.webkit.org/show_bug.cgi?id=176643
942
943         Reviewed by Matt Baker.
944
945         Add checkboxes to toggle (comment/uncomment) CSS properties.
946
947         * UserInterface/Base/Utilities.js:
948         (String.prototype.get lineCount):
949         (String.prototype.get lastLine):
950         Add string methods that are used by WI.CSSProperty.prototype._updateOwnerStyleText.
951
952         * UserInterface/Models/CSSProperty.js:
953         (WI.CSSProperty.prototype.commentOut):
954         (WI.CSSProperty.prototype.set text):
955         (WI.CSSProperty.prototype.get editable):
956         (WI.CSSProperty.prototype._updateOwnerStyleText):
957         Add methods necessary for property toggling.
958
959         * UserInterface/Models/CSSStyleDeclaration.js:
960         (WI.CSSStyleDeclaration):
961         (WI.CSSStyleDeclaration.prototype.get allVisibleProperties):
962         Add a getter that is used by SpreadsheetCSSStyleDeclarationEditor.prototype._propertiesToRender.
963
964         (WI.CSSStyleDeclaration.prototype.get visibleProperties):
965         * UserInterface/Models/TextRange.js:
966         (WI.TextRange.prototype.clone):
967         (WI.TextRange.prototype.cloneAndModify):
968         (WI.TextRange.prototype.relativeTo):
969         Add methods that are used by WI.CSSProperty.prototype._updateOwnerStyleText.
970
971         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css:
972         (.spreadsheet-style-declaration-editor):
973         (.spreadsheet-style-declaration-editor .property-toggle):
974         (.spreadsheet-css-declaration:matches(:hover, :focus) .property-toggle,):
975         (.spreadsheet-style-declaration-editor .property.disabled,):
976         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js:
977         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
978         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.set style):
979         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.get _propertiesToRender):
980         (WI.SpreadsheetCSSStyleDeclarationEditor):
981         (WI.SpreadsheetStyleProperty):
982         (WI.SpreadsheetStyleProperty.prototype.get element):
983         (WI.SpreadsheetStyleProperty.prototype._update):
984         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
985         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
986         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):
987         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
988         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.refresh):
989         (WI.SpreadsheetRulesStyleDetailsPanel):
990         * UserInterface/Views/SyntaxHighlightingDefaultTheme.css:
991         (.cm-s-default .cm-comment,):
992         * UserInterface/Views/Variables.css:
993         (:root):
994         Make comment color a CSS variable.
995
996 2017-09-15  Devin Rousso  <webkit@devinrousso.com>
997
998         Web Inspector: REGRESSION(r222057): recording state doesn't update when changing actions
999         https://bugs.webkit.org/show_bug.cgi?id=176988
1000
1001         Reviewed by Matt Baker.
1002
1003         Replace `updateActionIndex` with `updateAction`, where the currently selected RecordingAction
1004         is passed to the DetailsSidebarPanel. Also remove the call to `this._recording.actions` in
1005         order to ensure that all logic performed by both DetailsSidebarPanel is synchronous.
1006
1007         * Localizations/en.lproj/localizedStrings.js:
1008
1009         * UserInterface/Views/RecordingTabContentView.js:
1010         (WI.RecordingTabContentView.prototype._updateActionIndex):
1011
1012         * UserInterface/Views/RecordingContentView.js:
1013         (WI.RecordingContentView.prototype.async._generateContentCanvas2D):
1014         (WI.RecordingContentView.prototype.async._generateContentCanvasWebGL):
1015
1016         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
1017         (WI.RecordingStateDetailsSidebarPanel):
1018         (WI.RecordingStateDetailsSidebarPanel.prototype.set recording):
1019         (WI.RecordingStateDetailsSidebarPanel.prototype.updateAction):
1020         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
1021         (WI.RecordingStateDetailsSidebarPanel.prototype.updateActionIndex): Deleted.
1022
1023         * UserInterface/Views/RecordingTraceDetailsSidebarPanel.js:
1024         (WI.RecordingTraceDetailsSidebarPanel):
1025         (WI.RecordingTraceDetailsSidebarPanel.prototype.set recording):
1026         (WI.RecordingTraceDetailsSidebarPanel.prototype.updateAction):
1027         (WI.RecordingTraceDetailsSidebarPanel.prototype.updateActionIndex): Deleted.
1028
1029 2017-09-15  Matt Baker  <mattbaker@apple.com>
1030
1031         Web Inspector: Canvas: recording parameters that include colors should show an InlineSwatch (2D canvas)
1032         https://bugs.webkit.org/show_bug.cgi?id=176822
1033         <rdar://problem/34402170>
1034
1035         Reviewed by Devin Rousso.
1036
1037         Show inline swatches in the canvas recording action and state sidebars.
1038
1039         * UserInterface/Models/Color.js:
1040         Added helpers for dealing with CMYK and normalized RGB. The latter is
1041         for RGB components scaled to the range [0, 1]. Also improved handling
1042         for 8-bit channel values.
1043         (WI.Color.rgb2hsv):
1044         (WI.Color.cmyk2rgb):
1045         (WI.Color.normalized2rgb):
1046         (WI.Color._eightBitChannel):
1047         (WI.Color.prototype._toRGBString):
1048         (WI.Color.prototype._toRGBAString):
1049         (WI.Color.prototype._componentToHexValue):
1050         (WI.Color.prototype._rgbToHSL):
1051         (WI.Color.prototype._componentToNumber): Deleted.
1052         Replaced by _eightBitChannel.
1053
1054         * UserInterface/Models/RecordingAction.js:
1055         (WI.RecordingAction):
1056         (WI.RecordingAction.prototype.getColorParameters):
1057         Get a subset of parameters that describe a color. This can be an array
1058         containing one value (e.g. fillStyle), or multiple values, as is the
1059         case with non-standard API functions that describe color using multiple
1060         parameters (e.g. setFillColor).
1061
1062         * UserInterface/Views/InlineSwatch.css:
1063         (.inline-swatch:not(.read-only):hover > span):
1064         (.inline-swatch:hover > span): Deleted.
1065         * UserInterface/Views/InlineSwatch.js:
1066         (WI.InlineSwatch):
1067         Read-only colors shouldn't show a context menu or hover effects.
1068
1069         * UserInterface/Views/RecordingActionTreeElement.css:
1070         (.tree-outline:matches(:focus, .force-focus) .item.action > .titles .parameters > .inline-swatch):
1071
1072         * UserInterface/Views/RecordingActionTreeElement.js:
1073         (WI.RecordingActionTreeElement._generateDOM.createParameterElement):
1074         (WI.RecordingActionTreeElement._generateDOM):
1075         (WI.RecordingActionTreeElement._createSwatchForColorParameters):
1076
1077         * UserInterface/Views/RecordingStateDetailsSidebarPanel.css:
1078         (.sidebar > .panel.details.recording-state > .content > .data-grid .inline-swatch):
1079
1080         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
1081         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D.isColorProperty):
1082         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D.createInlineSwatch):
1083         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
1084         (WI.RecordingStateDetailsSidebarPanel):
1085
1086 2017-09-14  Joseph Pecoraro  <pecoraro@apple.com>
1087
1088         Unreviewed rollout r222036.
1089         
1090         The LayoutTests added with this change is flaky.
1091
1092         This left in the Test.js, Test.html, InspectorBackend changes
1093         needed by later patches. They are independent of the flakey test.
1094
1095         Reverted changeset
1096         Web Inspector: Timeline should show when events preventDefault() was called on an event or not
1097         https://bugs.webkit.org/show_bug.cgi?id=176824
1098         http://trac.webkit.org/changeset/222036
1099
1100 2017-09-14  Devin Rousso  <webkit@devinrousso.com>
1101
1102         Web Inspector: make recording swizzle async
1103         https://bugs.webkit.org/show_bug.cgi?id=176936
1104
1105         Reviewed by Joseph Pecoraro.
1106
1107         Move all swizzle functions, and all logic that depends on swizzled values, to async
1108         functions so that await can be used to pause execution while objects load. This was
1109         necessary primarily for swizzling Image values, as the Image is not able to be used (such as
1110         for creating a CanvasPattern) until its "load" event has fired. Any callers of a Recording's
1111         actions getter must now adapt to working with a promise that will resolve once all swizzling
1112         has finished across all actions within that recording.
1113
1114         * .eslintrc:
1115
1116         * UserInterface/Models/Recording.js:
1117         (WI.Recording):
1118         (WI.Recording.prototype.async swizzle):
1119         (WI.Recording.prototype.swizzle): Deleted.
1120         Drive-by: currently, no data is added to the JSON for WebGL objects, so don't try to swizzle
1121         them and return the placeholder value (0) instead.
1122
1123         * UserInterface/Models/RecordingAction.js:
1124         (WI.RecordingAction):
1125         (WI.RecordingAction.prototype.swizzle):
1126         (WI.RecordingAction.prototype.toJSON):
1127         (WI.RecordingAction.prototype.async _swizzle.swizzleParameter):
1128         (WI.RecordingAction.prototype.async _swizzle.async swizzleCallFrame):
1129         (WI.RecordingAction.prototype.async _swizzle):
1130
1131         * UserInterface/Models/RecordingInitialStateAction.js:
1132         (WI.RecordingInitialStateAction):
1133
1134         * UserInterface/Views/RecordingContentView.js:
1135         (WI.RecordingContentView.prototype.updateActionIndex):
1136         (WI.RecordingContentView.prototype.async _generateContentCanvas2D):
1137         (WI.RecordingContentView.prototype.async _generateContentCanvasWebGL):
1138         (WI.RecordingContentView.prototype._updateCanvasPath):
1139         (WI.RecordingContentView.prototype._generateContentCanvas2D): Deleted.
1140         (WI.RecordingContentView.prototype._generateContentCanvasWebGL): Deleted.
1141
1142         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
1143         (WI.RecordingNavigationSidebarPanel.prototype.set recording):
1144         (WI.RecordingNavigationSidebarPanel.prototype.updateActionIndex):
1145
1146         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
1147         (WI.RecordingStateDetailsSidebarPanel):
1148         (WI.RecordingStateDetailsSidebarPanel.prototype.updateActionIndex):
1149         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
1150
1151         * UserInterface/Views/RecordingTabContentView.js:
1152         (WI.RecordingTabContentView.prototype.showRepresentedObject):
1153
1154         * UserInterface/Views/RecordingTraceDetailsSidebarPanel.js:
1155         (WI.RecordingTraceDetailsSidebarPanel):
1156         (WI.RecordingTraceDetailsSidebarPanel.prototype.updateActionIndex):
1157
1158 2017-09-14  Matt Baker  <mattbaker@apple.com>
1159
1160         Web Inspector: Color created from an RGB/HSL triplet returns bad component arrays
1161         https://bugs.webkit.org/show_bug.cgi?id=176811
1162         <rdar://problem/34397529>
1163
1164         Reviewed by Joseph Pecoraro.
1165
1166         A Color constructed from a format and RGB/HSL triplet should set its
1167         alpha component to 1 instead of leaving it undefined. Color properties
1168         and member functions expect the components array to have a length of four.
1169
1170         * UserInterface/Models/Color.js:
1171         (WI.Color):
1172
1173 2017-09-14  Joseph Pecoraro  <pecoraro@apple.com>
1174
1175         Layout test inspector/debugger/breakpoints/resolved-dump-all-pause-locations.html is flaky.
1176         https://bugs.webkit.org/show_bug.cgi?id=176952
1177
1178         Reviewed by Matt Baker.
1179
1180         * UserInterface/Protocol/InspectorBackend.js:
1181         (InspectorBackend.Agent.prototype.dispatchEvent):
1182         Include the event name since that may be useful in understanding what happened.
1183
1184         * UserInterface/Test.html:
1185         * UserInterface/Test/Test.js:
1186         (WI.loaded):
1187         Register a MemoryObserver and include potentially necessary Model objects
1188         for the Memory domain.
1189
1190 2017-09-14  Joseph Pecoraro  <pecoraro@apple.com>
1191
1192         Web Inspector: Timeline should show when events preventDefault() was called on an event or not
1193         https://bugs.webkit.org/show_bug.cgi?id=176824
1194         <rdar://problem/34290931>
1195
1196         Reviewed by Devin Rousso.
1197
1198         * Localizations/en.lproj/localizedStrings.js:
1199         New string.
1200
1201         * UserInterface/Controllers/TimelineManager.js:
1202         (WI.TimelineManager.prototype._processRecord):
1203         Include the whole data object as extra details.
1204
1205         * UserInterface/Models/ScriptTimelineRecord.js:
1206         (WI.ScriptTimelineRecord):
1207         (WI.ScriptTimelineRecord.prototype.get extraDetails):
1208         Wholesale copy of the extra data instead of just a single property.
1209
1210         * UserInterface/Views/ScriptDetailsTimelineView.js:
1211         (WI.ScriptDetailsTimelineView):
1212         Give the name column more initial space, there is still extra space
1213         after this adjustment but name is comfortably larger (and the most
1214         likely to be expanded).
1215
1216         * UserInterface/Views/ScriptTimelineDataGridNode.js:
1217         (WI.ScriptTimelineDataGridNode.prototype.get subtitle):
1218         Include "default prevented" as the event's subtitle if it was prevented.
1219
1220         * UserInterface/Protocol/InspectorBackend.js:
1221         (InspectorBackend.Agent.prototype.dispatchEvent):
1222         (InspectorBackend.Agent):
1223         * UserInterface/Test.html:
1224         * UserInterface/Test/Test.js:
1225         (WI.loaded):
1226         Add the ScriptProfilerObserver to tests since it is on by default for Timelines.
1227
1228 2017-09-14  Ryan Haddad  <ryanhaddad@apple.com>
1229
1230         Unreviewed, rolling out r222015.
1231
1232         The LayoutTests added with this change are flaky.
1233
1234         Reverted changeset:
1235
1236         "Web Inspector: Timeline should show when events
1237         preventDefault() was called on an event or not"
1238         https://bugs.webkit.org/show_bug.cgi?id=176824
1239         http://trac.webkit.org/changeset/222015
1240
1241 2017-09-14  Joseph Pecoraro  <pecoraro@apple.com>
1242
1243         Web Inspector: Timeline should show when events preventDefault() was called on an event or not
1244         https://bugs.webkit.org/show_bug.cgi?id=176824
1245         <rdar://problem/34290931>
1246
1247         Reviewed by Devin Rousso.
1248
1249         * Localizations/en.lproj/localizedStrings.js:
1250         New string.
1251
1252         * UserInterface/Controllers/TimelineManager.js:
1253         (WI.TimelineManager.prototype._processRecord):
1254         Include the whole data object as extra details.
1255
1256         * UserInterface/Models/ScriptTimelineRecord.js:
1257         (WI.ScriptTimelineRecord):
1258         (WI.ScriptTimelineRecord.prototype.get extraDetails):
1259         Wholesale copy of the extra data instead of just a single property.
1260
1261         * UserInterface/Views/ScriptDetailsTimelineView.js:
1262         (WI.ScriptDetailsTimelineView):
1263         Give the name column more initial space, there is still extra space
1264         after this adjustment but name is comfortably larger (and the most
1265         likely to be expanded).
1266
1267         * UserInterface/Views/ScriptTimelineDataGridNode.js:
1268         (WI.ScriptTimelineDataGridNode.prototype.get subtitle):
1269         Include "default prevented" as the event's subtitle if it was prevented.
1270
1271         * UserInterface/Protocol/InspectorBackend.js:
1272         (InspectorBackend.Agent.prototype.dispatchEvent):
1273         (InspectorBackend.Agent):
1274         * UserInterface/Test.html:
1275         * UserInterface/Test/Test.js:
1276         (WI.loaded):
1277         Add the ScriptProfilerObserver to tests since it is on by default for Timelines.
1278
1279 2017-09-13  Devin Rousso  <webkit@devinrousso.com>
1280
1281         Web Inspector: allow recordings to be saved via ⌘-S in the Recording tab
1282         https://bugs.webkit.org/show_bug.cgi?id=175284
1283
1284         Reviewed by Matt Baker.
1285
1286         * UserInterface/Views/RecordingContentView.js:
1287         (WI.RecordingContentView.prototype.get supportsSave):
1288         (WI.RecordingContentView.prototype.get saveData):
1289
1290         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
1291         (WI.RecordingNavigationSidebarPanel.prototype._exportNavigationItemClicked):
1292         Use the current content view's saveData when exporting.
1293
1294 2017-09-13  Devin Rousso  <webkit@devinrousso.com>
1295
1296         Web Inspector: Event Listeners section does not update when listeners are added/removed
1297         https://bugs.webkit.org/show_bug.cgi?id=170570
1298         <rdar://problem/31501645>
1299
1300         Reviewed by Joseph Pecoraro.
1301
1302         * UserInterface/Protocol/DOMObserver.js:
1303         (WI.DOMObserver.prototype.didAddEventListener):
1304         (WI.DOMObserver.prototype.willRemoveEventListener):
1305
1306         * UserInterface/Controllers/DOMTreeManager.js:
1307         (WI.DOMTreeManager.prototype.didAddEventListener):
1308         (WI.DOMTreeManager.prototype.willRemoveEventListener):
1309
1310         * UserInterface/Models/DOMNode.js:
1311         Add "EventListenersChanged" event. Fired when an event listener is added or removed.
1312
1313         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
1314         (WI.DOMNodeDetailsSidebarPanel.prototype.addEventListeners):
1315         (WI.DOMNodeDetailsSidebarPanel.prototype.removeEventListeners):
1316         (WI.DOMNodeDetailsSidebarPanel.prototype._eventListenersChanged):
1317         Refresh the event listeners section whenever a node's event listeners change.
1318
1319 2017-09-13  Joseph Pecoraro  <pecoraro@apple.com>
1320
1321         Web Inspector: Sort by size issues with Cookies and ApplicationCache DataGrids
1322         https://bugs.webkit.org/show_bug.cgi?id=176879
1323         <rdar://problem/34237096>
1324
1325         Reviewed by Matt Baker.
1326
1327         * UserInterface/Views/ApplicationCacheFrameContentView.js:
1328         (WI.ApplicationCacheFrameContentView.prototype._sortDataGrid):
1329         (WI.ApplicationCacheFrameContentView.prototype._populateDataGrid):
1330         This uses very dumb DataGridNodes with a pure data object. In that
1331         object `size` is a bytes string not a number. Include the number size
1332         in this data object that can be used during sorting.
1333
1334         * UserInterface/Views/CookieStorageContentView.js:
1335         (WI.CookieStorageContentView.prototype._rebuildTable):
1336         Simplify creation. Also don't reset sort options. Note that here the
1337         DataGridNodes have access to the Cookie object and can already sort size
1338         using the cookie's size (a number) and not the data's size (string).
1339
1340         * UserInterface/Views/DataGrid.js:
1341         (WI.DataGrid.prototype.sortNodes):
1342         (WI.DataGrid.prototype._sortNodesCallback):
1343         If sortNodes was called twice, it would defer the sort and actually
1344         do the sort with the first comparator and not the latest, preferred
1345         comparator. Make it use the latest comparator.
1346
1347 2017-09-13  Nikita Vasilyev  <nvasilyev@apple.com>
1348
1349         Web Inspector: Styles Redesign: display @media section headers
1350         https://bugs.webkit.org/show_bug.cgi?id=176289
1351         <rdar://problem/34228389>
1352
1353         Reviewed by Devin Rousso.
1354
1355         Prepend CSS media query selectors to every matching rule.
1356
1357         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css:
1358         (.spreadsheet-css-declaration .media-label):
1359         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js:
1360         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):
1361         (WI.SpreadsheetCSSStyleDeclarationSection.prototype._createMediaHeader):
1362         Don't localize "@media" since it's CSS code.
1363         Don't display "all" or "screen" media query selectors. One of the goals of the
1364         Styles sidebar redesign is to fit more data.
1365
1366 2017-09-13  Nikita Vasilyev  <nvasilyev@apple.com>
1367
1368         Web Inspector: Frontend should be made to expect and handle disabled properties
1369         https://bugs.webkit.org/show_bug.cgi?id=166787
1370         <rdar://problem/34379593>
1371
1372         Reviewed by Joseph Pecoraro.
1373
1374         This change introduces WI.CSSStyleDeclaration.prototype.allProperties getter,
1375         that includes both enabled and disabled (commented out) CSS properties.
1376
1377         The existing WI.CSSStyleDeclaration.prototype.properties getter only includes enabled CSS properties,
1378         same as before the backend change.
1379
1380         There is no behaviour change in the current styles sidebar. The new redesigned styles sidebar will
1381         use disabled properties and display them as commented out.
1382
1383         * UserInterface/Models/CSSProperty.js:
1384         (WI.CSSProperty.prototype.get attached):
1385         Rename `enabled` to `attached`, as it didn't correspond to `_enabled` property. Attached means that the property
1386         is enabled and has a ownerStyle with a set index (unless it's a computed style, where index is not applicable).
1387
1388         (WI.CSSProperty.prototype.get enabled):
1389         * UserInterface/Models/CSSStyleDeclaration.js:
1390         (WI.CSSStyleDeclaration.prototype.get allProperties):
1391         Add allProperties getter that will be used in the new styles sidebar.
1392
1393         * UserInterface/Models/DOMNodeStyles.js:
1394         (WI.DOMNodeStyles.prototype._markOverriddenProperties):
1395         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
1396         (WI.CSSStyleDeclarationTextEditor.prototype.highlightProperty.propertiesMatch):
1397         Rename "enabled" to "attached" without any behavior change.
1398
1399 2017-09-13  Joseph Pecoraro  <pecoraro@apple.com>
1400
1401         Web Inspector: Escape in global search field should clear it
1402         https://bugs.webkit.org/show_bug.cgi?id=176764
1403
1404         Reviewed by Timothy Hatcher.
1405
1406         * UserInterface/Views/QuickConsole.js:
1407         (WI.QuickConsole.prototype._toggleOrFocus):
1408         Don't implicitly prevent default. So if we didn't cause an action we
1409         can let the default system action happen.
1410
1411         * UserInterface/Views/SearchBar.js:
1412         (WI.SearchBar):
1413         Remove unused keyboard shortcuts.
1414
1415 2017-09-12  Joseph Pecoraro  <pecoraro@apple.com>
1416
1417         Web Inspector: Add Experimental setting for new Network tab
1418         https://bugs.webkit.org/show_bug.cgi?id=176750
1419
1420         Reviewed by Matt Baker.
1421
1422         * Localizations/en.lproj/localizedStrings.js:
1423         * UserInterface/Main.html:
1424         * UserInterface/Base/Main.js:
1425         (WI.contentLoaded):
1426         New files and strings.
1427
1428         * UserInterface/Base/Setting.js:
1429         New experimental setting.
1430
1431         * UserInterface/Views/LegacyNetworkTabContentView.js:
1432         (WI.LegacyNetworkTabContentView.isTabAllowed):
1433         Legacy tab availability depends on the setting.
1434
1435         * UserInterface/Views/NetworkTabContentView.js:
1436         (WI.NetworkTabContentView):
1437         (WI.NetworkTabContentView.isTabAllowed):
1438         (WI.NetworkTabContentView.prototype.get contentBrowser):
1439         (WI.NetworkTabContentView.prototype.get type):
1440         (WI.NetworkTabContentView.prototype.canShowRepresentedObject):
1441         (WI.NetworkTabContentView.prototype.get supportsSplitContentBrowser):
1442         Modern network tab. Only difference right now is it allows the split console.
1443
1444         * UserInterface/Views/NetworkTableContentView.js: Added.
1445         (WI.NetworkTableContentView):
1446         (WI.NetworkTableContentView.prototype.get selectionPathComponents):
1447         (WI.NetworkTableContentView.prototype.get navigationItems):
1448         (WI.NetworkTableContentView.prototype.shown):
1449         (WI.NetworkTableContentView.prototype.hidden):
1450         (WI.NetworkTableContentView.prototype.closed):
1451         (WI.NetworkTableContentView.prototype.reset):
1452         (WI.NetworkTableContentView.prototype.layout):
1453         (WI.NetworkTableContentView.prototype.handleClearShortcut):
1454         (WI.NetworkTableContentView.prototype._resourceCachingDisabledSettingChanged):
1455         (WI.NetworkTableContentView.prototype._toggleDisableResourceCache):
1456         Add a stubbed out ContentView. This will be implemented next.
1457
1458         * UserInterface/Views/SettingsTabContentView.js:
1459         (WI.SettingsTabContentView.prototype._createExperimentalSettingsView):
1460         Add an experimental setting to toggle the new network tab. Only
1461         show the experimental settings that relate to the debuggable target.
1462         For JSContext targets, none of the settings are applicable, so don't
1463         even show the experimental section.
1464
1465         * UserInterface/Views/TabBrowser.js:
1466         (WI.TabBrowser.prototype.bestTabContentViewForRepresentedObject):
1467         Treat all network tabs the same.
1468
1469 2017-09-11  Matt Baker  <mattbaker@apple.com>
1470
1471         Web Inspector: Canvas: improve recording controls and state management
1472         https://bugs.webkit.org/show_bug.cgi?id=176762
1473         <rdar://problem/34382294>
1474
1475         Reviewed by Devin Rousso.
1476
1477         CanvasManager should be responsible for starting/stopping recordings
1478         and tracking state. Fixing this layering issue lets CanvasContentView
1479         better manage its recording UI.
1480
1481         * UserInterface/Controllers/CanvasManager.js:
1482         (WI.CanvasManager):
1483         (WI.CanvasManager.prototype.get recordingCanvas):
1484         (WI.CanvasManager.prototype.startRecording):
1485         (WI.CanvasManager.prototype.stopRecording):
1486
1487         * UserInterface/Models/Canvas.js:
1488         (WI.Canvas.prototype.get isRecording):
1489         (WI.Canvas.prototype.toggleRecording): Deleted.
1490
1491         * UserInterface/Views/CanvasContentView.css:
1492         (.navigation-bar > .item.canvas-record.disabled):
1493
1494         * UserInterface/Views/CanvasContentView.js:
1495         (WI.CanvasContentView.prototype.shown):
1496         (WI.CanvasContentView.prototype._toggleRecording):
1497         (WI.CanvasContentView.prototype._recordingFinished):
1498         (WI.CanvasContentView.prototype._updateRecordNavigationItem):
1499
1500 2017-09-11  Joseph Pecoraro  <pecoraro@apple.com>
1501
1502         Web Inspector: Cleanup and test MIMETypeUtilities
1503         https://bugs.webkit.org/show_bug.cgi?id=176731
1504
1505         Reviewed by Matt Baker.
1506
1507         * UserInterface/Base/FileUtilities.js:
1508         (WI.saveDataToFile):
1509         * UserInterface/Models/SourceMapResource.js:
1510         (WI.SourceMapResource):
1511         Update callers to handle new return values.
1512
1513         * UserInterface/Base/MIMETypeUtilities.js:
1514         (WI.fileExtensionForURL):
1515         Return null in error cases.
1516         Only provide the content after the last period.
1517
1518         (WI.fileExtensionForMIMEType):
1519         Handle generic "+json" and "+xml" cases.
1520
1521         * UserInterface/Test.html:
1522         Include MIMETypeUtilities for testing.
1523
1524 2017-09-11  Joseph Pecoraro  <pecoraro@apple.com>
1525
1526         Web Inspector: Rename NetworkTab / NetworkSidebar to LegacyNetwork*
1527         https://bugs.webkit.org/show_bug.cgi?id=176739
1528
1529         Reviewed by Matt Baker.
1530
1531         * UserInterface/Main.html:
1532         * UserInterface/Views/LegacyNetworkSidebarPanel.css: Renamed from Source/WebInspectorUI/UserInterface/Views/NetworkSidebarPanel.css.
1533         * UserInterface/Views/LegacyNetworkSidebarPanel.js: Renamed from Source/WebInspectorUI/UserInterface/Views/NetworkSidebarPanel.js.
1534         * UserInterface/Views/LegacyNetworkTabContentView.js: Renamed from Source/WebInspectorUI/UserInterface/Views/NetworkTabContentView.js.
1535         Rename resources.
1536
1537         * UserInterface/Base/Main.js:
1538         (WI.contentLoaded):
1539         * UserInterface/Views/NetworkGridContentView.js:
1540         (WI.NetworkGridContentView):
1541         (WI.NetworkGridContentView.prototype._networkTimelineRecordAdded):
1542         * UserInterface/Views/TabBrowser.js:
1543         (WI.TabBrowser.prototype.bestTabContentViewForRepresentedObject):
1544         Update names at callsites.
1545
1546 2017-09-11  Joseph Pecoraro  <pecoraro@apple.com>
1547
1548         Web Inspector: Remove unused parameter to UIString
1549         https://bugs.webkit.org/show_bug.cgi?id=176738
1550
1551         Reviewed by Matt Baker.
1552
1553         * UserInterface/Base/LoadLocalizedStrings.js:
1554         (WI.UIString):
1555         Remove unused parameter. We moved to String.format for this behavior a while ago.
1556
1557 2017-09-11  Joseph Pecoraro  <pecoraro@apple.com>
1558
1559         Web Inspector: Do not allow the split console in the Settings tab
1560         https://bugs.webkit.org/show_bug.cgi?id=176726
1561
1562         Reviewed by Matt Baker.
1563
1564         * UserInterface/Views/SettingsTabContentView.js:
1565         (WI.SettingsTabContentView.prototype.get supportsSplitContentBrowser):
1566
1567 2017-09-11  Joseph Pecoraro  <pecoraro@apple.com>
1568
1569         Web Inspector: Include a DebugContentView for debugging
1570         https://bugs.webkit.org/show_bug.cgi?id=176733
1571
1572         Reviewed by Matt Baker.
1573
1574         Provide a DebugContentView which can be used to debug lifecycle
1575         events of a ContentView (shown, hidden, closed), and displays a
1576         provided string. It can be created like so:
1577
1578             `new WI.DebugContentView("Name")`
1579
1580         * UserInterface/Debug/DebugContentView.css: Added.
1581         (.content-view.debug):
1582         * UserInterface/Debug/DebugContentView.js: Added.
1583         (WI.DebugContentView):
1584         (WI.DebugContentView.prototype.shown):
1585         (WI.DebugContentView.prototype.hidden):
1586         (WI.DebugContentView.prototype.closed):
1587         Log events for debugging.
1588
1589         * UserInterface/Main.html:
1590         Include new Debug resources.
1591
1592 2017-09-11  Joseph Pecoraro  <pecoraro@apple.com>
1593
1594         Web Inspector: Make Dashboard Timeline icon and Timeline tab icon more similar
1595         https://bugs.webkit.org/show_bug.cgi?id=176582
1596
1597         Reviewed by Timothy Hatcher.
1598
1599         * UserInterface/Images/Time.svg:
1600         Change the clock hands to match the time of Timelines.svg.
1601
1602 2017-09-10  Matt Baker  <mattbaker@apple.com>
1603
1604         Web Inspector: change style of RecordingNavigationSidebarPanel
1605         https://bugs.webkit.org/show_bug.cgi?id=175451
1606         <rdar://problem/34040769>
1607
1608         Reviewed by Devin Rousso.
1609
1610         This patch adds UI polish to the Canvas recording navigation sidebar:
1611          - New icons for Canvas2D operations
1612          - Removed extraneous colors: zebra striping, frame element background color
1613          - Visual action color changed to match details sidebar "changed" color
1614          - Make tree item indent a convenient multiple of the base indent
1615          - Move RecordingActionTreeElement styles to a separate file
1616
1617         * UserInterface/Images/Clip.svg: Added.
1618         * UserInterface/Images/Composite.svg: Added.
1619         * UserInterface/Images/Fill.svg: Added.
1620         * UserInterface/Images/LineStyle.svg: Added.
1621         * UserInterface/Images/Palette.svg: Added.
1622         * UserInterface/Images/PathArc.svg: Added.
1623         * UserInterface/Images/PathCurve.svg: Added.
1624         * UserInterface/Images/PathEllipse.svg: Added.
1625         * UserInterface/Images/PathLineTo.svg: Added.
1626         * UserInterface/Images/PathMoveTo.svg: Added.
1627         * UserInterface/Images/PathRect.svg: Added.
1628         * UserInterface/Images/Pixels.svg: Added.
1629         * UserInterface/Images/PointInPath.svg: Added.
1630         * UserInterface/Images/PointInStroke.svg: Added.
1631         * UserInterface/Images/Shadow.svg: Added.
1632         * UserInterface/Images/Stroke.svg: Added.
1633         * UserInterface/Images/Text.svg: Added.
1634         * UserInterface/Images/Transform.svg: Added.
1635         New icons for Canvas2D operations.
1636
1637         * UserInterface/Main.html:
1638         New file.
1639
1640         * UserInterface/Views/GeneralTreeElement.js:
1641         (WI.GeneralTreeElement.prototype.customTitleTooltip):
1642         (WI.GeneralTreeElement.prototype._updateTitleTooltip):
1643         Allow derived classes to supply a custom tooltip, when
1644         simply getting the title element text is insufficient.
1645
1646         * UserInterface/Views/RecordingActionTreeElement.css: Added.
1647         (.item.action.initial-state > .icon):
1648         (.tree-outline:not(:focus, .force-focus) .item.action:not(.initial-state, .parent, .invalid) > .icon):
1649         (.item.action:not(.initial-state)::before):
1650         (body[dir=ltr] .item.action::before):
1651         (body[dir=rtl] .item.action::before):
1652         (.tree-outline:matches(:focus, .force-focus) .item.action.selected:not(.initial-state, .invalid) > .icon):
1653         (body:not(.window-inactive, .window-docked-inactive) :matches(:focus, .force-focus) .item.action.selected > .titles .parameter.swizzled,):
1654         (.tree-outline[data-indent="1"] .item.action::before,):
1655         (.tree-outline[data-indent="3"] .item.action::before):
1656         (.tree-outline[data-indent="4"] .item.action::before):
1657         (.tree-outline[data-indent="5"] .item.action::before):
1658         (.tree-outline[data-indent="6"] .item.action::before):
1659         (.tree-outline[data-indent="7"] .item.action::before):
1660         (body[dir=ltr] .tree-outline:not(.hide-disclosure-buttons) .item.action:not(.initial-state, .parent) > .icon):
1661         (body[dir=rtl] .tree-outline:not(.hide-disclosure-buttons) .item.action:not(.initial-state, .parent) > .icon):
1662         (.item.action.visual:not(.selected, .invalid)):
1663         (.item.action.attribute > .titles .parameters::before):
1664         (.item.action:not(.attribute) > .titles .parameters::before):
1665         (.item.action:not(.attribute) > .titles .parameters::after):
1666         (.item.action > .titles .parameter:not(:last-child)::after):
1667         (.item.action:not(.selected) > .titles .parameter.swizzled):
1668         (.item.action.composite > .icon):
1669         (.item.action.fill > .icon):
1670         (.item.action.image > .icon):
1671         (.item.action.line-style > .icon):
1672         (.item.action.shadow > .icon):
1673         (.item.action.stroke > .icon):
1674         (.item.action.style > .icon):
1675         (.item.action.text > .icon):
1676         (.item.action.transform > .icon):
1677         (.item.action.arc > .icon):
1678         (.item.action.clip > .icon):
1679         (.item.action.curve > .icon):
1680         (.item.action.ellipse > .icon):
1681         (.item.action.line-to > .icon):
1682         (.item.action.move-to > .icon):
1683         (.item.action.point-in-path > .icon):
1684         (.item.action.point-in-stroke > .icon):
1685         (.item.action.rect > .icon):
1686         (.item.action.restore > .icon):
1687         (.item.action.save > .icon):
1688         (.item.action.invalid > .icon):
1689
1690         * UserInterface/Views/RecordingActionTreeElement.js:
1691         (WI.RecordingActionTreeElement):
1692         (WI.RecordingActionTreeElement._generateDOM.createParameterElement):
1693         (WI.RecordingActionTreeElement._generateDOM):
1694         (WI.RecordingActionTreeElement._getClassNames):
1695         Broke out into its own helper, to simplify _generateDOM which had
1696         too many responsibilities.
1697
1698         (WI.RecordingActionTreeElement._classNameForAction.classNameForActionName):
1699         (WI.RecordingActionTreeElement._classNameForAction):
1700         Get an icon for the action "type". Actions are grouped by similar
1701         operations. For example, lineCap, lineDash, lineJoin, lineWidth, and
1702         miterLimit are assigned the icon LineStyle.svg.
1703
1704         (WI.RecordingActionTreeElement.prototype.customTitleTooltip):
1705
1706         * UserInterface/Views/RecordingNavigationSidebarPanel.css:
1707         (.sidebar > .panel.navigation.recording > .content > .tree-outline .item.folder-icon > .icon):
1708         (.sidebar > .panel.navigation.recording > .content > .tree-outline:not(:empty)): Deleted.
1709         (.sidebar > .panel.navigation.recording > .content > .tree-outline > .item.parent:not(.action, .selected).expanded): Deleted.
1710         (.sidebar > .panel.navigation.recording > .content > .tree-outline .item.action:not(.initial-state)::before): Deleted.
1711         (body[dir=ltr] .sidebar > .panel.navigation.recording > .content > .tree-outline .item.action:not(.initial-state)::before): Deleted.
1712         (body[dir=rtl] .sidebar > .panel.navigation.recording > .content > .tree-outline .item.action:not(.initial-state)::before): Deleted.
1713         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="2"] .item.action:not(.initial-state)::before): Deleted.
1714         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="3"] .item.action:not(.initial-state)::before): Deleted.
1715         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="4"] .item.action:not(.initial-state)::before): Deleted.
1716         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="5"] .item.action:not(.initial-state)::before): Deleted.
1717         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="6"] .item.action:not(.initial-state)::before): Deleted.
1718         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="7"] .item.action:not(.initial-state)::before): Deleted.
1719         (.sidebar > .panel.navigation.recording > .content .action > .icon): Deleted.
1720         (.sidebar > .panel.navigation.recording > .content .action.function > .icon): Deleted.
1721         (.sidebar > .panel.navigation.recording > .content .action.attribute.getter > .icon): Deleted.
1722         (.sidebar > .panel.navigation.recording > .content .tree-outline:matches(:focus, .force-focus) .action.attribute.getter.selected > .icon): Deleted.
1723         (.sidebar > .panel.navigation.recording > .content .action.attribute.boolean > .icon): Deleted.
1724         (.sidebar > .panel.navigation.recording > .content .action.attribute.number > .icon): Deleted.
1725         (.sidebar > .panel.navigation.recording > .content .action.attribute.object > .icon): Deleted.
1726         (.sidebar > .panel.navigation.recording > .content .action.attribute.string > .icon): Deleted.
1727         (.sidebar > .panel.navigation.recording > .content > .tree-outline > .item.parent:not(.action) > .icon): Deleted.
1728         (.sidebar > .panel.navigation.recording > .content .action:matches(.invalid, .missing) > .icon): Deleted.
1729         (body[dir=ltr] .sidebar > .panel.navigation.recording > .content .action:not(.initial-state) > .icon): Deleted.
1730         (body[dir=rtl] .sidebar > .panel.navigation.recording > .content .action:not(.initial-state) > .icon): Deleted.
1731         (.sidebar > .panel.navigation.recording > .content .action.visual:not(.selected, .invalid)): Deleted.
1732         (.sidebar > .panel.navigation.recording > .content .action:not(.selected, .initial-state) > .titles .parameter.swizzled): Deleted.
1733         (.sidebar > .panel.navigation.recording > .content .action.invalid:not(.selected, .initial-state) > .titles :matches(.name, .parameter.invalid)): Deleted.
1734         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
1735
1736 2017-09-08  Joseph Pecoraro  <pecoraro@apple.com>
1737
1738         Uncaught Exception: TypeError: this._heapSnapshot.addEventListener is not a function.
1739         https://bugs.webkit.org/show_bug.cgi?id=176633
1740
1741         Reviewed by Michael Saboff.
1742
1743         * UserInterface/Proxies/HeapSnapshotDiffProxy.js:
1744         (WI.HeapSnapshotDiffProxy):
1745         This class has listeners of another object's events. It should extend WI.Object.
1746
1747 2017-09-08  Devin Rousso  <webkit@devinrousso.com>
1748
1749         Web Inspector: Canvas: changes to currentX/currentY aren't highlighted in the details sidebar
1750         https://bugs.webkit.org/show_bug.cgi?id=176569
1751
1752         Reviewed by Matt Baker.
1753
1754         * UserInterface/Models/RecordingAction.js:
1755         Add entries to WI.RecordingAction._stateModifiers for each path function.
1756
1757 2017-09-07  Joseph Pecoraro  <pecoraro@apple.com>
1758
1759         Augmented Inspector: Provide a way to inspect a DOM Node (DOM.inspect)
1760         https://bugs.webkit.org/show_bug.cgi?id=176563
1761         <rdar://problem/19639583>
1762
1763         Reviewed by Matt Baker.
1764
1765         * UserInterface/Base/Main.js:
1766         (WI.contentLoaded):
1767         Always create the element search toolbar icon. Only show it if the DOM domain
1768         is available. With augmented agents the DOM domain may be activated later.
1769
1770         * UserInterface/Protocol/DOMObserver.js:
1771         (WI.DOMObserver.prototype.inspect):
1772         Select the node in the DOM tree outline.
1773
1774 2017-09-07  Devin Rousso  <webkit@devinrousso.com>
1775
1776         Web Inspector: Canvas RecordingAction tree outline virtualization is broken
1777         https://bugs.webkit.org/show_bug.cgi?id=176547
1778
1779         Reviewed by Joseph Pecoraro.
1780
1781         * UserInterface/Views/TreeOutline.js:
1782         (WI.TreeOutline.prototype.updateVirtualizedElements.walk):
1783         (WI.TreeOutline.prototype.updateVirtualizedElements):
1784         Pass the current `count` to each recursive call of `walk` so that the cumulative index of a
1785         TreeElement in any given sub-tree is correct.
1786         Drive-by: if there is a focused TreeElement when scrolling, only change the current
1787         `scrollTop` if it is not already visible. Also rewrote some loops for clarity.
1788
1789 2017-09-07  Devin Rousso  <webkit@devinrousso.com>
1790
1791         Unreviewed, change my copyright email.
1792
1793         * Scripts/copy-user-interface-resources.pl:
1794         * UserInterface/Controllers/CodeMirrorSpringEditingController.js:
1795         * UserInterface/Images/AnimationPlayStatePaused.svg:
1796         * UserInterface/Images/AnimationPlayStateRunning.svg:
1797         * UserInterface/Images/CSSVariable.svg:
1798         * UserInterface/Images/ListStylePositionInside.svg:
1799         * UserInterface/Images/ListStylePositionOutside.svg:
1800         * UserInterface/Images/StyleRule.svg:
1801         * UserInterface/Images/StyleRulePseudoElement.svg:
1802         * UserInterface/Models/Collection.js:
1803         * UserInterface/Models/ResourceCollection.js:
1804         * UserInterface/Views/CollectionContentView.css:
1805         * UserInterface/Views/CollectionContentView.js:
1806         * UserInterface/Views/ContextMenuUtilities.js:
1807         * UserInterface/Views/GeneralTabBarItem.js:
1808         * UserInterface/Views/GradientEditor.css:
1809         * UserInterface/Views/GradientEditor.js:
1810         * UserInterface/Views/InlineSwatch.css:
1811         * UserInterface/Views/InlineSwatch.js:
1812         * UserInterface/Views/PinnedTabBarItem.js:
1813         * UserInterface/Views/SettingsTabContentView.css:
1814         * UserInterface/Views/SettingsTabContentView.js:
1815         * UserInterface/Views/SpringEditor.css:
1816         * UserInterface/Views/SpringEditor.js:
1817         * UserInterface/Views/StyleRuleIcons.css:
1818         * UserInterface/Views/TabBarItem.js:
1819         * UserInterface/Views/TitleView.css:
1820         * UserInterface/Views/TitleView.js:
1821         * UserInterface/Views/VisualStyleBackgroundPicker.css:
1822         * UserInterface/Views/VisualStyleBackgroundPicker.js:
1823         * UserInterface/Views/VisualStyleBasicInput.js:
1824
1825 2017-09-06  Matt Baker  <mattbaker@apple.com>
1826
1827         Web Inspector: Relax the maximum sidebar width
1828         https://bugs.webkit.org/show_bug.cgi?id=175808
1829         <rdar://problem/34005339>
1830
1831         Reviewed by Devin Rousso.
1832
1833         This patch introduces a constant, `minimumContentBrowserWidth`, which
1834         constrains the maximum width of either sidebar:
1835
1836         maxSidebarWidth = window.innerWidth - minimumContentBrowserWidth - otherSidebarWidth
1837
1838         A value of 100px for `minimumContentBrowserWidth` leaves enough space for
1839         three NavigationItems at their minimum width (32px), with a few pixels
1840         left over for good measure. For most tabs this will ensure that the buttons
1841         for showing the sidebars will be visible, along with an addition button.
1842
1843         * UserInterface/Base/Main.js:
1844         * UserInterface/Views/Sidebar.js:
1845         (WI.Sidebar.prototype.get maximumWidth):
1846
1847 2017-09-06  Devin Rousso  <webkit@devinrousso.com>
1848
1849         Web Inspector: Support overloaded CanvasRenderingContext2D actions with identical parameter counts
1850         https://bugs.webkit.org/show_bug.cgi?id=176178
1851         <rdar://problem/34192229>
1852
1853         Reviewed by Matt Baker.
1854
1855         * UserInterface/Models/Recording.js:
1856         (WI.Recording.displayNameForSwizzleType):
1857         (WI.Recording.prototype.swizzle):
1858         Replace WI.Recording.Swizzle with an object of swizzle type keys to int values. This object
1859         matches the values in WebCore::RecordingSwizzleTypes.h.
1860
1861         * UserInterface/Models/RecordingAction.js:
1862         (WI.RecordingAction):
1863         (WI.RecordingAction.fromPayload):
1864         (WI.RecordingAction.prototype.get swizzleTypes):
1865         (WI.RecordingAction.prototype.swizzle):
1866         (WI.RecordingAction.prototype.toJSON):
1867         (WI.RecordingAction.prototype.parameterSwizzleTypeForTypeAtIndex): Deleted.
1868         Replace WI.RecordingAction._parameterSwizzleTypeForTypeAtIndex with an array of parameter
1869         types sent in the payload. This gives more control over the swizzling to the JSON, but also
1870         simplifies the way we regenerate the data in the frontend.
1871
1872         * UserInterface/Views/RecordingActionTreeElement.js:
1873         (WI.RecordingActionTreeElement._generateDOM):
1874
1875         * UserInterface/Views/RecordingContentView.js:
1876         (WI.RecordingContentView.prototype._generateContentCanvas2D):
1877         (WI.RecordingContentView.prototype._applyAction):
1878
1879         * UserInterface/Views/RecordingNavigationSidebarPanel.css:
1880         (.sidebar > .panel.navigation.recording > .content .action.invalid:not(.selected, .initial-state) > .titles :matches(.name, .parameter.invalid)):
1881         (.sidebar > .panel.navigation.recording > .content .action.invalid:not(.selected, .initial-state) > .titles .name,): Deleted.
1882
1883 2017-09-06  Joseph Pecoraro  <pecoraro@apple.com>
1884
1885         Web Inspector: ⌘E and ⌘G do not work in main content area when quick console drawer is open
1886         https://bugs.webkit.org/show_bug.cgi?id=176433
1887
1888         Reviewed by Brian Burg.
1889
1890         Make the ⌘E and ⌘G keyboard shortcuts behave more like the global ⌘K clear shortcut.
1891         Instead of keeping them inside of FindBanner, and enabling/disabling them when they
1892         make sense to apply, we make a single global instance of the keyboard shortcut and
1893         apply it to whatever content view / content browser is active. This avoids conflicts
1894         in situations where there are two ContentViews that are visible and each can handle
1895         the keyboard shortcut.
1896
1897         * UserInterface/Base/Main.js:
1898         (WI.contentLoaded):
1899         New keyboard shortcuts.
1900
1901         (WI._populateFind):
1902         (WI._findNext):
1903         (WI._findPrevious):
1904         Perform the shortcut on the active content view or content browser.
1905
1906         * UserInterface/Views/ContentBrowser.js:
1907         (WI.ContentBrowser.prototype.shown):
1908         (WI.ContentBrowser.prototype.hidden):
1909         (WI.ContentBrowser.prototype.handlePopulateFindShortcut):
1910         (WI.ContentBrowser.prototype.handleFindNextShortcut):
1911         (WI.ContentBrowser.prototype.handleFindPreviousShortcut):
1912         (WI.ContentBrowser.prototype.findBannerSearchQueryForSelection): Deleted.
1913         * UserInterface/Views/LogContentView.js:
1914         (WI.LogContentView.prototype.handlePopulateFindShortcut):
1915         (WI.LogContentView.prototype.handleFindNextShortcut):
1916         (WI.LogContentView.prototype.handleFindPreviousShortcut):
1917         ContentBrowser and LogContentView (the only content view with a custom find banner)
1918         now each handle the global keyboard shortcut handlers to do the right thing for
1919         their respective cases.
1920
1921         * UserInterface/Views/FindBanner.js:
1922         (WI.FindBanner.prototype.enableKeyboardShortcuts): Deleted.
1923         (WI.FindBanner.prototype.disableKeyboardShortcuts): Deleted.
1924         (WI.FindBanner.prototype._populateSearchQueryFromSelection): Deleted.
1925         Move keyboard shortcut handling up to Main.js to be global.
1926
1927         * UserInterface/Views/ContentView.js:
1928         (WI.ContentView.prototype.searchQueryWithSelection):
1929         Default implementation should grab the selected text from the selection.
1930         Previously shortcut selections only worked for selections in text editors.
1931
1932 2017-09-05  Nikita Vasilyev  <nvasilyev@apple.com>
1933
1934         Web Inspector: Styles Redesign: display "Inherited From" section headers
1935         https://bugs.webkit.org/show_bug.cgi?id=176033
1936         <rdar://problem/34116930>
1937
1938         Reviewed by Devin Rousso.
1939
1940         Compared to the old styles sidebar, the new "Inherited From" sections are more compact.
1941         One of the goals of the styles redesign is to make it fit more data vertically.
1942
1943         The contrast is inceased. The text is darker while the background stayed the same.
1944
1945         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.css:
1946         (.spreadsheet-style-panel .section-inherited):
1947         (.spreadsheet-style-panel .section-inherited .node-link):
1948         (.spreadsheet-style-panel .section-inherited .node-link:hover):
1949         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js:
1950         (WI.SpreadsheetRulesStyleDetailsPanel):
1951         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.refresh):
1952         Don't show two identical "Inherited From" sections.
1953
1954 2017-09-05  Nikita Vasilyev  <nvasilyev@apple.com>
1955
1956         Web Inspector: Layout flashing for internal View.prototype.layout
1957         https://bugs.webkit.org/show_bug.cgi?id=176389
1958
1959         Reviewed by Matt Baker.
1960
1961         Add a checkbox to Settings (Debug panel) to draw an orange outline around an element every time View.prototype.layout is called.
1962         This is similar to paint flashing, except this is only for View.prototype.layout.
1963
1964         * UserInterface/Base/Setting.js:
1965         * UserInterface/Views/SettingsTabContentView.js:
1966         (WI.SettingsTabContentView.prototype._createDebugSettingsView):
1967         * UserInterface/Views/View.js:
1968         (WI.View.prototype._layoutSubtree):
1969         (WI.View.prototype._drawLayoutFlashingOutline):
1970
1971 2017-09-04  Nikita Vasilyev  <nvasilyev@apple.com>
1972
1973         Web Inspector: Styles Redesign: hook up real data to spreadsheet style editor
1974         https://bugs.webkit.org/show_bug.cgi?id=175343
1975         <rdar://problem/33784793>
1976
1977         Reviewed by Devin Rousso.
1978
1979         Replace static HTML added in <https://webkit.org/b/174838> with actual data.
1980
1981         Addressed in this patch:
1982         - CSS rules can be copied.
1983         - Source links work as expected.
1984         - Nonmatching selectors are grayed out.
1985
1986         Known limitations:
1987         - Neither CSS selectors nor CSS properties are editable.
1988         - "Inherited from" and media query section headers are missing.
1989         - No syntax highlighting of complex CSS values, e.g. hsl(0, 0%, 70%).
1990
1991         * UserInterface/Main.html:
1992         * UserInterface/Models/CSSStyleDeclaration.js:
1993         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
1994         (WI.CSSStyleDeclarationTextEditor):
1995         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
1996         (WI.CSSStyleDetailsSidebarPanel):
1997         * UserInterface/Views/RulesStyleSpreadsheetDetailsPanel.js: Removed.
1998         Rename RulesStyleSpreadsheetDetailsPanel to SpreadsheetRulesStyleDetailsPanel. All files related to the spreadsheet editor start with "Spreadsheet" now.
1999
2000         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.css: Added.
2001         (.spreadsheet-style-declaration-editor):
2002         (.spreadsheet-style-declaration-editor .name):
2003         (.spreadsheet-style-declaration-editor .value):
2004         (.spreadsheet-style-declaration-editor.no-properties):
2005         * UserInterface/Views/SpreadsheetCSSStyleDeclarationEditor.js: Added.
2006         (WI.SpreadsheetCSSStyleDeclarationEditor):
2007         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.layout):
2008         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.get delegate):
2009         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.set delegate):
2010         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.get style):
2011         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.set style):
2012         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype.get _propertiesToRender):
2013         Similar condition is commonly used in CSSStyleDeclarationTextEditor. Abstact it out to its own method.
2014
2015         (WI.SpreadsheetCSSStyleDeclarationEditor.prototype._renderProperty):
2016         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.css: Copied from Source/WebInspectorUI/UserInterface/Views/RulesStyleSpreadsheetDetailsPanel.css.
2017         (.spreadsheet-css-declaration):
2018         (.spreadsheet-css-declaration .origin):
2019         (.spreadsheet-css-declaration.locked .origin::after):
2020         (.spreadsheet-css-declaration .origin .go-to-link):
2021         (.spreadsheet-css-declaration .origin .go-to-link:hover):
2022         (.spreadsheet-css-declaration .styles-source):
2023         (.spreadsheet-css-declaration .selector.style-attribute):
2024         (.spreadsheet-css-declaration .selector > span):
2025         (.spreadsheet-css-declaration .selector > .matched):
2026         (.spreadsheet-css-declaration .properties):
2027         (.spreadsheet-css-declaration.locked):
2028         (.spreadsheet-css-declaration .locked-icon):
2029         * UserInterface/Views/SpreadsheetCSSStyleDeclarationSection.js: Added.
2030         (WI.SpreadsheetCSSStyleDeclarationSection):
2031         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.get element):
2032         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.get style):
2033         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.initialLayout):
2034         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.layout):
2035         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.cssStyleDeclarationTextEditorFocused):
2036         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.get locked):
2037         (WI.SpreadsheetCSSStyleDeclarationSection.prototype.get selectorEditable):
2038         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.css: Renamed from Source/WebInspectorUI/UserInterface/Views/RulesStyleSpreadsheetDetailsPanel.css.
2039         * UserInterface/Views/SpreadsheetRulesStyleDetailsPanel.js: Added.
2040         (WI.SpreadsheetRulesStyleDetailsPanel):
2041         (WI.SpreadsheetRulesStyleDetailsPanel.prototype.refresh):
2042         * UserInterface/Views/StyleDetailsPanel.js:
2043         (WI.StyleDetailsPanel.prototype.filterDidChange):
2044
2045         * UserInterface/Views/View.js:
2046         (WI.View.prototype.removeAllSubviews):
2047         Add a method to remove all subviews more efficiently.
2048
2049 2017-08-29  Matt Baker  <mattbaker@apple.com>
2050
2051         Web Inspector: Critical content browser toolbar buttons are hidden at narrow widths
2052         https://bugs.webkit.org/show_bug.cgi?id=175999
2053
2054         Reviewed by Devin Rousso.
2055
2056         This patch adds a VisibilityPriority concept to NavigationItems. If a
2057         NavigationBar cannot fit all of its items in the available space, items
2058         are hidden to make room, starting with the lowest priority item. Consecutive
2059         dividers are then collapsed, as well as leading and trailing dividers.
2060
2061         * UserInterface/Main.html:
2062         New file.
2063
2064         * UserInterface/Views/CanvasContentView.js:
2065         (WI.CanvasContentView):
2066         * UserInterface/Views/ConsoleDrawer.js:
2067         (WI.ConsoleDrawer):
2068         * UserInterface/Views/ContentBrowser.js:
2069         (WI.ContentBrowser):
2070         * UserInterface/Views/ContentBrowserTabContentView.js:
2071         (WI.ContentBrowserTabContentView):
2072         * UserInterface/Views/DOMTreeContentView.js:
2073         (WI.DOMTreeContentView):
2074         Set `High` and `Low` priorities, and group the back/forward buttons.
2075
2076         * UserInterface/Views/GroupNavigationItem.js: Added.
2077         (WI.GroupNavigationItem):
2078         (WI.GroupNavigationItem.prototype.get navigationItems):
2079         (WI.GroupNavigationItem.prototype.get minimumWidth):
2080         (WI.GroupNavigationItem.prototype.updateLayout):
2081         (WI.GroupNavigationItem.prototype.didAttach):
2082         (WI.GroupNavigationItem.prototype.didDetach):
2083         NavigationItem groups. Grouped items are shown/hidden together.
2084
2085         * UserInterface/Views/HierarchicalPathNavigationItem.js:
2086         (WI.HierarchicalPathNavigationItem.prototype.updateLayout):
2087         * UserInterface/Views/ImageResourceContentView.js:
2088         (WI.ImageResourceContentView):
2089         * UserInterface/Views/IndexedDatabaseObjectStoreContentView.js:
2090         (WI.IndexedDatabaseObjectStoreContentView):
2091         * UserInterface/Views/LogContentView.js:
2092         (WI.LogContentView):
2093         Set `High` and `Low` priorities.
2094
2095         * UserInterface/Views/NavigationBar.css:
2096         (.navigation-bar .item.force-hidden):
2097         New hidden class, which must be tracked separately from ".hidden".
2098         The former is an implementation detail of NavigationBar, while the
2099         latter is set by the client.
2100
2101         * UserInterface/Views/NavigationBar.js:
2102         (WI.NavigationBar.prototype.insertNavigationItem):
2103         (WI.NavigationBar.prototype.removeNavigationItem):
2104         (WI.NavigationBar.prototype.findNavigationItem.matchingSelfOrChild):
2105         (WI.NavigationBar.prototype.findNavigationItem):
2106         (WI.NavigationBar.prototype.layout.forceItemHidden):
2107         (WI.NavigationBar.prototype.layout.isDivider):
2108         (WI.NavigationBar.prototype.layout.calculateVisibleItemWidth):
2109         (WI.NavigationBar.prototype.layout):
2110         (WI.NavigationBar.prototype._calculateMinimumWidth):
2111         (WI.NavigationBar.prototype.get _visibleNavigationItems):
2112         (WI.NavigationBar):
2113
2114         * UserInterface/Views/NavigationItem.js:
2115         Add support for visibility priority, an integer value that determines the
2116         order in which items are hidden when the NavigationBar becomes too narrow
2117         to fit all of items child items. NavigationIte3m defines constants for
2118         Low, Normal (the default), and High priority.
2119
2120         (WI.NavigationItem):
2121         (WI.NavigationItem.prototype.get minimumWidth):
2122         (WI.NavigationItem.prototype.get width):
2123         (WI.NavigationItem.prototype.get visibilityPriority):
2124         (WI.NavigationItem.prototype.set visibilityPriority):
2125         (WI.NavigationItem.prototype.updateLayout):
2126         (WI.NavigationItem.prototype.didAttach):
2127         (WI.NavigationItem.prototype.didDetach):
2128         Encapsulate the setting of the parent NavigationBar. Needed so that
2129         GroupNavigationItem can forward this action to its children.
2130
2131         * UserInterface/Views/NetworkGridContentView.js:
2132         (WI.NetworkGridContentView):
2133         * UserInterface/Views/RadioButtonNavigationItem.js:
2134         (WI.RadioButtonNavigationItem.prototype.updateLayout):
2135         * UserInterface/Views/RecordingContentView.js:
2136         (WI.RecordingContentView):
2137         * UserInterface/Views/ScriptContentView.js:
2138         (WI.ScriptContentView):
2139         * UserInterface/Views/TextContentView.js:
2140         (WI.TextContentView):
2141         * UserInterface/Views/TextResourceContentView.js:
2142         (WI.TextResourceContentView):
2143         * UserInterface/Views/TimelineRecordingContentView.js:
2144         (WI.TimelineRecordingContentView):
2145         * UserInterface/Views/TimelineTabContentView.js:
2146         (WI.TimelineTabContentView):
2147         Set `High` and `Low` priorities, and group Timeline view mode buttons.
2148
2149 2017-08-29  Joseph Pecoraro  <pecoraro@apple.com>
2150
2151         REGRESSION(r220235): Web Inspector: Global search should not happen incrementally
2152         https://bugs.webkit.org/show_bug.cgi?id=176063
2153
2154         Reviewed by Devin Rousso.
2155
2156         * UserInterface/Base/Main.js:
2157         (WI.contentLoaded):
2158         * UserInterface/Views/SearchBar.js:
2159         (WI.SearchBar):
2160         (WI.SearchBar.prototype._handleKeydownEvent):
2161         Remove delegate and simplify setting incremental.
2162
2163 2017-08-29  Nikita Vasilyev  <nvasilyev@apple.com>
2164
2165         Web Inspector: Convert all methods in Utilities.js to ECMAScript 2015 shorthand syntax
2166         https://bugs.webkit.org/show_bug.cgi?id=176067
2167
2168         Reviewed by Joseph Pecoraro.
2169
2170         * UserInterface/Base/Utilities.js:
2171         (get return):
2172         (addStringToken):
2173         (prettyFunctionName):
2174         (warn):
2175         (error):
2176         (isEmptyObject):
2177         (isEnterKey):
2178         (resolveDotsInPath):
2179         (parseMIMEType):
2180         (simpleGlobStringToRegExp):
2181         (defaultComparator):
2182         (get Object):
2183         (appendWebInspectorSourceURL):
2184         (appendWebInspectorConsoleEvaluationSourceURL):
2185         (isWebInspectorInternalScript):
2186         (isWebInspectorConsoleEvaluationScript):
2187         (isWebKitInjectedScript):
2188         (isWebKitInternalScript):
2189         (isFunctionStringNativeCode):
2190         (isTextLikelyMinified):
2191         (doubleQuotedString):
2192         (insertionIndexForObjectInListSortedByFunction):
2193         (insertObjectIntoSortedArray):
2194         (decodeBase64ToBlob):
2195
2196 2017-08-29  Nikita Vasilyev  <nvasilyev@apple.com>
2197
2198         Web Inspector: Optimize View.prototype.removeSubview
2199         https://bugs.webkit.org/show_bug.cgi?id=176041
2200
2201         Reviewed by Matt Baker.
2202
2203         Look up a subview in an array only once, not twice.
2204
2205         * UserInterface/Base/Utilities.js:
2206         (Array.prototype.removeAll):
2207         (Array.prototype.remove):
2208         Split Array.propotype.remove(value, onlyFirst) into Array.propotype.removeAll(value) and
2209         Array.propotype.remove(value).
2210
2211         * UserInterface/Controllers/DebuggerManager.js:
2212         (WI.DebuggerManager.prototype._debuggerBreakpointOptions):
2213         * UserInterface/Views/ContentViewContainer.js:
2214         (WI.ContentViewContainer.prototype._clearTombstonesForContentView):
2215         (WI.ContentViewContainer.prototype._disassociateFromContentView):
2216         * UserInterface/Views/View.js:
2217         (WI.View.prototype.removeSubview):
2218
2219 2017-08-28  Joseph Pecoraro  <pecoraro@apple.com>
2220
2221         Web Inspector: Remove some unused DataGrid code
2222         https://bugs.webkit.org/show_bug.cgi?id=176029
2223
2224         Reviewed by Matt Baker.
2225
2226         * UserInterface/Views/DataGrid.js:
2227         (WI.DataGrid.prototype.get copyTextDelimiter):
2228         (WI.DataGrid.prototype.set copyTextDelimiter):
2229         (WI.DataGrid.prototype.resizerDragging):
2230         (WI.DataGrid.prototype.columnWidthsMap): Deleted.
2231         (WI.DataGrid.prototype.applyColumnWidthsMap): Deleted.
2232         (WI.DataGrid.prototype.get resizeMethod): Deleted.
2233         (WI.DataGrid.prototype.set resizeMethod): Deleted.
2234
2235 2017-08-27  Devin Rousso  <webkit@devinrousso.com>
2236
2237         Web Inspector: Record actions performed on WebGLRenderingContext
2238         https://bugs.webkit.org/show_bug.cgi?id=174483
2239         <rdar://problem/34040722>
2240
2241         Reviewed by Matt Baker.
2242
2243         * UserInterface/Models/Recording.js:
2244         (WI.Recording):
2245         (WI.Recording.fromPayload):
2246         (WI.Recording.prototype.swizzle):
2247         Add swizzle types for WebGL parameters.
2248
2249         * UserInterface/Models/RecordingAction.js:
2250         (WI.RecordingAction):
2251         (WI.RecordingAction.fromPayload):
2252         (WI.RecordingAction.prototype.get snapshot):
2253         (WI.RecordingAction.prototype.swizzle):
2254         (WI.RecordingAction.prototype.toJSON):
2255         Include an optional fourth parameter `snapshot` that will be sent for visual actions when
2256         recording WebGL canvas contexts.
2257
2258         * UserInterface/Views/RecordingContentView.js:
2259         (WI.RecordingContentView):
2260         (WI.RecordingContentView.prototype.get navigationItems):
2261         (WI.RecordingContentView.prototype.updateActionIndex):
2262         (WI.RecordingContentView.prototype.shown):
2263         (WI.RecordingContentView.prototype._generateContentCanvasWebGL):
2264         * UserInterface/Views/RecordingContentView.css:
2265         (.content-view:not(.tab).recording :matches(img, canvas)):
2266         (.content-view:not(.tab).recording canvas): Deleted.
2267         Instead of regenerating the canvas context in the WebInspector frontend, just display the
2268         snapshot image for the last visual action.
2269
2270         * UserInterface/Views/CanvasContentView.js:
2271         (WI.CanvasContentView):
2272
2273         * UserInterface/Views/RecordingActionTreeElement.js:
2274         (WI.RecordingActionTreeElement._generateDOM):
2275
2276 2017-08-24  Devin Rousso  <webkit@devinrousso.com>
2277
2278         Web Inspector: add filter for draw actions in Recordings
2279         https://bugs.webkit.org/show_bug.cgi?id=175448
2280         <rdar://problem/34040764>
2281
2282         Reviewed by Matt Baker.
2283
2284         * Localizations/en.lproj/localizedStrings.js:
2285         
2286         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
2287         (WI.RecordingNavigationSidebarPanel.prototype.initialLayout):
2288         (WI.RecordingNavigationSidebarPanel.prototype.matchTreeElementAgainstCustomFilters):
2289         Add button to filter visual actions.
2290         Drive-by fix: ensure that frame folders are still visible when filtering.
2291
2292         * UserInterface/Images/Paint.svg: Renamed from Source/WebInspectorUI/UserInterface/Images/PaintFlashing.svg.
2293         * UserInterface/Images/gtk/Paint.svg: Renamed from Source/WebInspectorUI/UserInterface/Images/gtk/PaintFlashing.svg.
2294         * UserInterface/Views/DOMTreeContentView.js:
2295         (WI.DOMTreeContentView):
2296         Rename PaintFlashing.svg to Paint.svg.
2297
2298 2017-08-24  Ross Kirsling  <ross.kirsling@sony.com>
2299
2300         Web Inspector: Create experimental Layers tab
2301         https://bugs.webkit.org/show_bug.cgi?id=175728
2302
2303         Reviewed by Devin Rousso.
2304
2305         * Localizations/en.lproj/localizedStrings.js:
2306         * UserInterface/Base/Main.js:
2307         * UserInterface/Base/Setting.js:
2308         * UserInterface/Images/Layers.svg: Added.
2309         * UserInterface/Main.html:
2310         * UserInterface/Views/Layers3DContentView.js: Added.
2311         * UserInterface/Views/LayersTabContentView.js: Added.
2312         * UserInterface/Views/SettingsTabContentView.js:
2313
2314 2017-08-24  Devin Rousso  <webkit@devinrousso.com>
2315
2316         Web Inspector: Table grid shouldn't show behind empty state
2317         https://bugs.webkit.org/show_bug.cgi?id=175943
2318
2319         Reviewed by Brian Burg.
2320
2321         * UserInterface/Views/RecordingNavigationSidebarPanel.css:
2322         (.sidebar > .panel.navigation.recording > .content > .tree-outline):
2323         (.sidebar > .panel.navigation.recording > .content > .tree-outline:not(:empty)):
2324         Only apply the background when the TreeOutline has children.
2325
2326 2017-08-23  Nikita Vasilyev  <nvasilyev@apple.com>
2327
2328         Web Inspector: Make lock icon crispier
2329         https://bugs.webkit.org/show_bug.cgi?id=175868
2330
2331         Reviewed by Matt Baker.
2332
2333         * UserInterface/Images/Locked.svg:
2334
2335 2017-08-22  Devin Rousso  <webkit@devinrousso.com>
2336
2337         Web Inspector: provide way for ShaderPrograms to be enabled/disabled
2338         https://bugs.webkit.org/show_bug.cgi?id=175400
2339
2340         Reviewed by Matt Baker.
2341
2342         Adds a status element to ShaderProgramTreeElement that, when clicked, will toggle the
2343         disabled state of the corresponding ShaderProgram. Disabled shader programs will not draw
2344         anything to the context.
2345
2346         * Localizations/en.lproj/localizedStrings.js:
2347         * UserInterface/Main.html:
2348
2349         * UserInterface/Models/ShaderProgram.js:
2350         (WI.ShaderProgram):
2351         (WI.ShaderProgram.prototype.get disabled):
2352         (WI.ShaderProgram.prototype.toggleDisabled):
2353
2354         * UserInterface/Views/ShaderProgramTreeElement.js:
2355         (WI.ShaderProgramTreeElement):
2356         (WI.ShaderProgramTreeElement.prototype.selectOnMouseDown):
2357         (WI.ShaderProgramTreeElement.prototype._disabledImageElementClicked):
2358         * UserInterface/Views/ShaderProgramTreeElement.css: Added.
2359         (.item.shader-program .status > img):
2360         (.item.shader-program:not(:hover, .selected, .disabled) .status > img):
2361         (.tree-outline:matches(:focus, .force-focus) .item.shader-program.selected .status > img):
2362         (.item.shader-program.disabled > *):
2363
2364 2017-08-21  Devin Rousso  <webkit@devinrousso.com>
2365
2366         Web Inspector: Can't copy text from "View variable value" popover in Styles sidebar
2367         https://bugs.webkit.org/show_bug.cgi?id=175758
2368
2369         Reviewed by Matt Baker.
2370
2371         * UserInterface/Views/InlineSwatch.js:
2372         (WI.InlineSwatch.prototype._swatchElementClicked):
2373         Change CodeMirror readOnly from "nocursor" to true. The former prevents the editor from
2374         being focused during selection, therefore preventing the content from being copied.
2375
2376 2017-08-17  Matt Baker  <mattbaker@apple.com>
2377
2378         Web Inspector: create better icon for Canvas Path navigation item
2379         https://bugs.webkit.org/show_bug.cgi?id=175274
2380
2381         Reviewed by Joseph Pecoraro.
2382
2383         * UserInterface/Images/Path.svg: Added.
2384         * UserInterface/Views/RecordingContentView.js:
2385         (WI.RecordingContentView):
2386
2387 2017-08-17  Nikita Vasilyev  <nvasilyev@apple.com>
2388
2389         Web Inspector: Styles: replace "Enter Class Name" with "Add New Class"
2390         https://bugs.webkit.org/show_bug.cgi?id=175686
2391
2392         Reviewed by Matt Baker.
2393
2394         "Enter Class Name" isn't very descriptive. It doesn't suggest what's going to happen after you enter a class name.
2395
2396         * Localizations/en.lproj/localizedStrings.js:
2397         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
2398         (WI.CSSStyleDetailsSidebarPanel.prototype.initialLayout):
2399
2400 2017-08-17  Ross Kirsling  <ross.kirsling@sony.com>
2401
2402         Web Inspector: Ensure three.js gets minified properly for production builds.
2403         https://bugs.webkit.org/show_bug.cgi?id=175452
2404
2405         Reviewed by Brian Burg.
2406
2407         * Scripts/copy-user-interface-resources.pl:
2408
2409 2017-08-14  Simon Fraser  <simon.fraser@apple.com>
2410
2411         Remove Proximity Events and related code
2412         https://bugs.webkit.org/show_bug.cgi?id=175545
2413
2414         Reviewed by Daniel Bates.
2415
2416         No platform enables Proximity Events, so remove code inside ENABLE(PROXIMITY_EVENTS)
2417         and other related code.
2418
2419         * UserInterface/Models/ScriptTimelineRecord.js:
2420         (WI.ScriptTimelineRecord.EventType.displayName):
2421
2422 2017-08-14  Matt Baker  <mattbaker@apple.com>
2423
2424         Web Inspector: Remove text-shadow and gradient backgrounds
2425         https://bugs.webkit.org/show_bug.cgi?id=175430
2426
2427         Reviewed by Brian Burg.
2428
2429         Inspector should more closely match flat system look. Remove text-shadow
2430         embossing and replace linear gradients in popover backgrounds and selected
2431         tree item background color.
2432
2433         * UserInterface/Views/CSSStyleDetailsSidebarPanel.css:
2434         (.sidebar > .panel.details.css-style > .content > .pseudo-classes > .group > label):
2435         * UserInterface/Views/CompletionSuggestionsView.css:
2436         (.completion-suggestions-container:not(:active) > .item.selected,):
2437         * UserInterface/Views/DebuggerDashboardView.css:
2438         (.toolbar .dashboard.debugger):
2439         * UserInterface/Views/HierarchicalPathComponent.css:
2440         (.hierarchical-path-component > .title):
2441         * UserInterface/Views/Main.css:
2442         (.bouncy-highlight):
2443         * UserInterface/Views/NavigationSidebarPanel.css:
2444         (.sidebar > .panel.navigation > .content .empty-content-placeholder > .message):
2445         * UserInterface/Views/Popover.js:
2446         (WI.Popover.prototype._drawBackground):
2447         * UserInterface/Views/RecordingTraceDetailsSidebarPanel.css:
2448         (.sidebar > .details.recording-trace > .content > .no-trace-data > .message):
2449         * UserInterface/Views/RulesStyleDetailsPanel.css:
2450         (.sidebar > .panel.details.css-style .rules .label):
2451         (.sidebar > .panel.details.css-style > .content.filter-in-progress > .rules.filter-non-matching > .no-filter-results > .no-filter-results-message):
2452         (@media (-webkit-min-device-pixel-ratio: 2)): Deleted.
2453         (.sidebar > .panel.details.css-style > .content.filter-in-progress > .rules .label.filter-matching-label,): Deleted.
2454         * UserInterface/Views/RulesStyleSpreadsheetDetailsPanel.css:
2455         (.style-spreadsheet .inherited):
2456         * UserInterface/Views/TimelineDataGrid.css:
2457         (.tree-outline.timeline-data-grid .item:hover):
2458         * UserInterface/Views/TimelineDataGrid.js:
2459         (WI.TimelineDataGrid.prototype._createPopoverContent):
2460         * UserInterface/Views/Variables.css:
2461         (:root):
2462
2463 2017-08-11  Nikita Vasilyev  <nvasilyev@apple.com>
2464
2465         Web Inspector: Clicking on suggestion hint should apply it, not dismiss
2466         https://bugs.webkit.org/show_bug.cgi?id=175409
2467
2468         Reviewed by Matt Baker.
2469
2470         Make clicking on the suggestion hint apply the completion, and place the text caret after it.
2471
2472         * UserInterface/Controllers/CodeMirrorCompletionController.js:
2473         (WI.CodeMirrorCompletionController.prototype._createCompletionHintMarker):
2474
2475 2017-08-11  Nikita Vasilyev  <nvasilyev@apple.com>
2476
2477         Web Inspector: Styles: Update the filter icon to match Xcode
2478         https://bugs.webkit.org/show_bug.cgi?id=175458
2479         <rdar://problem/33838660>
2480
2481         Reviewed by Matt Baker.
2482
2483         * UserInterface/Images/FilterFieldGlyph.svg:
2484         Half-pixel transform is necessary for a cleaner rasterisation.
2485
2486         * UserInterface/Views/FilterBar.css:
2487         (.filter-bar > input[type="search"]::-webkit-search-decoration):        
2488         (.sidebar > .panel.dom-node-details .details-section.dom-node-event-listeners > .header > .filter):
2489         ::-webkit-search-decoration is a flexbox item. Remove `vertical-align: bottom`,
2490         since it didn't do anything for it.
2491
2492         * UserInterface/Views/DOMNodeDetailsSidebarPanel.css:
2493         * UserInterface/Views/FilterBar.js:
2494         (WI.FilterBar):        
2495         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
2496         (WI.CSSStyleDetailsSidebarPanel.prototype.initialLayout):
2497         * UserInterface/Views/DebuggerSidebarPanel.js:
2498         * UserInterface/Views/LogContentView.js:
2499         (WI.LogContentView):
2500         * UserInterface/Views/NetworkSidebarPanel.js:
2501         (WI.NetworkSidebarPanel):
2502         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
2503         (WI.RecordingNavigationSidebarPanel):
2504         * UserInterface/Views/ResourceSidebarPanel.js:
2505         (WI.ResourceSidebarPanel):
2506         * UserInterface/Views/SearchSidebarPanel.js:
2507         (WI.SearchSidebarPanel):
2508         * UserInterface/Views/StorageSidebarPanel.js:
2509         (WI.StorageSidebarPanel):
2510         * UserInterface/Views/TimelineRecordingContentView.js:
2511         (WI.TimelineRecordingContentView):
2512         * Localizations/en.lproj/localizedStrings.js:        
2513         Replace placeholder text for all filter fields with "Filter".
2514
2515 2017-08-10  Ross Kirsling  <ross.kirsling@sony.com>
2516
2517         Web Inspector: Add three.js in preparation for layer visualization.
2518         https://bugs.webkit.org/show_bug.cgi?id=174798
2519
2520         Reviewed by Brian Burg.
2521
2522         * UserInterface/External/three.js/LICENSE: Added.
2523         * UserInterface/External/three.js/OrbitControls.js: Added.
2524         * UserInterface/External/three.js/three.js: Added.
2525
2526 2017-08-09  Nikita Vasilyev  <nvasilyev@apple.com>
2527
2528         Web Inspector: Styles: Add pre-populated data to spreadsheet-style view
2529         https://bugs.webkit.org/show_bug.cgi?id=174838
2530         <rdar://problem/33523220>
2531
2532         Reviewed by Matt Baker.
2533
2534         This patch adds static content to the experimental RulesStyleSpreadsheetDetailsPanel.
2535         The static content will be replaced with actual data in the follow up patches.
2536
2537         * UserInterface/Main.html:
2538         * UserInterface/Views/RulesStyleSpreadsheetDetailsPanel.css: Added.
2539         (.style-spreadsheet .style-rule):
2540         (.style-spreadsheet .selector-line):
2541         (.style-spreadsheet .selector):
2542         (.style-spreadsheet :matches(.selector .matched, .selector:focus)):
2543         (.style-spreadsheet .name):
2544         (.style-spreadsheet .value):
2545         (.style-spreadsheet :matches(.selector, .name, .value)):
2546         (.style-spreadsheet :matches(.selector, .name, .value):focus):
2547         (.style-spreadsheet .selector-inline):
2548         (.style-spreadsheet .property):
2549         (.style-spreadsheet .property-disabled,):
2550         (.style-spreadsheet .property-disabled :matches(.name, .value)):
2551         (.style-spreadsheet .styles-source):
2552         (.style-spreadsheet :matches(a, .node-link)):
2553         (.style-spreadsheet :matches(a, .node-link):hover):
2554         (.style-spreadsheet .inherited):
2555         (.style-spreadsheet .declarations):
2556         (.style-spreadsheet input[type="checkbox"]):
2557         (.style-spreadsheet input[type="checkbox"]:not(:checked)):
2558         (.style-spreadsheet .declarations:hover input[type="checkbox"]):
2559         * UserInterface/Views/RulesStyleSpreadsheetDetailsPanel.js:
2560
2561 2017-08-08  Devin Rousso  <drousso@apple.com>
2562
2563         Web Inspector: Canvas: support editing WebGL shaders
2564         https://bugs.webkit.org/show_bug.cgi?id=124211
2565         <rdar://problem/15448958>
2566
2567         Reviewed by Matt Baker.
2568
2569         * UserInterface/Models/ShaderProgram.js:
2570         (WI.ShaderProgram.prototype.updateVertexShader):
2571         (WI.ShaderProgram.prototype.updateFragmentShader):
2572         (WI.ShaderProgram.prototype._updateShader):
2573
2574         * UserInterface/Views/ShaderProgramContentView.js:
2575         (WI.ShaderProgramContentView):
2576         (WI.ShaderProgramContentView.prototype._contentDidChange):
2577
2578 2017-08-07  Devin Rousso  <drousso@apple.com>
2579
2580         Web Inspector: Preview Canvas path when viewing a recording
2581         https://bugs.webkit.org/show_bug.cgi?id=174967
2582
2583         Reviewed by Brian Burg.
2584
2585         * Localizations/en.lproj/localizedStrings.js:
2586         * UserInterface/Base/Setting.js:
2587
2588         * UserInterface/Views/RecordingContentView.js:
2589         (WI.RecordingContentView):
2590         (WI.RecordingContentView.supportsCanvasPathDebugging):
2591         (WI.RecordingContentView.prototype.get navigationItems):
2592         (WI.RecordingContentView.prototype.shown):
2593         (WI.RecordingContentView.prototype._generateContentCanvas2D):
2594         (WI.RecordingContentView.prototype._actionModifiesPath):
2595         (WI.RecordingContentView.prototype._updateCanvasPath):
2596         (WI.RecordingContentView.prototype._showPathButtonClicked):
2597         Show each segment of the current path as an overlay when the setting is enabled.
2598         Drive-by: fix forgotten function rename.
2599
2600         * UserInterface/Views/RecordingContentView.css:
2601         (.content-view:not(.tab).recording canvas.path):
2602
2603         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js:
2604         (WI.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
2605         Show the currentX/currentY in the current state.
2606
2607         * UserInterface/Models/RecordingAction.js:
2608         (WI.RecordingAction.isFunctionForType):
2609         (WI.RecordingAction.prototype.swizzle):
2610         Use Sets for better performance.
2611
2612 2017-08-04  Devin Rousso  <drousso@apple.com>
2613
2614         Web Inspector: add source view for WebGL shader programs
2615         https://bugs.webkit.org/show_bug.cgi?id=138593
2616         <rdar://problem/18936194>
2617
2618         Reviewed by Matt Baker.
2619
2620         Shader programs are now listed in the Resources sidebar as items within the owner Canvas
2621         context. When selected, the shown content view has two editors, one for the Vertex shader
2622         and one for the Fragment shader. These editors use CodeMirror's "clike" mode for GLSL syntax.
2623
2624         * Localizations/en.lproj/localizedStrings.js:
2625         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj:
2626         * WebInspectorUI.vcxproj/WebInspectorUI.vcxproj.filters:
2627         * UserInterface/Main.html:
2628
2629         * UserInterface/Controllers/CanvasManager.js:
2630         (WI.CanvasManager):
2631         (WI.CanvasManager.prototype.canvasRemoved):
2632         (WI.CanvasManager.prototype.programCreated):
2633         (WI.CanvasManager.prototype.programDeleted):
2634         (WI.CanvasManager.prototype._mainResourceDidChange):
2635
2636         * UserInterface/Models/Collection.js:
2637         * UserInterface/Models/Canvas.js:
2638         (WI.Canvas.prototype.get shaderProgramCollection)
2639
2640         * UserInterface/Models/ShaderProgram.js:
2641         (WI.ShaderProgram.prototype.requestVertexShaderSource):
2642         (WI.ShaderProgram.prototype.requestFragmentShaderSource):
2643         (WI.ShaderProgram.prototype._requestShaderSource):
2644
2645         * UserInterface/Views/CanvasTreeElement.js:
2646         (WI.CanvasTreeElement):
2647         (WI.CanvasTreeElement.prototype.onattach):
2648         (WI.CanvasTreeElement.prototype.ondetach):
2649         (WI.CanvasTreeElement.prototype.onpopulate):
2650         (WI.CanvasTreeElement.prototype._shaderProgramAdded):
2651         (WI.CanvasTreeElement.prototype._shaderProgramRemoved):
2652
2653         * UserInterface/Views/ShaderProgramTreeElement.js: Added.
2654         (WI.ShaderProgramTreeElement):
2655
2656         * UserInterface/Views/ShaderProgramContentView.js: Added.
2657         (WI.ShaderProgramContentView):
2658         (WI.ShaderProgramContentView.prototype.shown):
2659         (WI.ShaderProgramContentView.prototype.hidden):
2660         (WI.ShaderProgramContentView.prototype.closed):
2661         (WI.ShaderProgramContentView.prototype.get supportsSave):
2662         (WI.ShaderProgramContentView.prototype.get saveData):
2663         (WI.ShaderProgramContentView.prototype.get supportsSearch):
2664         (WI.ShaderProgramContentView.prototype.get numberOfSearchResults):
2665         (WI.ShaderProgramContentView.prototype.get hasPerformedSearch):
2666         (WI.ShaderProgramContentView.prototype.set automaticallyRevealFirstSearchResult):
2667         (WI.ShaderProgramContentView.prototype.performSearch):
2668         (WI.ShaderProgramContentView.prototype.searchCleared):
2669         (WI.ShaderProgramContentView.prototype.searchQueryWithSelection):
2670         (WI.ShaderProgramContentView.prototype.revealPreviousSearchResult):
2671         (WI.ShaderProgramContentView.prototype.revealNextSearchResult):
2672         (WI.ShaderProgramContentView.prototype.revealPosition):
2673         (WI.ShaderProgramContentView.prototype._editorFocused):
2674         (WI.ShaderProgramContentView.prototype._numberOfSearchResultsDidChange):
2675         * UserInterface/Views/ShaderProgramContentView.css: Added.
2676         (.content-view.shader-program > .text-editor.shader):
2677         (body[dir=ltr] .content-view.shader-program > .text-editor.shader.vertex,):
2678         (body[dir=ltr] .content-view.shader-program > .text-editor.shader.fragment,):
2679         (body[dir=ltr] .content-view.shader-program > .text-editor.shader + .text-editor.shader):
2680         (body[dir=rtl] .content-view.shader-program > .text-editor.shader + .text-editor.shader):
2681         (.content-view.shader-program > .text-editor.shader > .type-title):
2682         (.content-view.shader-program > .text-editor.shader > .CodeMirror):
2683
2684         * UserInterface/Images/DocumentGL.png: Added.
2685         * UserInterface/Images/DocumentGL@2x.png: Added.
2686         * UserInterface/Views/ResourceIcons.css:
2687         (.shader-program .icon):
2688
2689         * UserInterface/Base/Main.js:
2690         * UserInterface/Views/ContentView.js:
2691         (WI.ContentView.createFromRepresentedObject):
2692         (WI.ContentView.isViewable):
2693         * UserInterface/Views/ResourceSidebarPanel.js:
2694         (WI.ResourceSidebarPanel.prototype.matchTreeElementAgainstCustomFilters.match):
2695         (WI.ResourceSidebarPanel.prototype.matchTreeElementAgainstCustomFilters):
2696         (WI.ResourceSidebarPanel.prototype._treeSelectionDidChange):
2697         * UserInterface/Views/ResourcesTabContentView.js:
2698         (WI.ResourcesTabContentView.prototype.canShowRepresentedObject):
2699         Plumbing for displaying ShaderProgram content.
2700
2701         * UserInterface/Views/TextEditor.js:
2702         (WebInspector.TextEditor):
2703         (WebInspector.TextEditor.prototype._editorFocused):
2704
2705         * Scripts/update-codemirror-resources.rb:
2706         * UserInterface/External/CodeMirror/clike.js: Added.
2707         Add C-like mode for highlighting GLSL.
2708
2709 2017-08-03  Joseph Pecoraro  <pecoraro@apple.com>
2710
2711         JSContext Inspector: Scripts sometimes do not show in resources tab
2712         https://bugs.webkit.org/show_bug.cgi?id=175153
2713         <rdar://problem/33708683>
2714
2715         Reviewed by Matt Baker.
2716
2717         * UserInterface/Views/ResourceSidebarPanel.js:
2718         (WI.ResourceSidebarPanel.prototype.initialLayout):
2719         When the ResourceSidebar is lazily created, be sure to add any scripts
2720         to the sidebar that are not backed by Resources.
2721
2722         (WI.ResourceSidebarPanel.prototype._scriptWasAdded):
2723         (WI.ResourceSidebarPanel.prototype._addScript):
2724         Extract so it can be used outside of an event handler.
2725
2726 2017-08-03  Devin Rousso  <drousso@apple.com>
2727
2728         Web Inspector: add button to open Inspector^2
2729         https://bugs.webkit.org/show_bug.cgi?id=175108
2730
2731         Reviewed by Brian Burg.
2732
2733         * UserInterface/Debug/Bootstrap.js:
2734         (updateDebugUI):
2735         (WI.runBootstrapOperations):
2736
2737         * UserInterface/Views/ButtonToolbarItem.js:
2738         (WI.ButtonToolbarItem):
2739         (WI.ButtonToolbarItem.prototype.get label): Deleted.
2740         (WI.ButtonToolbarItem.prototype.set label): Deleted.
2741         * UserInterface/Views/ButtonToolbarItem.css:
2742         (.toolbar .item.button):
2743         (.toolbar .item.button:not(.disabled):active):
2744         (.toolbar .item.button:not(.disabled):matches(:focus, .activate.activated)):
2745         (.toolbar .item.button:not(.disabled):active:matches(:focus, .activate.activated)):
2746         (.toolbar .item.button > .glyph):
2747         (.toolbar .item.button:not(.disabled):active > .glyph): Deleted.
2748         (.toolbar .item.button:not(.disabled):matches(:focus, .activate.activated) > .glyph): Deleted.
2749         (.toolbar .item.button:not(.disabled):active:matches(:focus, .activate.activated) > .glyph): Deleted.
2750         (.toolbar .item.button > .label): Deleted.
2751         * UserInterface/Views/ActivateButtonToolbarItem.js:
2752         (WI.ActivateButtonToolbarItem):
2753         (WI.ActivateButtonToolbarItem.prototype.get label): Deleted.
2754         (WI.ActivateButtonToolbarItem.prototype.set label): Deleted.
2755         * UserInterface/Base/Main.js:
2756         (WI.contentLoaded):
2757         Remove unused `label` parameter from Toolbar objects.
2758
2759 2017-08-03  Matt Baker  <mattbaker@apple.com>
2760
2761         Web Inspector: Instrument WebGLProgram created/deleted
2762         https://bugs.webkit.org/show_bug.cgi?id=175059
2763
2764         Reviewed by Devin Rousso.
2765
2766         This patch adds frontend support for shader program instrumentation.
2767         The frontend creates a ShaderProgram model object for each WebGLProgram.
2768         Since only canvases with a WebGL context have programs, the Canvas model
2769         object does not contain any logic specific to programs. CanvasManager
2770         dispatches program added/removed events, and the parent Canvas can be
2771         accessed from ShaderProgram but not the other way around.
2772
2773         * UserInterface/Controllers/CanvasManager.js:
2774         (WI.CanvasManager):
2775         (WI.CanvasManager.prototype.get shaderPrograms):
2776         (WI.CanvasManager.prototype.canvasRemoved):
2777         (WI.CanvasManager.prototype.programCreated):
2778         (WI.CanvasManager.prototype.programDeleted):
2779         (WI.CanvasManager.prototype._mainResourceDidChange):
2780         (WI.CanvasManager.prototype._dispatchShaderProgramRemoved):
2781
2782         * UserInterface/Main.html:
2783
2784         * UserInterface/Models/Canvas.js:
2785         (WI.Canvas.prototype.nextShaderProgramDisplayNumber):
2786         (WI.Canvas):
2787
2788         * UserInterface/Models/ShaderProgram.js: Added.
2789         (WI.ShaderProgram):
2790         (WI.ShaderProgram.prototype.get identifier):
2791         (WI.ShaderProgram.prototype.get canvas):
2792         (WI.ShaderProgram.prototype.get displayName):
2793
2794         * UserInterface/Protocol/CanvasObserver.js:
2795         (WI.CanvasObserver.prototype.programCreated):
2796         (WI.CanvasObserver.prototype.programDeleted):
2797         (WI.CanvasObserver):
2798
2799         * UserInterface/Test.html:
2800
2801 2017-08-03  Joseph Pecoraro  <pecoraro@apple.com>
2802
2803         JSContext Inspector: Recording tab should not be available in New Tab picker
2804         https://bugs.webkit.org/show_bug.cgi?id=175155
2805
2806         Reviewed by Brian Burg.
2807
2808         * UserInterface/Views/RecordingTabContentView.js:
2809         (WI.RecordingTabContentView.isTabAllowed):
2810         Only allow the Recording Tab if we have a CanvasAgent.
2811
2812 2017-08-02  Devin Rousso  <drousso@apple.com>
2813
2814         Web Inspector: add stack trace information for each RecordingAction
2815         https://bugs.webkit.org/show_bug.cgi?id=174663
2816
2817         Reviewed by Joseph Pecoraro.
2818
2819         * Localizations/en.lproj/localizedStrings.js:
2820         * UserInterface/Main.html:
2821
2822         * UserInterface/Models/Recording.js:
2823         (WI.Recording.prototype.swizzle):
2824         Add Array type for swizzling array values.
2825
2826         * UserInterface/Models/RecordingAction.js:
2827         (WI.RecordingAction):
2828         (WI.RecordingAction.fromPayload):
2829         (WI.RecordingAction.prototype.get trace):
2830         (WI.RecordingAction.prototype.swizzle):
2831         (WI.RecordingAction.prototype.toJSON):
2832
2833         * UserInterface/Views/RecordingTraceDetailsSidebarPanel.js: Added.
2834         (WI.RecordingTraceDetailsSidebarPanel):
2835         (WI.RecordingTraceDetailsSidebarPanel.disallowInstanceForClass):
2836         (WI.RecordingTraceDetailsSidebarPanel.prototype.inspect):
2837         (WI.RecordingTraceDetailsSidebarPanel.prototype.set recording):
2838         (WI.RecordingTraceDetailsSidebarPanel.prototype.updateActionIndex):
2839         * UserInterface/Views/RecordingTraceDetailsSidebarPanel.css: Added.
2840         (.sidebar > .panel.details.recording-trace > .content > .call-frame):
2841         (.sidebar > .details.recording-trace > .content > .no-trace-data):
2842         (.sidebar > .details.recording-trace > .content > .no-trace-data > .message):
2843
2844         * UserInterface/Views/RecordingTabContentView.js:
2845         (WI.RecordingTabContentView):
2846
2847         * UserInterface/Views/RecordingActionTreeElement.js:
2848         (WI.RecordingActionTreeElement.prototype.populateContextMenu):
2849
2850         * UserInterface/Views/CallFrameView.css:
2851         (.call-frame):
2852         (body[dir=ltr] .call-frame .icon):
2853         (body[dir=rtl] .call-frame .icon):
2854         Apply the same trailing margin for CallFrameView icons as TreeElement.
2855
2856 2017-08-02  Devin Rousso  <drousso@apple.com>
2857
2858         Web Inspector: add TreeElement virtualization for the Recording tab
2859         https://bugs.webkit.org/show_bug.cgi?id=174968
2860
2861         Reviewed by Joseph Pecoraro.
2862
2863         * UserInterface/Views/RecordingNavigationSidebarPanel.js:
2864         (WI.RecordingNavigationSidebarPanel):
2865
2866         * UserInterface/Views/TreeOutline.js:
2867         (WI.TreeOutline):
2868         (WI.TreeOutline.prototype.get virtualized):
2869         (WI.TreeOutline.prototype.registerScrollVirtualizer):
2870         (WI.TreeOutline.prototype.updateVirtualizedElements.walk):
2871         (WI.TreeOutline.prototype.updateVirtualizedElements):
2872         Add spacer elements before and after the TreeOutline element that will size to ensure that
2873         the TreeOutline node still takes up the same amount of space after some of the TreeElements
2874         are removed. Whenever the scroll of the container view changes, recalculate the visible area
2875         and add/remove TreeElements based on whether they would be in that. This is only possible if
2876         every TreeElement has the same vertical height, which is given when setting up the scroll
2877         listener on the container view.
2878
2879         * UserInterface/Views/TreeElement.js:
2880         (WI.TreeElement.prototype.set hidden):
2881         (WI.TreeElement.prototype._attach):
2882         (WI.TreeElement.prototype.collapse):
2883         (WI.TreeElement.prototype.expand):
2884         (WI.TreeElement.prototype.reveal):
2885         If the TreeOutline is being virtualized, don't add each TreeElement's node to the DOM. They
2886         will be added at the end of the frame (via setTimeout) if they are within the visible + padding
2887         area of the TreeOutline.
2888
2889 2017-08-01  Devin Rousso  <drousso@apple.com>
2890
2891         Web Inspector: simplify WebInspector with WI
2892         https://bugs.webkit.org/show_bug.cgi?id=175058
2893
2894         Reviewed by Joseph Pecoraro.
2895
2896         * .eslintrc:
2897
2898         * Tools/PrettyPrinting/FormatterDebug.js:
2899         * Tools/PrettyPrinting/index.html:
2900
2901         * UserInterface/Main.html:
2902         * UserInterface/Test.html:
2903
2904         * UserInterface/Base/*.js:
2905         * UserInterface/Controllers/*.js:
2906         * UserInterface/Debug/*.js:
2907         * UserInterface/Models/*.js:
2908         * UserInterface/Protocol/*.js:
2909         * UserInterface/Proxies/*.js:
2910         * UserInterface/Test/*.js:
2911         * UserInterface/Views/*.js:
2912
2913 2017-08-01  Devin Rousso  <drousso@apple.com>
2914
2915         Web Inspector: create Recording tab for displaying recordings
2916         https://bugs.webkit.org/show_bug.cgi?id=174484
2917
2918         Reviewed by Joseph Pecoraro.
2919
2920         * Localizations/en.lproj/localizedStrings.js:
2921         * UserInterface/Main.html:
2922         * UserInterface/Test.html:
2923
2924         * UserInterface/Controllers/CanvasManager.js:
2925         (WebInspector.CanvasManager.prototype.recordingFinished):
2926         * UserInterface/Models/Canvas.js:
2927         (WebInspector.Canvas.prototype.toggleRecording):
2928
2929         * UserInterface/Models/Recording.js:
2930         (WebInspector.Recording):
2931         (WebInspector.Recording.synthesizeError):
2932         (WebInspector.Recording.prototype.get actions):
2933         (WebInspector.Recording.prototype.get source):
2934         (WebInspector.Recording.prototype.set source):
2935         (WebInspector.Recording.prototype.swizzle):
2936
2937         * UserInterface/Models/RecordingAction.js:
2938         (WebInspector.RecordingAction):
2939         (WebInspector.RecordingAction.isFunctionForType):
2940         (WebInspector.RecordingAction.get name):
2941         (WebInspector.RecordingAction.get parameters):
2942         (WebInspector.RecordingAction.prototype.get valid):
2943         (WebInspector.RecordingAction.prototype.set valid):
2944         (WebInspector.RecordingAction.get isFunction):
2945         (WebInspector.RecordingAction.get isGetter):
2946         (WebInspector.RecordingAction.get isVisual):
2947         (WebInspector.RecordingAction.get stateModifiers):
2948         (WebInspector.RecordingAction.prototype.swizzle):
2949         (WebInspector.RecordingAction.prototype.parameterSwizzleTypeForTypeAtIndex):
2950
2951         * UserInterface/Models/RecordingInitialStateAction.js: Added.
2952         (WebInspector.RecordingInitialStateAction):
2953
2954         * UserInterface/Views/RecordingTabContentView.js: Added.
2955         (WebInspector.RecordingTabContentView):
2956         (WebInspector.RecordingTabContentView.tabInfo):
2957         (WebInspector.RecordingTabContentView.prototype.get type):
2958         (WebInspector.RecordingTabContentView.prototype.canShowRepresentedObject):
2959         (WebInspector.RecordingTabContentView.prototype.showRepresentedObject):
2960         (WebInspector.RecordingTabContentView.prototype.restoreStateFromCookie):
2961         (WebInspector.RecordingTabContentView.prototype.saveStateToCookie):
2962         (WebInspector.RecordingTabContentView.prototype.closed):
2963         (WebInspector.RecordingTabContentView.prototype._updateActionIndex):
2964         (WebInspector.RecordingTabContentView.prototype._scrubberNavigationItemValueChanged):
2965         (WebInspector.RecordingTabContentView.prototype._navigationSidebarImport):
2966         (WebInspector.RecordingTabContentView.prototype._navigationSidebarTreeOutlineSelectionChanged):
2967
2968         * UserInterface/Views/RecordingContentView.js: Added.
2969         (WebInspector.RecordingContentView):
2970         (WebInspector.RecordingContentView.prototype.get navigationItems):
2971         (WebInspector.RecordingContentView.prototype.updateActionIndex):
2972         (WebInspector.RecordingContentView.prototype.shown):
2973         (WebInspector.RecordingContentView.prototype.get supplementalRepresentedObjects):
2974         (WebInspector.RecordingContentView.prototype._generateContentCanvas2D):
2975         (WebInspector.RecordingContentView.prototype._applyAction):
2976         (WebInspector.RecordingContentView.prototype._updateImageGrid):
2977         (WebInspector.RecordingContentView.prototype._showGridButtonClicked):
2978         * UserInterface/Views/RecordingContentView.css: Copied from Source/WebInspectorUI/UserInterface/Views/CanvasContentView.css.
2979         (.content-view:not(.tab).recording):
2980         (.content-view:not(.tab).recording > .preview-container):
2981         (.content-view:not(.tab).recording canvas):
2982
2983         * UserInterface/Views/RecordingNavigationSidebarPanel.js: Added.
2984         (WebInspector.RecordingNavigationSidebarPanel):
2985         (WebInspector.RecordingNavigationSidebarPanel.disallowInstanceForClass):
2986         (WebInspector.RecordingNavigationSidebarPanel.prototype.set recording):
2987         (WebInspector.RecordingNavigationSidebarPanel.prototype.updateActionIndex):
2988         (WebInspector.RecordingNavigationSidebarPanel.prototype.initialLayout):
2989         (WebInspector.RecordingNavigationSidebarPanel.prototype._importNavigationItemClicked):
2990         (WebInspector.RecordingNavigationSidebarPanel.prototype._exportNavigationItemClicked):
2991         * UserInterface/Views/RecordingNavigationSidebarPanel.css: Added.
2992         (.sidebar > .panel.navigation.recording > :matches(.content, .empty-content-placeholder)):
2993         (.sidebar > .panel.navigation.recording > .content > .tree-outline):
2994         (.sidebar > .panel.navigation.recording > .content > .tree-outline > .item.parent:not(.action, .selected).expanded):
2995         (.sidebar > .panel.navigation.recording > .content > .tree-outline .item.action:not(.initial-state)::before):
2996         (body[dir=ltr] .sidebar > .panel.navigation.recording > .content > .tree-outline .item.action:not(.initial-state)::before):
2997         (body[dir=rtl] .sidebar > .panel.navigation.recording > .content > .tree-outline .item.action:not(.initial-state)::before):
2998         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="2"] .item.action:not(.initial-state)::before):
2999         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="3"] .item.action:not(.initial-state)::before):
3000         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="4"] .item.action:not(.initial-state)::before):
3001         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="5"] .item.action:not(.initial-state)::before):
3002         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="6"] .item.action:not(.initial-state)::before):
3003         (.sidebar > .panel.navigation.recording > .content > .tree-outline[data-indent="7"] .item.action:not(.initial-state)::before):
3004         (.sidebar > .panel.navigation.recording > .content .action > .icon):
3005         (.sidebar > .panel.navigation.recording > .content .action.function > .icon):
3006         (.sidebar > .panel.navigation.recording > .content .action.attribute.getter > .icon):
3007         (.sidebar > .panel.navigation.recording > .content .tree-outline:matches(:focus, .force-focus) .action.attribute.getter.selected > .icon):
3008         (.sidebar > .panel.navigation.recording > .content .action.attribute.boolean > .icon):
3009         (.sidebar > .panel.navigation.recording > .content .action.attribute.number > .icon):
3010         (.sidebar > .panel.navigation.recording > .content .action.attribute.object > .icon):
3011         (.sidebar > .panel.navigation.recording > .content .action.attribute.string > .icon):
3012         (.sidebar > .panel.navigation.recording > .content > .tree-outline > .item.parent:not(.action) > .icon):
3013         (.sidebar > .panel.navigation.recording > .content .action:matches(.invalid, .missing) > .icon):
3014         (body[dir=ltr] .sidebar > .panel.navigation.recording > .content .action:not(.initial-state) > .icon):
3015         (body[dir=rtl] .sidebar > .panel.navigation.recording > .content .action:not(.initial-state) > .icon):
3016         (.sidebar > .panel.navigation.recording > .content .action.visual:not(.selected, .invalid)):
3017         (.sidebar > .panel.navigation.recording > .content .action:not(.selected, .initial-state) > .titles .parameter.swizzled):
3018         (.sidebar > .panel.navigation.recording > .content .action.invalid:not(.selected, .initial-state) > .titles .name,):
3019
3020         * UserInterface/Views/RecordingStateDetailsSidebarPanel.js: Added.
3021         (WebInspector.RecordingStateDetailsSidebarPanel):
3022         (WebInspector.RecordingStateDetailsSidebarPanel.disallowInstanceForClass):
3023         (WebInspector.RecordingStateDetailsSidebarPanel.prototype.inspect):
3024         (WebInspector.RecordingStateDetailsSidebarPanel.prototype.set recording):
3025         (WebInspector.RecordingStateDetailsSidebarPanel.prototype.updateActionIndex):
3026         (WebInspector.RecordingStateDetailsSidebarPanel.prototype._generateDetailsCanvas2D):
3027         * UserInterface/Views/RecordingStateDetailsSidebarPanel.css: Added.
3028         (.sidebar > .panel.details.recording-state > .content > .data-grid):
3029         (.sidebar > .panel.details.recording-state > .content > .data-grid tr.modified):
3030         (.sidebar > .panel.details.recording-state > .content > .data-grid tr:not(.selected).non-standard):
3031         (.sidebar > .panel.details.recording-state > .content > .data-grid tr:not(.selected) .unavailable):
3032
3033         * UserInterface/Views/RecordingActionTreeElement.js: Added.
3034         (WebInspector.RecordingActionTreeElement):
3035         (WebInspector.RecordingActionTreeElement._generateDOM):
3036         (WebInspector.RecordingActionTreeElement.prototype.get index):
3037         (WebInspector.RecordingActionTreeElement.get filterableData):
3038         (WebInspector.RecordingActionTreeElement.prototype.get filterableData):
3039         (WebInspector.RecordingActionTreeElement.prototype.onattach):
3040         (WebInspector.RecordingActionTreeElement.prototype.populateContextMenu):
3041
3042         * UserInterface/Base/Main.js:
3043         (WebInspector.contentLoaded):
3044         (WebInspector.instanceForClass):
3045
3046         * UserInterface/Base/FileUtilites.js: Added.
3047         (WebInspector.saveDataToFile): Moved from UserInterface/Base/Main.js
3048         (WebInspector.loadDataFromFile):
3049
3050         * UserInterface/Views/ButtonNavigationItem.js:
3051         (WebInspector.ButtonNavigationItem.prototype._mouseClicked):
3052         Send the native event as part of the data.
3053
3054         * UserInterface/Views/CanvasContentView.js:
3055         (WebInspector.CanvasContentView):
3056         (WebInspector.CanvasContentView.prototype.get navigationItems):
3057         (WebInspector.CanvasContentView.prototype.initialLayout):
3058         (WebInspector.CanvasContentView.prototype.closed):
3059         (WebInspector.CanvasContentView.prototype._toggleRecording):
3060         (WebInspector.CanvasContentView.prototype._recordingFinished):
3061         * UserInterface/Views/CanvasContentView.css:
3062         (.content-view.canvas):
3063
3064         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
3065         (WebInspector.CanvasDetailsSidebarPanel.prototype.inspect):
3066
3067         * UserInterface/Views/ContentBrowser.js:
3068         (WebInspector.ContentBrowser):
3069         (WebInspector.ContentBrowser.prototype._updateContentViewNavigationItems):
3070         * UserInterface/Views/ContentBrowserTabContentView.js:
3071         (WebInspector.ContentBrowserTabContentView):
3072         * UserInterface/Views/ContentView.js:
3073         (WebInspector.ContentView.createFromRepresentedObject):
3074         (WebInspector.ContentView.isViewable):
3075         * UserInterface/Views/ScrubberNavigationItem.js: Added.
3076         (WebInspector.ScrubberNavigationItem):
3077         (WebInspector.ScrubberNavigationItem.prototype.get value):
3078         (WebInspector.ScrubberNavigationItem.prototype.set value):
3079         (WebInspector.ScrubberNavigationItem.prototype.get min):
3080         (WebInspector.ScrubberNavigationItem.prototype.set min):
3081         (WebInspector.ScrubberNavigationItem.prototype.get max):
3082         (WebInspector.ScrubberNavigationItem.prototype.set max):
3083         (WebInspector.ScrubberNavigationItem.prototype.set disabled):
3084         (WebInspector.ScrubberNavigationItem.prototype.get additionalClassNames):
3085         (WebInspector.ScrubberNavigationItem.prototype._sliderChanged):
3086         * UserInterface/Views/ScrubberNavigationItem.css: Added.
3087         (.navigation-bar .item.scrubber):
3088         (.navigation-bar .item.scrubber > input):
3089         (.navigation-bar .item.scrubber > input[disabled]):
3090         Allow the flexible space to be replaced with a navigation item at construction.
3091
3092         * UserInterface/Views/DataGridNode.js:
3093         (WebInspector.DataGridNode):
3094         (WebInspector.DataGridNode.prototype.get element):
3095         Allow a list of CSS classes to be added to the node's element.
3096
3097         * UserInterface/Views/SettingsTabContentView.js:
3098         (WebInspector.SettingsTabContentView.prototype.initialLayout):
3099         (WebInspector.SettingsTabContentView.prototype._createExperimentalSettingsView.listenForChange):
3100         (WebInspector.SettingsTabContentView.prototype._createExperimentalSettingsView):
3101         (WebInspector.SettingsTabContentView.prototype._createDebugSettingsView):
3102         Move experimental settings to their own panel.
3103
3104         * UserInterface/Views/TabContentView.js:
3105         (WebInspector.TabContentView.prototype.get navigationSidebarPanel):
3106         Save the NavigationSidebarPanel after it's constructed.
3107
3108         * UserInterface/Base/Utilities.js:
3109         (Number.countDigits):
3110
3111         * UserInterface/Images/Recording.svg: Added.
3112         * UserInterface/Images/RenderingFrame.svg: Renamed from Source/WebInspectorUI/UserInterface/Images/TimelineRecordRenderingFrame.svg.
3113         * UserInterface/Images/gtk/RenderingFrame.svg: Renamed from Source/WebInspectorUI/UserInterface/Images/gtk/TimelineRecordRenderingFrame.svg.
3114         * UserInterface/Views/TimelineIcons.css:
3115         (.rendering-frame-record .icon):
3116
3117         * UserInterface/Views/DOMTreeOutline.css:
3118         (@keyframes node-state-changed):
3119         * UserInterface/Views/Main.css:
3120         (:matches(img, canvas).show-grid):
3121         (img.show-grid): Deleted.
3122         * UserInterface/Views/NavigationBar.css:
3123         (.navigation-bar):
3124         * UserInterface/Views/NetworkSidebarPanel.css:
3125         (.sidebar > .panel.navigation.network.network-grid-content-view-showing > .content > .tree-outline):
3126         * UserInterface/Views/TimelineTabContentView.css:
3127         (.timeline.tab.content-view .navigation-bar > .item.radio):
3128         * UserInterface/Views/TimelineView.css:
3129         (.panel.navigation.timeline.timeline-recording-content-view-showing > .content > .tree-outline):
3130         * UserInterface/Views/Variables.css:
3131         (:root):
3132         Create CSS variables for the DOM modification flash color and the color striping.
3133
3134 2017-07-28  Devin Rousso  <drousso@apple.com>
3135
3136         Web Inspector: Cleanup unused/invalid parameters for TreeElements
3137         https://bugs.webkit.org/show_bug.cgi?id=173987
3138
3139         Reviewed by Brian Burg.
3140
3141         * UserInterface/Views/TreeElement.js:
3142         * UserInterface/Views/GeneralTreeElement.js:
3143
3144         * UserInterface/Views/ApplicationCacheFrameTreeElement.js:
3145         * UserInterface/Views/BreakpointTreeElement.js:
3146         * UserInterface/Views/CSSStyleSheetTreeElement.js:
3147         * UserInterface/Views/CallFrameTreeElement.js:
3148         * UserInterface/Views/ContentFlowTreeElement.js:
3149         * UserInterface/Views/DOMNodeTreeElement.js:
3150         * UserInterface/Views/DatabaseTableTreeElement.js:
3151         * UserInterface/Views/DatabaseTreeElement.js:
3152         * UserInterface/Views/FolderTreeElement.js:
3153         * UserInterface/Views/FolderizedTreeElement.js:
3154         * UserInterface/Views/FrameTreeElement.js:
3155         * UserInterface/Views/IndexedDatabaseObjectStoreIndexTreeElement.js:
3156         * UserInterface/Views/IndexedDatabaseObjectStoreTreeElement.js:
3157         * UserInterface/Views/IndexedDatabaseTreeElement.js:
3158         * UserInterface/Views/IssueTreeElement.js:
3159         * UserInterface/Views/ObjectTreeBaseTreeElement.js:
3160         * UserInterface/Views/ProfileNodeTreeElement.js:
3161         * UserInterface/Views/ResourceTreeElement.js:
3162         * UserInterface/Views/ScriptTreeElement.js:
3163         * UserInterface/Views/SearchResultTreeElement.js:
3164         * UserInterface/Views/SourceCodeTreeElement.js:
3165         * UserInterface/Views/SourceMapResourceTreeElement.js:
3166         * UserInterface/Views/StorageTreeElement.js:
3167         * UserInterface/Views/TimelineRecordTreeElement.js:
3168         * UserInterface/Views/TypeTreeElement.js:
3169
3170 2017-07-26  Devin Rousso  <drousso@apple.com>
3171
3172         Uncaught Exception: undefined is not an object (evaluating 'this._memoryRow.value = Number.bytesToString(this._canvas.memoryCost)')
3173         https://bugs.webkit.org/show_bug.cgi?id=174823
3174
3175         Reviewed by Joseph Pecoraro.
3176
3177         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
3178         (WebInspector.CanvasDetailsSidebarPanel.prototype._refreshIdentitySection):
3179         (WebInspector.CanvasDetailsSidebarPanel.prototype._refreshSourceSection):
3180         (WebInspector.CanvasDetailsSidebarPanel.prototype._refreshAttributesSection):
3181         (WebInspector.CanvasDetailsSidebarPanel.prototype._refreshCSSCanvasSection):
3182         (WebInspector.CanvasDetailsSidebarPanel.prototype._formatMemoryRow):
3183         Early return if the view has not called initialLayout, as the rows might not have been
3184         constructed yet.
3185
3186         * UserInterface/Views/View.js:
3187         (WebInspector.View.prototype.get didInitialLayout): Added.
3188
3189 2017-07-26  Devin Rousso  <drousso@apple.com>
3190
3191         Web Inspector: create protocol for recording Canvas contexts
3192         https://bugs.webkit.org/show_bug.cgi?id=174481
3193
3194         Reviewed by Joseph Pecoraro.
3195
3196         Create model objects that effectively mirror the protocol objects sent for Canvas recordings.
3197
3198         * .eslintrc:
3199         * UserInterface/Main.html:
3200         * UserInterface/Test.html:
3201
3202         * UserInterface/Controllers/CanvasManager.js:
3203         (WebInspector.CanvasManager.prototype.recordingFinished):
3204         * UserInterface/Protocol/CanvasObserver.js:
3205         (WebInspector.CanvasObserver.prototype.recordingFinished):
3206
3207         * UserInterface/Models/Recording.js: Added.
3208         (WebInspector.Recording):
3209         (WebInspector.Recording.fromPayload):
3210         (WebInspector.Recording.prototype.get type):
3211         (WebInspector.Recording.prototype.get initialState):
3212         (WebInspector.Recording.prototype.get frames):
3213         (WebInspector.Recording.prototype.get data):
3214         (WebInspector.Recording.prototype.toJSON):
3215
3216         * UserInterface/Models/RecordingAction.js: Added.
3217         (WebInspector.RecordingAction):
3218         (WebInspector.RecordingAction.fromPayload):
3219         (WebInspector.RecordingAction.prototype.get name):
3220         (WebInspector.RecordingAction.prototype.get parameters):
3221         (WebInspector.RecordingAction.prototype.toJSON):
3222
3223         * UserInterface/Models/RecordingFrame.js: Added.
3224         (WebInspector.RecordingFrame):
3225         (WebInspector.RecordingFrame.fromPayload):
3226         (WebInspector.RecordingFrame.prototype.get actions):
3227         (WebInspector.RecordingFrame.prototype.get incomplete):
3228         (WebInspector.RecordingFrame.prototype.toJSON):
3229
3230 2017-07-26  Brian Burg  <bburg@apple.com>
3231
3232         Remove WEB_TIMING feature flag
3233         https://bugs.webkit.org/show_bug.cgi?id=174795
3234
3235         Reviewed by Alex Christensen.
3236
3237         Remove fallback for ports that lack WEB_TIMING.
3238
3239         * UserInterface/Base/Utilities.js:
3240         (timestamp): Deleted.
3241         * UserInterface/Protocol/Connection.js:
3242         (InspectorBackend.Connection.prototype._dispatchResponse):
3243         (InspectorBackend.Connection.prototype._dispatchEvent):
3244         (InspectorBackend.Connection.prototype._sendCommandToBackendWithCallback):
3245         (InspectorBackend.Connection.prototype._sendCommandToBackendExpectingPromise):
3246         * UserInterface/Protocol/MessageDispatcher.js:
3247         (WebInspector.dispatchNextQueuedMessageFromBackend):
3248
3249 2017-07-25  Joseph Pecoraro  <pecoraro@apple.com>
3250
3251         Web Inspector: Don't output "No message" for multi-value logs like console.log(x, y)
3252         https://bugs.webkit.org/show_bug.cgi?id=174842
3253
3254         Reviewed by Matt Baker.
3255
3256         * Localizations/en.lproj/localizedStrings.js:
3257         Removed "No message".
3258
3259         * UserInterface/Views/ConsoleMessageView.js:
3260         (WebInspector.ConsoleMessageView.prototype._appendFormattedArguments):
3261         Track whether or not outputting the next parameter will need a divider
3262         in front of it or not.
3263
3264 2017-07-25  Joseph Pecoraro  <pecoraro@apple.com>
3265
3266         Web Inspector: Fix warnings about console.assert lines without semicolons
3267         https://bugs.webkit.org/show_bug.cgi?id=174840
3268
3269         Reviewed by Brian Burg.
3270
3271         * UserInterface/Views/SettingsTabContentView.js:
3272         (WebInspector.SettingsTabContentView.prototype.set selectedSettingsView):
3273         (WebInspector.SettingsTabContentView.prototype.setSettingsViewVisible):
3274         Add semicolon to assert lines so they can be stripped in optimized builds.
3275
3276 2017-07-25  Joseph Pecoraro  <pecoraro@apple.com>
3277
3278         Web Inspector: Inline multiple console log values if they are simple
3279         https://bugs.webkit.org/show_bug.cgi?id=174746
3280         <rdar://problem/33469376>
3281
3282         Reviewed by Matt Baker.
3283
3284         * UserInterface/Models/IssueMessage.js:
3285         * UserInterface/Protocol/RemoteObject.js:
3286         (WebInspector.RemoteObject.type): Deleted.
3287         Remove this as it isn't as useful as directly checking the type.
3288
3289         * UserInterface/Views/ConsoleMessageView.js:
3290         (WebInspector.ConsoleMessageView.prototype._appendExtraParameters):
3291         (WebInspector.ConsoleMessageView.prototype._appendFormattedArguments):
3292         (WebInspector.ConsoleMessageView.prototype._hasSimpleDisplay):
3293         (WebInspector.ConsoleMessageView.prototype._isStackTrace):
3294         For leading primitive/simple values, display them inline on the console message.
3295
3296         * UserInterface/Views/FormattedValue.js:
3297         (WebInspector.FormattedValue.hasSimpleDisplay):
3298         Provide a helper to determine if a formatted value will be simple.
3299
3300 2017-07-25  Nikita Vasilyev  <nvasilyev@apple.com>
3301
3302         Web Inspector: Styles: Add a switch for Spreadsheet model style editor to experimental settings
3303         https://bugs.webkit.org/show_bug.cgi?id=174741
3304         <rdar://problem/33467954>
3305
3306         Reviewed by Brian Burg.
3307
3308         Show a blank panel when Spreadsheet Style Editor is enabled.
3309
3310         * UserInterface/Base/Setting.js:
3311         * UserInterface/Main.html:
3312         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
3313         (WebInspector.CSSStyleDetailsSidebarPanel):
3314         (WebInspector.CSSStyleDetailsSidebarPanel.prototype.computedStyleDetailsPanelShowProperty):
3315         * UserInterface/Views/RulesStyleSpreadsheetDetailsPanel.js: Added.
3316         (WebInspector.RulesStyleSpreadsheetDetailsPanel):
3317         (WebInspector.RulesStyleSpreadsheetDetailsPanel.prototype.filterDidChange):
3318         (WebInspector.RulesStyleSpreadsheetDetailsPanel.prototype.scrollToSectionAndHighlightProperty):
3319
3320         * UserInterface/Views/SettingsTabContentView.css:
3321         (.content-view.settings > .settings-view > .container.hidden):
3322         (.content-view.settings > .settings-view > .container-centered):
3323         (.content-view.settings > .settings-view > .container button):
3324         * UserInterface/Views/SettingsTabContentView.js:
3325         (WebInspector.SettingsTabContentView.prototype._createDebugSettingsView):
3326         * UserInterface/Views/SettingsView.js:
3327         (WebInspector.SettingsView.prototype.addCenteredContainer):
3328         (WebInspector.SettingsView):
3329         Show "Reload Web Inspector" button when Spreadsheet Style Editor setting is modified.
3330
3331 2017-07-25  Devin Rousso  <drousso@apple.com>
3332
3333         Web Inspector: add context menu item for taking a screenshot of a node
3334         https://bugs.webkit.org/show_bug.cgi?id=174754
3335
3336         Reviewed by Brian Burg.
3337
3338         * Localizations/en.lproj/localizedStrings.js:
3339         * UserInterface/Views/ContextMenuUtilities.js:
3340         (WebInspector.appendContextMenuItemsForDOMNode):
3341         Add "Capture Element Screenshot " context menu item that opens a save dialog with a picture of the node.
3342
3343         * UserInterface/Base/Main.js:
3344         (WebInspector.saveDataToFile):
3345         Allow the saveData to specify whether the contained content is base64Encoded, instead of
3346         having to go through a Blob to save base64 data.
3347
3348         * UserInterface/Base/Utilities.js:
3349         Add Number.pad to add leading zeros up to a certain width.
3350
3351         Drive-by: fix failing test for Number.constrain.
3352
3353         * UserInterface/Models/DOMNode.js:
3354         (WebInspector.DOMNode.prototype.scrollIntoView.resolvedNode.scrollIntoView): Added.
3355         (WebInspector.DOMNode.prototype.scrollIntoView.resolvedNode): Added.
3356         (WebInspector.DOMNode.prototype.scrollIntoView): Added.
3357         * UserInterface/Views/DOMTreeElement.js:
3358         (WebInspector.DOMTreeElement.prototype._populateNodeContextMenu):
3359         (WebInspector.DOMTreeElement.prototype._scrollIntoView.resolvedNode.scrollIntoView): Deleted.
3360         (WebInspector.DOMTreeElement.prototype._scrollIntoView.resolvedNode): Deleted.
3361         (WebInspector.DOMTreeElement.prototype._scrollIntoView): Deleted.
3362         * UserInterface/Views/DOMTreeOutline.js:
3363         (WebInspector.DOMTreeOutline.prototype.populateContextMenu):
3364         Drive-by: move "Scroll Into View" context menu command to WebInspector.appendContextMenuItemsForDOMNode
3365         so that it can be triggered from more places than just the DOM tree.
3366
3367 2017-07-24  Nikita Vasilyev  <me@elv1s.ru>
3368
3369         Web Inspector: Settings: Some controls overlay settings header
3370         https://bugs.webkit.org/show_bug.cgi?id=174804
3371
3372         Reviewed by Matt Baker.
3373
3374         * UserInterface/Views/SettingsTabContentView.css:
3375         (.content-view.settings .navigation-bar):
3376
3377 2017-07-24  Matt Baker  <mattbaker@apple.com>
3378
3379         Web Inspector: should only show Canvases in resource type filter if debug setting enabled
3380         https://bugs.webkit.org/show_bug.cgi?id=174765
3381         <rdar://problem/33479009>
3382
3383         Reviewed by Devin Rousso.
3384
3385         * UserInterface/Views/ResourceSidebarPanel.js:
3386         (WebInspector.ResourceSidebarPanel):
3387
3388 2017-07-21  Joseph Pecoraro  <pecoraro@apple.com>
3389
3390         Web Inspector: inspect(aFunction) should jump to function definition
3391         https://bugs.webkit.org/show_bug.cgi?id=149344
3392         <rdar://problem/11563607>
3393
3394         Reviewed by Matt Baker.
3395
3396         * UserInterface/Protocol/InspectorObserver.js:
3397         (WebInspector.InspectorObserver.prototype.inspect):
3398         If we receive a function remote object jump to its location if available.
3399
3400 2017-07-21  Joseph Pecoraro  <pecoraro@apple.com>
3401
3402         Web Inspector: Avoid subclassing WebInspector.Object if we do not need to
3403         https://bugs.webkit.org/show_bug.cgi?id=174703
3404
3405         Reviewed by Brian Burg.
3406
3407         * UserInterface/Models/LogObject.js:
3408         (WebInspector.LogObject):
3409         (WebInspector.LogObject.prototype.get startDate): Deleted.
3410         Remove unused startDate property as well.
3411
3412         * UserInterface/Base/YieldableTask.js:
3413         * UserInterface/Debug/ProtocolTrace.js:
3414         * UserInterface/Models/AnalyzerMessage.js:
3415         * UserInterface/Models/ApplicationCacheFrame.js:
3416         * UserInterface/Models/ApplicationCacheManifest.js:
3417         * UserInterface/Models/BackForwardEntry.js:
3418         * UserInterface/Models/Branch.js:
3419         * UserInterface/Models/BreakpointAction.js:
3420         * UserInterface/Models/CSSMedia.js:
3421         * UserInterface/Models/CSSSelector.js:
3422         * UserInterface/Models/CallFrame.js:
3423         * UserInterface/Models/CallingContextTree.js:
3424         * UserInterface/Models/CallingContextTreeNode.js:
3425         * UserInterface/Models/CollectionEntry.js:
3426         * UserInterface/Models/CollectionEntryPreview.js:
3427         * UserInterface/Models/ConsoleMessage.js:
3428         * UserInterface/Models/DOMSearchMatchObject.js:
3429         * UserInterface/Models/DatabaseObject.js:
3430         * UserInterface/Models/DatabaseTableObject.js:
3431         * UserInterface/Models/DebuggerDashboard.js:
3432         * UserInterface/Models/DebuggerData.js:
3433         * UserInterface/Models/ExecutionContext.js:
3434         * UserInterface/Models/ExecutionContextList.js:
3435         * UserInterface/Models/GarbageCollection.js:
3436         * UserInterface/Models/HeapSnapshotRootPath.js:
3437         * UserInterface/Models/IndexedDatabase.js:
3438         * UserInterface/Models/IndexedDatabaseObjectStore.js:
3439         * UserInterface/Models/IndexedDatabaseObjectStoreIndex.js:
3440         * UserInterface/Models/Instrument.js:
3441         * UserInterface/Models/KeyboardShortcut.js:
3442         * UserInterface/Models/LineWidget.js:
3443         * UserInterface/Models/MemoryCategory.js:
3444         * UserInterface/Models/MemoryPressureEvent.js:
3445         * UserInterface/Models/ObjectPreview.js:
3446         * UserInterface/Models/Probe.js:
3447         * UserInterface/Models/ProbeSetDataFrame.js:
3448         * UserInterface/Models/Profile.js:
3449         * UserInterface/Models/ProfileNode.js:
3450         * UserInterface/Models/ProfileNodeCall.js:
3451         * UserInterface/Models/PropertyDescriptor.js:
3452         * UserInterface/Models/PropertyPath.js:
3453         * UserInterface/Models/PropertyPreview.js:
3454         * UserInterface/Models/ResourceQueryMatch.js:
3455         * UserInterface/Models/ResourceQueryResult.js:
3456         * UserInterface/Models/ResourceTimingData.js:
3457         * UserInterface/Models/Revision.js:
3458         * UserInterface/Models/ScopeChainNode.js:
3459         * UserInterface/Models/ScriptSyntaxTree.js:
3460         * UserInterface/Models/SourceCodePosition.js:
3461         * UserInterface/Models/SourceCodeSearchMatchObject.js:
3462         * UserInterface/Models/SourceMap.js:
3463         * UserInterface/Models/StackTrace.js:
3464         * UserInterface/Models/StructureDescription.js:
3465         * UserInterface/Models/TextMarker.js:
3466         * UserInterface/Models/TextRange.js:
3467         * UserInterface/Models/TimelineRange.js:
3468         * UserInterface/Models/TypeDescription.js:
3469         * UserInterface/Models/TypeSet.js:
3470         * UserInterface/Protocol/ProtocolTracer.js:
3471         * UserInterface/Proxies/FormatterWorkerProxy.js:
3472         * UserInterface/Proxies/HeapSnapshotDiffProxy.js:
3473         * UserInterface/Proxies/HeapSnapshotWorkerProxy.js:
3474         * UserInterface/Test/TestSuite.js:
3475
3476 2017-07-19  Chris Dumez  <cdumez@apple.com>
3477
3478         Drop SQLException type
3479         https://bugs.webkit.org/show_bug.cgi?id=174665
3480
3481         Reviewed by Sam Weinig.
3482
3483         Use SQLError instead of SQLException, this is what the script should really
3484         use here since it is checking the code of an SQLError.
3485
3486         * .eslintrc:
3487         * UserInterface/Models/DatabaseObject.js:
3488         (WebInspector.DatabaseObject.prototype.executeSQL.queryCallback):
3489         (WebInspector.DatabaseObject.prototype.executeSQL):
3490         (WebInspector.DatabaseObject):
3491
3492 2017-07-18  Andy Estes  <aestes@apple.com>
3493
3494         [Xcode] Enable CLANG_WARN_RANGE_LOOP_ANALYSIS
3495         https://bugs.webkit.org/show_bug.cgi?id=174631
3496
3497         Reviewed by Tim Horton.
3498
3499         * Configurations/Base.xcconfig:
3500
3501 2017-07-18  Andy Estes  <aestes@apple.com>
3502
3503         [Xcode] Enable CLANG_WARN_OBJC_LITERAL_CONVERSION
3504         https://bugs.webkit.org/show_bug.cgi?id=174631
3505
3506         Reviewed by Sam Weinig.
3507
3508         * Configurations/Base.xcconfig:
3509
3510 2017-07-18  Brian Burg  <bburg@apple.com>
3511
3512         Web Inspector: adjust wording of "clear when page {navigates -> loads}"
3513         https://bugs.webkit.org/show_bug.cgi?id=174589
3514         <rdar://problem/32797981>
3515
3516         Reviewed by Joseph Pecoraro.
3517
3518         * Localizations/en.lproj/localizedStrings.js:
3519         * UserInterface/Views/SettingsTabContentView.js:
3520         (WebInspector.SettingsTabContentView.prototype._createGeneralSettingsView):
3521
3522 2017-07-18  Andy Estes  <aestes@apple.com>
3523
3524         [Xcode] Enable CLANG_WARN_NON_LITERAL_NULL_CONVERSION
3525         https://bugs.webkit.org/show_bug.cgi?id=174631
3526
3527         Reviewed by Dan Bernstein.
3528
3529         * Configurations/Base.xcconfig:
3530
3531 2017-07-18  Andy Estes  <aestes@apple.com>
3532
3533         [Xcode] Enable CLANG_WARN_BLOCK_CAPTURE_AUTORELEASING
3534         https://bugs.webkit.org/show_bug.cgi?id=174631
3535
3536         Reviewed by Darin Adler.
3537
3538         * Configurations/Base.xcconfig:
3539
3540 2017-07-13  Joseph Pecoraro  <pecoraro@apple.com>
3541
3542         Web Inspector: Remove unused and untested Page domain commands
3543         https://bugs.webkit.org/show_bug.cgi?id=174429
3544
3545         Reviewed by Timothy Hatcher.
3546
3547         * UserInterface/Protocol/Legacy/10.0/InspectorBackendCommands.js:
3548         * UserInterface/Protocol/Legacy/10.3/InspectorBackendCommands.js:
3549         * UserInterface/Protocol/Legacy/11.0/InspectorBackendCommands.js:
3550         * UserInterface/Protocol/Legacy/7.0/InspectorBackendCommands.js:
3551         * UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js:
3552         * UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js:
3553         * UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js:
3554         * Versions/Inspector-iOS-10.0.json:
3555         * Versions/Inspector-iOS-10.3.json:
3556         * Versions/Inspector-iOS-11.0.json:
3557         * Versions/Inspector-iOS-7.0.json:
3558         * Versions/Inspector-iOS-8.0.json:
3559         * Versions/Inspector-iOS-9.0.json:
3560         * Versions/Inspector-iOS-9.3.json:
3561
3562 2017-07-11  Joseph Pecoraro  <pecoraro@apple.com>
3563
3564         Web Inspector: Correct a typo in the .eslintrc
3565         https://bugs.webkit.org/show_bug.cgi?id=174389
3566
3567         Reviewed by Matt Baker.
3568
3569         * .eslintrc:
3570
3571 2017-07-11  Joseph Pecoraro  <pecoraro@apple.com>
3572
3573         Web Inspector: Node Sidebar - Improve wording for Potential Custom Element lacking a Custom definition
3574         https://bugs.webkit.org/show_bug.cgi?id=174346
3575
3576         Reviewed by Matt Baker.
3577
3578         * Localizations/en.lproj/localizedStrings.js:
3579         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
3580         (WebInspector.DOMNodeDetailsSidebarPanel.prototype._customElementState):
3581         The text "Waiting to be upgraded" is poor. Any non-standard element with dashes
3582         in the name is considered custom, but does not need to be upgraded. Lets use
3583         different wording to indicate that it is detected as custom, and lacks a
3584         specific Custom Element definition.
3585
3586 2017-07-10  Devin Rousso  <drousso@apple.com>
3587
3588         Web Inspector: Highlight matching CSS canvas clients when hovering contexts in the Resources tab
3589         https://bugs.webkit.org/show_bug.cgi?id=174279
3590
3591         Reviewed by Matt Baker.
3592
3593         * UserInterface/Controllers/DOMTreeManager.js:
3594         (WebInspector.DOMTreeManager.prototype.highlightDOMNodeList):
3595         (WebInspector.DOMTreeManager.prototype.highlightSelector):
3596         * UserInterface/Views/CanvasTreeElement.js:
3597         (WebInspector.CanvasTreeElement.prototype._handleMouseOver):
3598
3599 2017-07-03  Brian Burg  <bburg@apple.com>
3600
3601         Web Replay: remove some unused code
3602         https://bugs.webkit.org/show_bug.cgi?id=173903
3603
3604         Rubber-stamped by Joseph Pecoraro.
3605
3606         * .eslintrc:
3607         * UserInterface/Base/Main.js:
3608         (WebInspector.loaded):
3609         * UserInterface/Controllers/DashboardManager.js:
3610         (WebInspector.DashboardManager):
3611         * UserInterface/Controllers/ReplayManager.js: Removed.
3612         * UserInterface/Images/ReplayPauseButton.svg: Removed.
3613         * UserInterface/Images/ReplayPlayButton.svg: Removed.
3614         * UserInterface/Images/ReplayRecordingButton.svg: Removed.
3615         * UserInterface/Images/gtk/ReplayPauseButton.svg: Removed.
3616         * UserInterface/Images/gtk/ReplayPlayButton.svg: Removed.
3617         * UserInterface/Images/gtk/ReplayRecordingButton.svg: Removed.
3618         * UserInterface/Main.html:
3619         * UserInterface/Models/ReplayDashboard.js: Removed.
3620         * UserInterface/Models/ReplaySession.js: Removed.
3621         * UserInterface/Models/ReplaySessionSegment.js: Removed.
3622         * UserInterface/Protocol/ReplayObserver.js: Removed.
3623         * UserInterface/Test.html:
3624         * UserInterface/Test/Test.js:
3625         (WebInspector.loaded):
3626         * UserInterface/Views/DashboardView.js:
3627         (WebInspector.DashboardView.create):
3628         * UserInterface/Views/ReplayDashboardView.css: Removed.
3629         * UserInterface/Views/ReplayDashboardView.js: Removed.
3630         * UserInterface/Views/TimelineRecordingContentView.js:
3631         (WebInspector.TimelineRecordingContentView.prototype._debuggerPaused):
3632         (WebInspector.TimelineRecordingContentView.prototype._debuggerResumed):
3633
3634 2017-07-07  Devin Rousso  <drousso@apple.com>
3635
3636         Web Inspector: Resources are sometimes missing from the tree outline right before folderizing
3637         https://bugs.webkit.org/show_bug.cgi?id=174277
3638
3639         Reviewed by Joseph Pecoraro.
3640
3641         * UserInterface/Views/TreeElement.js:
3642         (WebInspector.TreeElement.prototype.expand):
3643
3644 2017-07-07  Devin Rousso  <drousso@apple.com>
3645
3646         Web Inspector: REGRESSION(r217258): WebSocket resource tree elements don't show the connection status
3647         https://bugs.webkit.org/show_bug.cgi?id=174274
3648
3649         Reviewed by Brian Burg.
3650
3651         * UserInterface/Views/FrameTreeElement.js:
3652         (WebInspector.FrameTreeElement):
3653         * UserInterface/Views/ResourceTreeElement.js:
3654         (WebInspector.ResourceTreeElement.prototype.populateContextMenu):
3655         * UserInterface/Views/WebSocketResourceTreeElement.js:
3656         (WebInspector.WebSocketResourceTreeElement.prototype.populateContextMenu):
3657         Move "Log WebSocket" context menu item to WebSocketResourceTreeElement.
3658
3659 2017-07-07  Devin Rousso  <drousso@apple.com>
3660
3661         Web Inspector: Show all elements currently using a given CSS Canvas
3662         https://bugs.webkit.org/show_bug.cgi?id=173965
3663
3664         Reviewed by Joseph Pecoraro.
3665
3666         * UserInterface/Controllers/CanvasManager.js:
3667         (WebInspector.CanvasManager.prototype.cssCanvasClientNodesChanged):
3668         * UserInterface/Models/Canvas.js:
3669         (WebInspector.Canvas.prototype.requestCSSCanvasClientNodes):
3670         (WebInspector.Canvas.prototype.cssCanvasClientNodesChanged):
3671         * UserInterface/Protocol/CanvasObserver.js:
3672         (WebInspector.CanvasObserver.prototype.cssCanvasClientNodesChanged):
3673
3674         * Localizations/en.lproj/localizedStrings.js:
3675         * UserInterface/Views/CanvasDetailsSidebarPanel.js:
3676         (WebInspector.CanvasDetailsSidebarPanel):
3677         (WebInspector.CanvasDetailsSidebarPanel.prototype.set canvas):
3678         (WebInspector.CanvasDetailsSidebarPanel.prototype.initialLayout):
3679         (WebInspector.CanvasDetailsSidebarPanel.prototype.layout):
3680         (WebInspector.CanvasDetailsSidebarPanel.prototype._refreshCSSCanvasSection):
3681         (WebInspector.CanvasDetailsSidebarPanel.prototype._formatMemoryRow):
3682         Add CSS section for CSS canvases. Currently displays a list of node links, each of which is
3683         using the selected canvas via -webkit-canvas.
3684
3685         * UserInterface/Main.html:
3686         * UserInterface/Views/CanvasDetailsSidebarPanel.css: Added.
3687         (.sidebar > .panel.details.canvas .details-section > .content .row.simple > .value > .node-link):
3688
3689         * UserInterface/Controllers/DOMTreeManager.js:
3690         (WebInspector.DOMTreeManager.prototype.ensureDocument):
3691         * UserInterface/Models/Canvas.js:
3692         (WebInspector.Canvas.prototype.requestNode):
3693         * UserInterface/Views/SearchSidebarPanel.js:
3694         (WebInspector.SearchSidebarPanel.prototype.performSearch):
3695         Add convenience function that will call DOMAgent.getDocument with an empty function. Should
3696         be used when it is necessary that the document has been sent to the frontend, but the
3697         document node itself is not needed.
3698
3699 2017-07-07  Joseph Pecoraro  <pecoraro@apple.com>
3700
3701         Web Inspector: Clean up some unnecessary constructors
3702         https://bugs.webkit.org/show_bug.cgi?id=174236
3703
3704         Reviewed by Brian Burg.
3705
3706         * UserInterface/Controllers/CodeMirrorBezierEditingController.js:
3707         * UserInterface/Controllers/CodeMirrorColorEditingController.js:
3708         * UserInterface/Controllers/CodeMirrorGradientEditingController.js:
3709         * UserInterface/Views/DividerNavigationItem.js:
3710         * UserInterface/Views/FlexibleSpaceNavigationItem.js:
3711         * UserInterface/Views/IdleTreeElement.js:
3712
3713 2017-07-06  Devin Rousso  <drousso@apple.com>
3714
3715         Web Inspector: Highlight matching canvas element when hovering contexts in the Resources tab
3716         https://bugs.webkit.org/show_bug.cgi?id=174209
3717
3718         Reviewed by Joseph Pecoraro.
3719
3720         * UserInterface/Views/CanvasTreeElement.js:
3721         (WebInspector.CanvasTreeElement.prototype.onattach):
3722         (WebInspector.CanvasTreeElement.prototype._handleMouseOver):
3723         (WebInspector.CanvasTreeElement.prototype._handleMouseOut):
3724
3725 2017-07-06  Joseph Pecoraro  <pecoraro@apple.com>
3726
3727         Web Inspector: Add another Protocol Version
3728         https://bugs.webkit.org/show_bug.cgi?id=174193
3729         <rdar://problem/33150053>
3730
3731         Reviewed by Brian Burg.
3732
3733         * UserInterface/Protocol/Legacy/11.0/InspectorBackendCommands.js: Added.
3734         * Versions/Inspector-iOS-11.0.json: Added.
3735
3736 2017-07-05  Devin Rousso  <drousso@apple.com>
3737
3738         Web Inspector: Group Inspector Style Sheets as part of the Stylesheets folder
3739         https://bugs.webkit.org/show_bug.cgi?id=173435
3740
3741         Reviewed by Joseph Pecoraro.
3742
3743         * UserInterface/Views/ResourceSidebarPanel.js:
3744         (WebInspector.ResourceSidebarPanel.prototype.matchTreeElementAgainstCustomFilters.match):
3745         Add special case for CSSStyleSheetTreeElement.
3746
3747 2017-07-05  Devin Rousso  <drousso@apple.com>
3748
3749         Web Inspector: Split Canvas.svg into icons for 2D and 3D
3750         https://bugs.webkit.org/show_bug.cgi?id=174057
3751
3752         Reviewed by Matt Baker.
3753
3754         * UserInterface/Images/Canvas2D.svg: Added.
3755         * UserInterface/Images/Canvas3D.svg: Renamed from Source/WebInspectorUI/UserInterface/Images/Canvas.svg.
3756         * UserInterface/Views/ResourceIcons.css:
3757         (.canvas.canvas-2d .icon):
3758         (.canvas:matches(.webgl, .webgl2, .webgpu) .icon):
3759         (.canvas .icon): Deleted.
3760
3761 2017-07-05  Devin Rousso  <drousso@apple.com>
3762
3763         Web Inspector: Allow users to log any tracked canvas context
3764         https://bugs.webkit.org/show_bug.cgi?id=173397
3765         <rdar://problem/33111581>
3766
3767         Reviewed by Joseph Pecoraro.
3768
3769         * Localizations/en.lproj/localizedStrings.js:
3770         * UserInterface/Protocol/RemoteObject.js:
3771         (WebInspector.RemoteObject.resolveCanvasContext):
3772         * UserInterface/Views/CanvasTreeElement.js:
3773         (WebInspector.CanvasTreeElement.prototype.populateContextMenu):
3774
3775 2017-07-03  Devin Rousso  <drousso@apple.com>
3776
3777         Web Inspector: Support listing WebGL2 and WebGPU contexts
3778         https://bugs.webkit.org/show_bug.cgi?id=173396
3779
3780         Reviewed by Joseph Pecoraro.
3781
3782         * UserInterface/Models/Canvas.js:
3783         (WebInspector.Canvas.fromPayload):
3784         (WebInspector.Canvas.displayNameForContextType):
3785
3786 2017-07-01  Dan Bernstein  <mitz@apple.com>
3787
3788         [macOS] Remove code only needed when building for OS X Yosemite
3789         https://bugs.webkit.org/show_bug.cgi?id=174067
3790
3791         Reviewed by Tim Horton.
3792
3793         * Configurations/Base.xcconfig:
3794         * Configurations/DebugRelease.xcconfig:
3795         * Configurations/Version.xcconfig:
3796
3797 2017-06-30  Joseph Pecoraro  <pecoraro@apple.com>
3798
3799         Web Inspector: Type token background color in debugger looks poor
3800         https://bugs.webkit.org/show_bug.cgi?id=174063
3801
3802         Reviewed by Devin Rousso.
3803
3804         * UserInterface/Views/TextEditor.css:
3805         CodeMirror widgets do not get range styles like our (.execution-range-highlight).
3806         Make a best effort to carry over the styles to widgets. It isn't perfect, but it
3807         covers all common situations unless a selection ends inside the widget. The
3808         ultimate solution would be to get the expected range styles.
3809
3810 2017-06-30  Joseph Pecoraro  <pecoraro@apple.com>
3811
3812         Web Inspector: Initial search is sometimes performed twice, produces duplicate results
3813         https://bugs.webkit.org/show_bug.cgi?id=174047
3814
3815         Reviewed by Devin Rousso.
3816
3817         * UserInterface/Views/SearchTabContentView.js:
3818         (WebInspector.SearchTabContentView.prototype.performSearch):
3819         The initial layout of the tab content view was setting state to force a search
3820         which may happen after a delay, however the global search field was causing
3821         its own search to happen. We can clear the flag when a search is being performed
3822         to prevent duplicating the search.
3823
3824 2017-06-30  Devin Rousso  <drousso@apple.com>
3825
3826         Web Inspector: Add small delay before showing the progress spinner when loading resources
3827         https://bugs.webkit.org/show_bug.cgi?id=173437
3828
3829         Reviewed by Joseph Pecoraro.
3830
3831         * UserInterface/Views/ResourceContentView.js:
3832         (WebInspector.ResourceContentView):
3833         (WebInspector.ResourceContentView.prototype.removeLoadingIndicator): Added.
3834         (WebInspector.ResourceContentView.prototype._contentError):
3835         (WebInspector.ResourceContentView.prototype._hasContent):
3836         Delay the creation of the spinner for 100ms.  If the content is available before then, just
3837         clear the timeout and the spinner will never be created/shown.
3838
3839         We measured an average of 35ms to load and display images with slow cases being around 55ms.
3840         100ms was chosen for the timeout to give some room to allow for abnormally slow loading
3841         while not being too long as to be outright noticable.
3842
3843         * UserInterface/Views/FontResourceContentView.js:
3844         (WebInspector.FontResourceContentView.prototype.contentAvailable):
3845         * UserInterface/Views/ImageResourceContentView.js:
3846         (WebInspector.ImageResourceContentView.prototype.contentAvailable):
3847         * UserInterface/Views/TextResourceContentView.js:
3848         (WebInspector.TextResourceContentView.prototype._contentWillPopulate):
3849         Calls the new protected function removeLoadingIndicator to ensure that the spinner (and any
3850         other element) is removed.
3851
3852         This is necessary because TextResourceContentView effectively has two phases of loading its
3853         content: getting the content and formatting it for display.  The first follows the same path
3854         as the other ResourceContentView subclasses, the second waits for the ContentWillPopulate
3855         event on SourceCodeTextEditor before it actually adds the content as a subview.  In this
3856         case, the spinner should only be removed right before the content is actually added, not
3857         once it's ready.
3858
3859 2017-06-30  Commit Queue  <commit-queue@webkit.org>
3860
3861         Unreviewed, rolling out r218983.
3862         https://bugs.webkit.org/show_bug.cgi?id=174042
3863
3864         Broke Debugger Call Stack TreeOutline (Requested by drousso on
3865         #webkit).
3866
3867         Reverted changeset:
3868
3869         "Web Inspector: Remove unnecessary hasChildren from
3870         TreeOutline"
3871         https://bugs.webkit.org/show_bug.cgi?id=173986
3872         http://trac.webkit.org/changeset/218983
3873
3874 2017-06-30  Devin Rousso  <drousso@apple.com>
3875
3876         Web Inspector: Default string comparisons to treat numeric characters as numbers
3877         https://bugs.webkit.org/show_bug.cgi?id=173984
3878
3879         Reviewed by Joseph Pecoraro.
3880
3881         * UserInterface/Base/Utilities.js:
3882         (String.prototype.extendedLocaleCompare):
3883         * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js:
3884         (WebInspector.JavaScriptRuntimeCompletionProvider.prototype.completionControllerCompletionsNeeded.receivedPropertyNames.compare):
3885         * UserInterface/Controllers/ResourceQueryController.js:
3886         (WebInspector.ResourceQueryController.prototype.executeQuery):
3887         * UserInterface/Views/ApplicationCacheFrameContentView.js:
3888         (WebInspector.ApplicationCacheFrameContentView.prototype._sortDataGrid.localeCompare):
3889         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
3890         (WebInspector.CSSStyleDeclarationTextEditor.prototype._iterateOverProperties):
3891         * UserInterface/Views/CookieStorageContentView.js:
3892         (WebInspector.CookieStorageContentView.prototype._sortDataGrid.localeCompare):
3893         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
3894         (WebInspector.DOMNodeDetailsSidebarPanel.prototype._refreshAttributes):
3895         (WebInspector.DOMNodeDetailsSidebarPanel.prototype._refreshEventListeners.generateGroupsByNode):
3896         * UserInterface/Views/DOMStorageContentView.js:
3897         (WebInspector.DOMStorageContentView.prototype._sortDataGrid.comparator):
3898         * UserInterface/Views/DebuggerSidebarPanel.js:
3899         (WebInspector.DebuggerSidebarPanel.prototype._compareTopLevelTreeElements):