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