f42772e0db422c489833055ef5117e8aac344f21
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2016-08-26  Joseph Pecoraro  <pecoraro@apple.com>
2
3         Web Inspector: Add protocol version for iOS 10
4         https://bugs.webkit.org/show_bug.cgi?id=161266
5         <rdar://problem/28036594>
6
7         Rubber-stamped by Brian Burg.
8
9         * Localizations/en.lproj/localizedStrings.js:
10         Update missing localized strings.
11
12         * Versions/Inspector-iOS-10.0.json: Added.
13         Protocol for iOS 10.
14
15         * UserInterface/Protocol/Legacy/10.0/InspectorBackendCommands.js:
16         * UserInterface/Protocol/Legacy/7.0/InspectorBackendCommands.js:
17         * UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js:
18         * UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js:
19         * UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js:
20         Re-generate the legacy backend commands files.
21
22 2016-08-25  Joseph Pecoraro  <pecoraro@apple.com>
23
24         Web Inspector: Show IndexedDB Database/ObjectStore/Index data in a details sidebar
25         https://bugs.webkit.org/show_bug.cgi?id=161180
26         <rdar://problem/28003417>
27
28         Reviewed by Brian Burg.
29
30         * Localizations/en.lproj/localizedStrings.js:
31         * UserInterface/Main.html:
32         New strings and file.
33
34         * UserInterface/Base/Main.js:
35         (WebInspector.contentLoaded):
36         Instantiate the global details sidebar.
37
38         * UserInterface/Views/StorageTabContentView.js:
39         (WebInspector.StorageTabContentView):
40         Include the new details sidebar in the Storage tab.
41
42         * UserInterface/Controllers/StorageManager.js:
43         (WebInspector.StorageManager.prototype._addIndexedDBDatabasesIfNeeded.processKeyPath):
44         Use the protocol generated types.
45
46         * UserInterface/Views/IndexedDatabaseDetailsSidebarPanel.js: Added.
47         (WebInspector.IndexedDatabaseDetailsSidebarPanel):
48         (WebInspector.IndexedDatabaseDetailsSidebarPanel.prototype.inspect):
49         (WebInspector.IndexedDatabaseDetailsSidebarPanel.prototype.layout):
50         (WebInspector.IndexedDatabaseDetailsSidebarPanel.prototype._keyPathString):
51         Show the sidebar for an IndexedDatabase, ObjectStore, or Index.
52         Show each section if we can based on the objects we have.
53
54 2016-08-25  Joseph Pecoraro  <pecoraro@apple.com>
55
56         Web Inspector: Provide a way to clear an IndexedDB object store
57         https://bugs.webkit.org/show_bug.cgi?id=161167
58         <rdar://problem/27996932>
59
60         Reviewed by Brian Burg.
61
62         * Localizations/en.lproj/localizedStrings.js:
63         "Clear object store".
64
65         * UserInterface/Controllers/StorageManager.js:
66         (WebInspector.StorageManager.prototype.clearObjectStore):
67         Provide a wrapper for clearing an object store.
68
69         * UserInterface/Views/IndexedDatabaseObjectStoreContentView.js:
70         (WebInspector.IndexedDatabaseObjectStoreContentView):
71         (WebInspector.IndexedDatabaseObjectStoreContentView.prototype.get navigationItems):
72         (WebInspector.IndexedDatabaseObjectStoreContentView.prototype._clearButtonClicked):
73         Add a navigation button on ObjectStore content views to clear the object store.
74
75 2016-08-26  Devin Rousso  <dcrousso+webkit@gmail.com>
76
77         Web Inspector: Some CSS selectors in the UI aren't escaped
78         https://bugs.webkit.org/show_bug.cgi?id=151378
79
80         Reviewed by Joseph Pecoraro.
81
82         * UserInterface/Base/DOMUtilities.js:
83         (WebInspector.displayNameForNode): Deleted.
84         (WebInspector.linkifyNodeReference):
85         Use DOMNode.prototype.displayName instead of WebInspector.displayNameForNode.
86
87         * UserInterface/Models/DOMNode.js:
88         (WebInspector.DOMNode.prototype.get escapedIdSelector):
89         (WebInspector.DOMNode.prototype.get escapedClassSelector):
90         (WebInspector.DOMNode.prototype.get displayName):
91         (WebInspector.DOMNode.prototype.appropriateSelectorFor):
92         Rework escaping of ids and class names into separate public functions using CSS.escape.
93
94         * UserInterface/Views/CSSStyleDeclarationSection.js:
95         (WebInspector.CSSStyleDeclarationSection.prototype.refresh):
96         Use DOMNode.prototype.displayName instead of WebInspector.displayNameForNode.
97
98         * UserInterface/Views/DOMTreeDataGridNode.js:
99         (WebInspector.DOMTreeDataGridNode.prototype._createNameCellDocumentFragment):
100         Use DOMNode.prototype.displayName instead of WebInspector.displayNameForNode.
101
102         * UserInterface/Views/DOMTreeElementPathComponent.js:
103         (WebInspector.DOMTreeElementPathComponent):
104         Use DOMNode.prototype.displayName instead of WebInspector.displayNameForNode.
105
106         * UserInterface/Views/LayerTreeDataGridNode.js:
107         (WebInspector.LayerTreeDataGridNode.prototype.set layer):
108         Use DOMNode.prototype.displayName instead of WebInspector.displayNameForNode.
109
110         * UserInterface/Views/VisualStyleSelectorSection.js:
111         (WebInspector.VisualStyleSelectorSection.prototype.update):
112         Use DOMNode.prototype.displayName instead of WebInspector.displayNameForNode.
113
114 2016-08-24  Matt Baker  <mattbaker@apple.com>
115
116         Web Inspector: unexpected cursor changes while dragging ruler handle in rendering frames timeline
117         https://bugs.webkit.org/show_bug.cgi?id=161101
118         <rdar://problem/27974117>
119
120         Reviewed by Brian Burg.
121
122         -webkit-grab(bing) cursor styles shouldn't be applied to the selection
123         drag element when resizing.
124
125         * UserInterface/Views/TimelineRuler.css:
126         (.timeline-ruler:not(.disabled, .resizing-selection) > .selection-drag):
127         (.timeline-ruler:not(.disabled, .resizing-selection) > .selection-drag:active):
128         (.timeline-ruler:not(.disabled) > .selection-drag): Deleted.
129         (.timeline-ruler:not(.disabled) > .selection-drag:active): Deleted.
130
131 2016-08-24  Devin Rousso  <dcrousso+webkit@gmail.com>
132
133         Web Inspector: Shift-Tab should unindent selected line
134         https://bugs.webkit.org/show_bug.cgi?id=159316
135
136         Reviewed by Joseph Pecoraro.
137
138         * UserInterface/Views/CodeMirrorAdditions.js:
139         (CodeMirror.keyMap["default"]):
140         Changed "Shift-Tab" mapping to "indentLess".
141
142 2016-08-23  Devin Rousso  <dcrousso+webkit@gmail.com>
143
144         Web Inspector: resource tree elements should provide "Download File" context menu items
145         https://bugs.webkit.org/show_bug.cgi?id=158035
146
147         Reviewed by Joseph Pecoraro.
148
149         Add a context menu item to elements representing resources that
150         initiates a download of that resource.
151
152         * Localizations/en.lproj/localizedStrings.js:
153
154         * UserInterface/Base/Main.js:
155         (WebInspector.saveDataToFile):
156         Add support for saving base64 objects.
157
158         * UserInterface/Base/MIMETypeUtilities.js:
159         (WebInspector.fileExtensionForMIMEType):
160         Returns a file extension for the given MIME type if able.
161
162         * UserInterface/Views/FrameTreeElement.js:
163         (WebInspector.FrameTreeElement.prototype.onattach):
164         Add contextmenu event listener since superclass onattach call is explicitly not used.
165
166         * UserInterface/Views/ResourceTimelineDataGridNode.js:
167         (WebInspector.ResourceTimelineDataGridNode.prototype.appendContextMenuItems):
168         Add Save File context menu item.
169
170         * UserInterface/Views/ResourceTreeElement.js:
171         (WebInspector.ResourceTreeElement.prototype.onattach):
172         (WebInspector.ResourceTreeElement.prototype._handleContextMenuEvent):
173         Add contextmenu event listener and Save File context menu item.
174
175 2016-08-23  Devin Rousso  <dcrousso+webkit@gmail.com>
176
177         Web Inspector: No open/copy src resource in context menu
178         https://bugs.webkit.org/show_bug.cgi?id=159028
179
180         Reviewed by Joseph Pecoraro.
181
182         * Localizations/en.lproj/localizedStrings.js:
183
184         * UserInterface/Views/DOMTreeElement.js:
185         (WebInspector.DOMTreeElement.prototype._populateTagContextMenu):
186         Add options in the context menu of link attributes of DOM nodes to
187          - Open in New Tab
188          - Reveal in Resources Tab
189          - Copy Link Address
190
191 2016-08-23  Devin Rousso  <dcrousso+webkit@gmail.com>
192
193         Web Inspector: Add visual editor for spring() timing-function
194         https://bugs.webkit.org/show_bug.cgi?id=159315
195
196         Reviewed by Joseph Pecoraro.
197
198         * Localizations/en.lproj/localizedStrings.js:
199         * UserInterface/Main.html:
200
201         * UserInterface/Base/Utilities.js:
202         (Number.prototype.maxDecimals):
203         Limits the number of decimals for the number object via rounding.
204
205         * UserInterface/Controllers/CodeMirrorSpringEditingController.js:
206         (WebInspector.CodeMirrorSpringEditingController.prototype.get initialValue):
207         (WebInspector.CodeMirrorSpringEditingController.prototype.get cssClassName):
208         (WebInspector.CodeMirrorSpringEditingController.prototype.popoverWillPresent):
209         (WebInspector.CodeMirrorSpringEditingController.prototype.popoverDidPresent):
210         (WebInspector.CodeMirrorSpringEditingController.prototype.popoverDidDismiss):
211         (WebInspector.CodeMirrorSpringEditingController.prototype._springEditorSpringChanged):
212         Controller for Spring editors inside CodeMirror instances.
213
214         * UserInterface/Models/Geometry.js:
215         (WebInspector.Spring):
216         (WebInspector.Spring.fromValues):
217         (WebInspector.Spring.fromString):
218         (WebInspector.Spring.prototype.copy):
219         (WebInspector.Spring.prototype.toString):
220         (WebInspector.Spring.prototype.solve):
221         (WebInspector.Spring.prototype.calculateDuration):
222         Spring data class based on <https://webkit.org/demos/spring/>.
223
224         * UserInterface/Models/TextMarker.js:
225         (WebInspector.TextMarker.Type):
226         Added Spring marker type.
227
228         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
229         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createInlineSwatches):
230         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createInlineSwatches.update):
231         (WebInspector.CSSStyleDeclarationTextEditor.prototype._inlineSwatchValueChanged):
232         (WebInspector.CSSStyleDeclarationTextEditor.prototype._inlineSwatchValueChanged.update):
233
234         * UserInterface/Views/CodeMirrorTextMarkers.js:
235         (createCodeMirrorSpringTextMarkers):
236
237         * UserInterface/Views/InlineSwatch.css:
238         (.inline-swatch:matches(.bezier, .spring)):
239         (.inline-swatch:matches(.bezier, .spring):hover):
240         (.inline-swatch:matches(.bezier, .spring):active):
241         (.inline-swatch:matches(.bezier, .spring) > span):
242         (.inline-swatch.bezier): Deleted.
243         (.inline-swatch.bezier:hover): Deleted.
244         (.inline-swatch.bezier:active): Deleted.
245         (.inline-swatch.bezier > span): Deleted.
246
247         * UserInterface/Views/InlineSwatch.js:
248         (WebInspector.InlineSwatch):
249         (WebInspector.InlineSwatch.prototype._fallbackValue):
250         (WebInspector.InlineSwatch.prototype._swatchElementClicked):
251         (WebInspector.InlineSwatch.prototype._valueEditorValueDidChange):
252         (WebInspector.InlineSwatch.Type):
253         Added support for Spring editor Inline Swatches.
254
255         * UserInterface/Views/SourceCodeTextEditor.js:
256         (WebInspector.SourceCodeTextEditor.prototype._updateEditableMarkers):
257         (WebInspector.SourceCodeTextEditor.prototype._tokenTrackingControllerHighlightedMarkedExpression):
258
259         * UserInterface/Views/SpringEditor.css:
260         (.spring-editor):
261         (.spring-editor > .spring-preview):
262         (.spring-editor > .spring-preview > div):
263         (.spring-editor > .spring-timing):
264         (.spring-editor > .spring-timing > div):
265         (.spring-editor > .spring-timing:matches(::before, ::after)):
266         (.spring-editor > .spring-timing::before):
267         (.spring-editor > .spring-timing::after):
268         (.spring-editor > :matches(.spring-preview, .spring-timing) > div):
269         (.spring-editor > .animate:matches(.spring-preview, .spring-timing) > div):
270         (.spring-editor > .number-input-container > .number-input-row):
271         (.spring-editor > .number-input-container > .number-input-row > .number-input-row-title):
272         (.spring-editor > .number-input-container > .number-input-row > input):
273         (.spring-editor > .number-input-container > .number-input-row > input[type="range"]):
274
275         * UserInterface/Views/SpringEditor.js:
276         (WebInspector.SpringEditor):
277         (WebInspector.SpringEditor.prototype.get element):
278         (WebInspector.SpringEditor.prototype.set spring):
279         (WebInspector.SpringEditor.prototype.get spring):
280         (WebInspector.SpringEditor.prototype._handleNumberInputInput):
281         (WebInspector.SpringEditor.prototype._handleNumberInputKeydown):
282         (WebInspector.SpringEditor.prototype._handleNumberSliderInput):
283         (WebInspector.SpringEditor.prototype._handleNumberSliderMousedown):
284         (WebInspector.SpringEditor.prototype._handleNumberSliderMouseup):
285         (WebInspector.SpringEditor.prototype._changeSpringForInput):
286         (WebInspector.SpringEditor.prototype._resetPreviewAnimation):
287         (WebInspector.SpringEditor.prototype._updatePreviewAnimation):
288         (WebInspector.SpringEditor.Event):
289         Visual editor for CSS Spring timing function values.  Organized into 5 rows:
290          - Preview: shows movement of spring and total duration
291          - Mass: slider and input for "mass" parameter
292          - Stiffness: slider and input for "stiffness" parameter
293          - Damping: slider and input for "damping" parameter
294          - Initial Velocity: slider and input for "initial velocity" parameter
295         The preview animation will loop indefinitely until the user clicks the animation row
296         or changes the value of one of the parameters, at which point the duration will also
297         be recalculated.
298
299         * UserInterface/Views/TextEditor.js:
300         (WebInspector.TextEditor.prototype.createSpringMarkers):
301         (WebInspector.TextEditor.prototype.editingControllerForMarker):
302
303         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.js:
304         (WebInspector.VisualStyleCommaSeparatedKeywordEditor.prototype.set value):
305         (WebInspector.VisualStyleCommaSeparatedKeywordEditor.prototype._generateTextFromLonghandProperties):
306         Add support for CSS spring timing functions by allowing parenthesis in comma separated
307         values so long as there are no commas inside the parenthesis.
308
309         * UserInterface/Views/VisualStyleTimingEditor.css:
310         (.visual-style-property-container.timing-editor > .visual-style-property-value-container > .inline-swatch:matches(.bezier, .spring)):
311         (.visual-style-property-container.timing-editor > .visual-style-property-value-container:not(.spring-value) > .inline-swatch.spring):
312         (.visual-style-property-container.timing-editor > .visual-style-property-value-container > .inline-swatch.bezier): Deleted.
313         (.visual-style-property-container.timing-editor > .visual-style-property-value-container:not(.bezier-value) > .inline-swatch.bezier): Deleted.
314
315         * UserInterface/Views/VisualStyleTimingEditor.js:
316         (WebInspector.VisualStyleTimingEditor):
317         (WebInspector.VisualStyleTimingEditor.prototype.get value):
318         (WebInspector.VisualStyleTimingEditor.prototype.set value):
319         (WebInspector.VisualStyleTimingEditor.prototype.get synthesizedValue):
320         (WebInspector.VisualStyleTimingEditor.prototype.parseValue):
321         (WebInspector.VisualStyleTimingEditor.prototype.get _bezierValue):
322         (WebInspector.VisualStyleTimingEditor.prototype.set _bezierValue):
323         (WebInspector.VisualStyleTimingEditor.prototype.get _springValue):
324         (WebInspector.VisualStyleTimingEditor.prototype.set _springValue):
325         (WebInspector.VisualStyleTimingEditor.prototype._handleKeywordChanged):
326         (WebInspector.VisualStyleTimingEditor.prototype._springSwatchValueChanged):
327         (WebInspector.VisualStyleTimingEditor.prototype.get bezierValue): Renamed.
328         (WebInspector.VisualStyleTimingEditor.prototype.set bezierValue): Renamed.
329         Duplicate Bezier custom timing function logic for Spring timing functions.
330
331 2016-08-22  Devin Rousso  <dcrousso+webkit@gmail.com>
332
333         Web Inspector: Styles -> Computed -> Box Model shows NaN x NaN for invisible elements
334         https://bugs.webkit.org/show_bug.cgi?id=161038
335
336         Reviewed by Joseph Pecoraro.
337
338         * UserInterface/Base/Utilities.js:
339         Add figureDash variable.
340
341         * UserInterface/Views/BoxModelDetailsSectionRow.js:
342         (WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createElement):
343         (WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics.createBoxPartElement):
344         Moved isNaN check of value to common createElement.
345
346 2016-08-22  Devin Rousso  <dcrousso+webkit@gmail.com>
347
348         Web Inspector: Visual styles sidebar should do something sane for SVG elements
349         https://bugs.webkit.org/show_bug.cgi?id=148269
350
351         Reviewed by Joseph Pecoraro.
352
353         * Localizations/en.lproj/localizedStrings.js:
354
355         * UserInterface/Models/DOMNode.js:
356         (WebInspector.DOMNode.prototype.get ownerSVGElement):
357         (WebInspector.DOMNode.prototype.isSVGElement):
358         Climbs ancestor tree to determine if node is an SVG node.
359
360         * UserInterface/Views/VisualStyleDetailsPanel.js:
361         (WebInspector.VisualStyleDetailsPanel.prototype.initialLayout):
362         (WebInspector.VisualStyleDetailsPanel.prototype._updateSections):
363         (WebInspector.VisualStyleDetailsPanel.prototype._populatePositionSection):
364         (WebInspector.VisualStyleDetailsPanel.prototype._populateDimensionsSection):
365         (WebInspector.VisualStyleDetailsPanel.prototype._populateContentSection):
366         (WebInspector.VisualStyleDetailsPanel.prototype._populateFillSection):
367         (WebInspector.VisualStyleDetailsPanel.prototype._populateStrokeSection):
368
369         * UserInterface/Views/VisualStylePropertyEditor.css:
370         (.visual-style-property-container.inactive):
371         (.visual-style-property-container > *:first-child:matches(.visual-style-property-value-container)):
372
373         * UserInterface/Views/VisualStyleRelativeNumberSlider.css:
374         (.visual-style-property-container.number-input-box.relative-number-slider > .relative-slider):
375
376         * UserInterface/Views/VisualStyleUnitSlider.css:
377         (.visual-style-property-container.unit-slider > .visual-style-property-value-container > .slider):
378         (.visual-style-property-container.unit-slider.opacity > .visual-style-property-value-container > .slider): Deleted.
379
380 2016-08-22  Devin Rousso  <dcrousso+webkit@gmail.com>
381
382         Web Inspector: Visual Styles: "Text -> Content" section should only be visible for pseudo-element
383         https://bugs.webkit.org/show_bug.cgi?id=158272
384
385         Reviewed by Joseph Pecoraro.
386
387         * Localizations/en.lproj/localizedStrings.js:
388
389         * UserInterface/Views/VisualStyleDetailsPanel.css:
390         (.sidebar > .panel.details.css-style .visual > .details-section :matches(.details-section, .group).inactive):
391         (.sidebar > .panel.details.css-style .visual > .details-section :matches(.details-section, .group).inactive > *):
392         (.visual-style-property-container.transition): Deleted.
393         (.visual-style-property-container.animation): Deleted.
394
395         * UserInterface/Views/VisualStyleDetailsPanel.js:
396         (WebInspector.VisualStyleDetailsPanel.prototype.initialLayout):
397         (WebInspector.VisualStyleDetailsPanel.prototype._updateSections):
398         (WebInspector.VisualStyleDetailsPanel.prototype._populateContentSection):
399
400 2016-08-22  Devin Rousso  <dcrousso+webkit@gmail.com>
401
402         Web Inspector: Entering ":n" in Open Resource Dialog, where n > number of lines, should jump to the last line
403         https://bugs.webkit.org/show_bug.cgi?id=160840
404
405         Reviewed by Joseph Pecoraro.
406
407         * UserInterface/Views/TextEditor.js:
408         (TextEditor.prototype.revealPosition):
409         Limit the given line and column to the maximum number of lines and the column count on the
410         resulting line.
411
412 2016-08-22  Devin Rousso  <dcrousso+webkit@gmail.com>
413
414         Web Inspector: Add indicator to matched selector being a pseudo-element
415         https://bugs.webkit.org/show_bug.cgi?id=160893
416
417         Reviewed by Joseph Pecoraro.
418
419         Instead of using "{}" icons for CSS rules, use a "P" icon with the same coloring to identify
420         that the rule contains a pseudo-selector that is currently being applied to the selected element.
421
422         * UserInterface/Base/Utilities.js:
423         (Array.prototype.toggleIncludes):
424         Toggles whether or not to include the given value in the array based on its existence or a
425         "force" flag parameter.
426
427         * UserInterface/Images/StyleRuleAuthorPseudo.svg:
428         * UserInterface/Images/StyleRuleInspectorPseudo.svg:
429         * UserInterface/Images/StyleRuleUserAgentPseudo.svg:
430         * UserInterface/Images/StyleRuleUserPseudo.svg:
431
432         * UserInterface/Models/CSSRule.js:
433         (WebInspector.CSSRule.prototype.hasMatchedPseudoElementSelector):
434
435         * UserInterface/Models/CSSSelector.js:
436         (WebInspector.CSSSelector.prototype.isPseudoElementSelector):
437
438         * UserInterface/Views/CSSStyleDeclarationSection.js:
439         (WebInspector.CSSStyleDeclarationSection.prototype.refresh):
440
441         * UserInterface/Views/StyleRuleIcons.css:
442         (.author-style-rule-icon.pseudo-element-selector .icon):
443         (.user-style-rule-icon.pseudo-element-selector .icon):
444         (.user-agent-style-rule-icon.pseudo-element-selector .icon):
445         (.inspector-style-rule-icon.pseudo-element-selector .icon):
446
447          * UserInterface/Views/VisualStyleSelectorTreeItem.js:
448         (WebInspector.VisualStyleSelectorTreeItem):
449         (WebInspector.VisualStyleSelectorTreeItem.prototype.get iconClassName):
450         (WebInspector.VisualStyleSelectorTreeItem.prototype._updateSelectorIcon):
451
452 2016-08-19  Nikita Vasilyev  <nvasilyev@apple.com>
453
454         Web Inspector: Make an icon for Code Coverage Profiler
455         https://bugs.webkit.org/show_bug.cgi?id=160872
456         <rdar://problem/27855650>
457
458         Reviewed by Joseph Pecoraro.
459
460         Add a "C" icon, similar to the existing "T" (Type Profiler) icon.
461         "C" can stand for Code Coverage or Control Flow.
462
463         * UserInterface/Images/NavigationItemCodeCoverage.svg: Added.
464
465 2016-08-19  Devin Rousso  <dcrousso+webkit@gmail.com>
466
467         Web Inspector: Console log counter on the dashboard should be better at displaying large numbers
468         https://bugs.webkit.org/show_bug.cgi?id=160054
469
470         Reviewed by Matt Baker.
471
472         * Localizations/en.lproj/localizedStrings.js:
473
474         * UserInterface/Base/Utilities.js:
475         (Number.abbreviate):
476         Add logic for formatting a number as "#K", "#M", and "#B" when it is very large.
477
478         * UserInterface/Views/DefaultDashboardView.js:
479         (WebInspector.DefaultDashboardView.prototype._updateDisplay):
480         (WebInspector.DefaultDashboardView.prototype._formatPossibleLargeNumber): Deleted.
481         (WebInspector.DefaultDashboardView.prototype._setConsoleItemValue):
482
483 2016-08-17  Matt Baker  <mattbaker@apple.com>
484
485         Web Inspector: Network Tab should not layout if not visible
486         https://bugs.webkit.org/show_bug.cgi?id=160920
487         <rdar://problem/27876629>
488
489         Reviewed by Timothy Hatcher.
490
491         Avoid updating the current time when the Network tab is hidden.
492         The timer, and any debounced timer cancellations, need to be stopped
493         as soon as the view is hidden.
494
495         * UserInterface/Views/NetworkGridContentView.js:
496         (WebInspector.NetworkGridContentView.prototype.hidden):
497         (WebInspector.NetworkGridContentView.prototype._networkTimelineRecordAdded):
498         (WebInspector.NetworkGridContentView.prototype._stopUpdatingCurrentTime):
499         (WebInspector.NetworkGridContentView):
500
501 2016-08-17  Devin Rousso  <dcrousso+webkit@gmail.com>
502
503         Web Inspector: Select elements in DOM hierarchy are misaligned
504         https://bugs.webkit.org/show_bug.cgi?id=160885
505
506         Reviewed by Timothy Hatcher.
507
508         * UserInterface/Views/HierarchicalPathComponent.css:
509         (.hierarchical-path-component > select):
510
511 2016-08-17  Devin Rousso  <dcrousso+webkit@gmail.com>
512
513         Web Inspector: rapid updates to status icons in Visual Styles sidebar causes flicker
514         https://bugs.webkit.org/show_bug.cgi?id=160887
515
516         Reviewed by Timothy Hatcher.
517
518         * UserInterface/Views/VisualStyleBasicInput.js:
519         (WebInspector.VisualStyleBasicInput):
520
521         * UserInterface/Views/VisualStyleColorPicker.js:
522         (WebInspector.VisualStyleColorPicker):
523
524         * UserInterface/Views/VisualStyleNumberInputBox.js:
525         (WebInspector.VisualStyleNumberInputBox):
526         (WebInspector.VisualStyleNumberInputBox.prototype._valueNumberInputKeyDown):
527
528         * UserInterface/Views/VisualStylePropertyNameInput.js:
529         (WebInspector.VisualStylePropertyNameInput):
530
531 2016-08-16  Nikita Vasilyev  <nvasilyev@apple.com>
532
533         Web Inspector: DOM nodes shift when hovering over them in Console
534         https://bugs.webkit.org/show_bug.cgi?id=160789
535         <rdar://problem/27815600>
536
537         Reviewed by Matt Baker.
538
539         * UserInterface/Views/FormattedValue.css:
540         (.formatted-node > .tree-outline.dom ol): Deleted.
541
542 2016-08-16  Nikita Vasilyev  <nvasilyev@apple.com>
543
544         Web Inspector: Data grid has a double left border when the first column is hidden
545         https://bugs.webkit.org/show_bug.cgi?id=160723
546         <rdar://problem/27778081>
547
548         Reviewed by Timothy Hatcher.
549
550         This patch exploits the fact hiding columns that aren't first in DataGrid don't create double
551         borders.
552
553         * UserInterface/Views/DataGrid.css:
554         (.data-grid table.header,):
555         (.data-grid :matches(th, td):first-child):
556         (@media (-webkit-min-device-pixel-ratio: 2)):
557         * UserInterface/Views/SourceCodeTextEditor.js:
558         (WebInspector.SourceCodeTextEditor.prototype._setTypeTokenAnnotatorEnabledState):
559
560 2016-08-16  Joseph Pecoraro  <pecoraro@apple.com>
561
562         Web Inspector: Do not request Scope Chain lists if section is collapsed (mainly Global Variables)
563         https://bugs.webkit.org/show_bug.cgi?id=140567
564         <rdar://problem/19504745>
565
566         Reviewed by Timothy Hatcher.
567
568         * UserInterface/Main.html:
569         New file name.
570
571         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
572         (WebInspector.DOMNodeDetailsSidebarPanel.prototype._refreshProperties.fillSection):
573         (WebInspector.DOMNodeDetailsSidebarPanel.prototype._refreshProperties):
574         Avoid fetching object properties until the user expands the section.
575
576         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
577         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
578         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateWatchExpressionsSection):
579         Avoid fetching scope variable properties until the user expands the section.
580
581         * UserInterface/Views/ObjectPropertiesDetailSectionRow.js: Renamed from Source/WebInspectorUI/UserInterface/Views/DetailsSectionPropertiesRow.js.
582         (WebInspector.ObjectPropertiesDetailSectionRow):
583         (WebInspector.ObjectPropertiesDetailSectionRow.prototype.get objectTree):
584         (WebInspector.ObjectPropertiesDetailSectionRow.prototype._detailsSectionCollapsedStateChanged):
585         Rename and simplify the class since it always has an ObjectTreeView.
586         By default the section will auto-expand the ObjectTreeView, however
587         if provided a details section group, it will defer expanion until
588         the group expands.
589
590 2016-08-16  Devin Rousso  <dcrousso+webkit@gmail.com>
591
592         Web Inspector: add "Copy Selected" context menu item to Console
593         https://bugs.webkit.org/show_bug.cgi?id=151836
594
595         Reviewed by Timothy Hatcher.
596
597         * Localizations/en.lproj/localizedStrings.js:
598         * UserInterface/Views/LogContentView.js:
599         (WebInspector.LogContentView.prototype._previousMessageRepeatCountUpdated):
600         (WebInspector.LogContentView.prototype._handleContextMenuEvent):
601         (WebInspector.LogContentView.prototype._mousedown):
602
603 2016-08-16  Devin Rousso  <dcrousso+webkit@gmail.com>
604
605         Web Inspector: Visual Styles: "Text -> Content" isn't escaped
606         https://bugs.webkit.org/show_bug.cgi?id=158271
607
608         Reviewed by Timothy Hatcher.
609
610         * UserInterface/Base/Utilities.js:
611         (String.prototype.hasMatchingEscapedQuotes):
612         Checks that the given string has property escaped quotes (single or double).
613
614         * UserInterface/Views/VisualStyleBasicInput.js:
615         (WebInspector.VisualStyleBasicInput):
616         (WebInspector.VisualStyleBasicInput.prototype._handleInputElementInput):
617
618 2016-08-16  Joseph Pecoraro  <pecoraro@apple.com>
619
620         Modernize model objects simple getters
621         https://bugs.webkit.org/show_bug.cgi?id=160863
622
623         Reviewed by Timothy Hatcher.
624
625         Simplify the style of many Model objects with basic accessors.
626         We reduce them to a single line and group them together so
627         that they can be more easily read at a glance.
628
629         * UserInterface/Models/AnalyzerMessage.js:
630         * UserInterface/Models/ApplicationCacheFrame.js:
631         * UserInterface/Models/ApplicationCacheManifest.js:
632         * UserInterface/Models/BreakpointAction.js:
633         * UserInterface/Models/CSSMedia.js:
634         * UserInterface/Models/CSSSelector.js:
635         * UserInterface/Models/CollectionEntry.js:
636         * UserInterface/Models/CollectionEntryPreview.js:
637         * UserInterface/Models/DOMStorageObject.js:
638         * UserInterface/Models/DatabaseObject.js:
639         * UserInterface/Models/DatabaseTableObject.js:
640         * UserInterface/Models/ExecutionContext.js:
641         * UserInterface/Models/GarbageCollection.js:
642         * UserInterface/Models/IndexedDatabase.js:
643         * UserInterface/Models/IndexedDatabaseObjectStore.js:
644         * UserInterface/Models/IndexedDatabaseObjectStoreIndex.js:
645         * UserInterface/Models/ObjectPreview.js:
646         * UserInterface/Models/ProbeSet.js:
647         * UserInterface/Models/PropertyDescriptor.js:
648         * UserInterface/Models/PropertyPath.js:
649         * UserInterface/Models/PropertyPreview.js:
650         * UserInterface/Models/SourceCodePosition.js:
651         * UserInterface/Models/SourceCodeSearchMatchObject.js:
652         * UserInterface/Models/SourceCodeTimeline.js:
653         * UserInterface/Models/StructureDescription.js:
654         * UserInterface/Models/TextRange.js:
655         * UserInterface/Models/Timeline.js:
656         * UserInterface/Models/TimelineRecording.js:
657         * UserInterface/Models/TypeDescription.js:
658
659 2016-08-15  Devin Rousso  <dcrousso+webkit@gmail.com>
660
661         Web Inspector: Large class lists are not easily discoverable with "Classes" quick-toggle
662         https://bugs.webkit.org/show_bug.cgi?id=160856
663
664         Reviewed by Joseph Pecoraro.
665
666         * UserInterface/Base/DOMUtilities.js:
667         (WebInspector.linkifyNodeReference):
668         Add option to truncate the text of the linkified node.
669
670         * UserInterface/Views/CSSStyleDetailsSidebarPanel.css:
671         (.sidebar > .panel.details.css-style > .content ~ .class-list-container):
672         Increase the max-height to partially show additional classes if many are set.
673
674         * UserInterface/Views/RulesStyleDetailsPanel.js:
675         (WebInspector.RulesStyleDetailsPanel.prototype.refresh.insertMediaOrInheritanceLabel):
676         Trucate the name of inherited nodes so they don't take up as much space in the sidebar.
677
678         * UserInterface/Views/VisualStyleSelectorSection.css:
679         (.details-section.visual-style-selector-section > .header > .current-selector): Deleted.
680         (.details-section.visual-style-selector-section > .content > .selectors > .selector-list > .section-divider > .titles): Deleted.
681         Removed since they are already inherited.
682
683 2016-08-15  Devin Rousso  <dcrousso+webkit@gmail.com>
684
685         Web Inspector: Close button on selected item in Network tab is misaligned
686         https://bugs.webkit.org/show_bug.cgi?id=160884
687
688         Reviewed by Matt Baker.
689
690         * UserInterface/Views/NetworkSidebarPanel.css:
691         (.sidebar > .panel.navigation.network .status .close.status-button):
692
693 2016-08-15  Devin Rousso  <dcrousso+webkit@gmail.com>
694
695         Web Inspector: Error/Warning icons are misplaced in the Visual sidebar
696         https://bugs.webkit.org/show_bug.cgi?id=160875
697
698         Reviewed by Matt Baker.
699
700         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.css:
701         (.visual-style-property-container.comma-separated-keyword-editor > .visual-style-property-value-container > .visual-style-special-property-placeholder): Deleted.
702         Reworked to apply more generally to editors without titles.
703
704         * UserInterface/Views/VisualStylePropertyEditor.css:
705         (.visual-style-property-container.missing-dependency > .visual-style-property-editor-warning):
706         (.visual-style-property-container.invalid-value > .visual-style-property-editor-warning):
707         (.visual-style-property-container:matches(.missing-dependency, .invalid-value) > *:first-child:matches(.visual-style-property-value-container)):
708         (.visual-style-property-container > *:first-child:matches(.visual-style-property-value-container) > .visual-style-special-property-placeholder):
709         (.visual-style-property-container > .visual-style-property-editor-warning.missing-dependency): Deleted.
710         (.visual-style-property-container > .visual-style-property-editor-warning.invalid-value): Deleted.
711         Reworked class names to be on the element container instead of the icon.
712
713         * UserInterface/Views/VisualStylePropertyEditor.js:
714         (WebInspector.VisualStylePropertyEditor.prototype.update):
715         (WebInspector.VisualStylePropertyEditor.prototype.updateEditorValues):
716         (WebInspector.VisualStylePropertyEditor.prototype._valueDidChange):
717         (WebInspector.VisualStylePropertyEditor.prototype._checkDependencies):
718
719 2016-08-15  Saam Barati  <sbarati@apple.com>
720
721         Web Inspector: Introduce a method to enable code coverage profiler without enabling type profiler
722         https://bugs.webkit.org/show_bug.cgi?id=160750
723         <rdar://problem/27793469>
724
725         Reviewed by Joseph Pecoraro.
726
727         * UserInterface/Base/Main.js:
728         (WebInspector.loaded):
729         * UserInterface/Views/SourceCodeTextEditor.js:
730         (WebInspector.SourceCodeTextEditor.prototype._setTypeTokenAnnotatorEnabledState):
731
732 2016-08-12  Timothy Hatcher  <timothy@apple.com>
733
734         Web Inspector: Add application/vnd.api+json as a valid JSON MIME-type
735         https://bugs.webkit.org/show_bug.cgi?id=160834
736         rdar://problem/27608536
737
738         Reviewed by Joseph Pecoraro.
739
740         * UserInterface/Views/CodeMirrorAdditions.js: Add Add application/vnd.api+json to extraJSONTypes.
741
742 2016-08-12  Nikita Vasilyev  <nvasilyev@apple.com>
743
744         Web Inspector: Command-Shift-O causes infinite loop if web page has frames
745         https://bugs.webkit.org/show_bug.cgi?id=160810
746
747         Reviewed by Joseph Pecoraro.
748
749         * UserInterface/Views/OpenResourceDialog.js:
750         (WebInspector.OpenResourceDialog.prototype._addResourcesForFrame):
751         "frame" doesn't change inside the loop.
752
753 2016-08-12  Joseph Pecoraro  <pecoraro@apple.com>
754
755         Web Inspector: Support for :lineNumber syntax in Open Resource Dialog
756         https://bugs.webkit.org/show_bug.cgi?id=159732
757         <rdar://problem/27684491>
758
759         Reviewed by Matt Baker.
760
761         Allow the Open Resource Dialog to support line/column syntax.
762         Other tools allow "<name>:<line>:<column>" syntax, where the
763         location data at the end is optional. If the <name> portion
764         is missing, the location can be used for the active content
765         view, assuming it has text data and has lines.
766
767         * UserInterface/Base/Main.js:
768         (WebInspector.focusedOrVisibleContentView):
769         Expose a function to access the current focused / visible content view.
770
771         (WebInspector.dialogWasDismissed):
772         Include passing on cookie data when showing a represented object.
773
774         * UserInterface/Views/Dialog.js:
775         (WebInspector.Dialog):
776         (WebInspector.Dialog.prototype.get visible):
777         (WebInspector.Dialog.prototype.get delegate):
778         (WebInspector.Dialog.prototype.get representedObject):
779         (WebInspector.Dialog.prototype.get cookie):
780         (WebInspector.Dialog.prototype.dismiss):
781         * UserInterface/Models/ResourceQueryResult.js:
782         (WebInspector.ResourceQueryResult):
783         (WebInspector.ResourceQueryResult.prototype.get cookie):
784         Include cookie data along with the represented object in matches
785         and dialog results.
786
787         * UserInterface/Controllers/ResourceQueryController.js:
788         (WebInspector.ResourceQueryController.prototype.executeQuery):
789         Cut off location data from a query, and stash it on the query result.
790         A query can be "<name>:<line>:<column>", and the line/column data
791         becomes cookie data for the resource.
792
793         * UserInterface/Views/OpenResourceDialog.js:
794         (WebInspector.OpenResourceDialog.prototype._populateResourceTreeOutline):
795         If the query is just ":<line>:<column>" have it jump to a location
796         in the current content view if applicable.
797
798         (WebInspector.OpenResourceDialog.prototype._handleKeydownEvent):
799         (WebInspector.OpenResourceDialog.prototype._treeSelectionDidChange):
800         When dismissing, include cookie data.
801
802 2016-08-11  Nikita Vasilyev  <nvasilyev@apple.com>
803
804         REGRESSION (r204264): Web Inspector: Uncaught Exception in Network tab when reloading a web page
805         https://bugs.webkit.org/show_bug.cgi?id=160781
806         <rdar://problem/27810452>
807
808         Reviewed by Matt Baker.
809
810         WebInspector.TimelineDataGrid.prototype.closed was removed in r204264.
811         Define a stub method on DataGrid so it's available to all its subclasses.
812
813         * UserInterface/Views/DataGrid.js:
814         this._dataGrid.closed()
815
816 2016-08-10  Joseph Pecoraro  <pecoraro@apple.com>
817
818         Web Inspector: Should be able to Edit Node Attributes and Styles for non-UserAgent Shadow DOM nodes
819         https://bugs.webkit.org/show_bug.cgi?id=160762
820         <rdar://problem/27798271>
821
822         Reviewed by Ryosuke Niwa.
823
824         * UserInterface/Models/DOMNode.js:
825         (WebInspector.DOMNode.prototype.isInUserAgentShadowTree):
826         (WebInspector.DOMNode.prototype.isShadowRoot):
827         (WebInspector.DOMNode.prototype.isUserAgentShadowRoot):
828         (WebInspector.DOMNode.prototype.ancestorShadowRoot):
829         (WebInspector.DOMNode.prototype.ancestorShadowHost):
830         Add methods for determining the shadow root, host, and easily
831         checking the type of shadow tree a node is in.
832
833         * UserInterface/Models/CSSStyleDeclaration.js:
834         (WebInspector.CSSStyleDeclaration.prototype.get editable):
835         * UserInterface/Views/DOMTreeElement.js:
836         (WebInspector.DOMTreeElement.prototype.get editable):
837         (WebInspector.DOMTreeElement.prototype._startEditingTarget):
838         (WebInspector.DOMTreeElement.prototype._populateTagContextMenu):
839         * UserInterface/Views/RulesStyleDetailsPanel.js:
840         (WebInspector.RulesStyleDetailsPanel.prototype.newRuleButtonClicked):
841         * UserInterface/Views/VisualStyleSelectorSection.js:
842         (WebInspector.VisualStyleSelectorSection.prototype._addNewRule):
843         Allow editing shadow DOM nodes as long as they are not in a UserAgent shadow tree.
844
845         * UserInterface/Views/DOMTreeOutline.js:
846         (WebInspector.DOMTreeOutline.prototype._populateContextMenu):
847         Disallow "Log Element" on UserAgent shadow tree nodes.
848
849 2016-08-10  Nikita Vasilyev  <nvasilyev@apple.com>
850
851         Web Inspector: Can't click on the lower half of "S" icon in JavaScript Allocations timeline
852         https://bugs.webkit.org/show_bug.cgi?id=160743
853         <rdar://problem/27790098>
854
855         Reviewed by Timothy Hatcher.
856
857         "S" icons are covered by .scroll-container, which has `z-index: calc(var(--z-index-resizer) + 1)`.
858         Set larger z-index on the "S" icons.
859
860         * UserInterface/Views/HeapAllocationsTimelineOverviewGraph.css:
861         (.timeline-overview-graph.heap-allocations > img.snapshot):
862
863 2016-08-08  Joseph Pecoraro  <pecoraro@apple.com>
864
865         Web Inspector: Popover for Color Picker should update position when window resizes
866         https://bugs.webkit.org/show_bug.cgi?id=160321
867
868         Reviewed by Brian Burg.
869
870         * UserInterface/Views/Popover.js:
871         (WebInspector.Popover):
872         (WebInspector.Popover.prototype.set windowResizeHandler):
873         (WebInspector.Popover.prototype.dismiss):
874         (WebInspector.Popover.prototype.handleEvent):
875         (WebInspector.Popover.prototype._addListenersIfNeeded):
876         The popover already has a set of window listeners, add "resize" to
877         the list. If there is a resize, invoke a resize handler. The resize
878         handler will only be called while the popover is visible.
879
880         * UserInterface/Views/HeapSnapshotDataGridTree.js:
881         (WebInspector.HeapSnapshotDataGridTree):
882         (WebInspector.HeapSnapshotDataGridTree.prototype.get visible):
883         (WebInspector.HeapSnapshotDataGridTree.prototype.get popoverNode):
884         (WebInspector.HeapSnapshotDataGridTree.prototype.set popoverNode):
885         (WebInspector.HeapSnapshotDataGridTree.prototype.get popoverTargetElement):
886         (WebInspector.HeapSnapshotDataGridTree.prototype.set popoverTargetElement):
887         (WebInspector.HeapSnapshotDataGridTree.prototype.get popover):
888         (WebInspector.HeapSnapshotDataGridTree.prototype.willDismissPopover):
889         * UserInterface/Views/HeapSnapshotInstanceDataGridNode.js:
890         Update heap snapshot popovers to reposition on window resize.
891         Set a target to reposition around, since the popover is shared.
892
893         * UserInterface/Views/ProbeSetDetailsSection.js:
894         (WebInspector.ProbeSetDetailsSection.prototype._addProbeButtonClicked):
895         Update probe expression popover to respect window resizes.
896
897         * UserInterface/Views/VisualStylePropertyEditor.js:
898         (WebInspector.VisualStylePropertyEditor.prototype._showPropertyInfoPopover):
899         Though not yet visible, update this to respect window resizes.
900
901         * UserInterface/Views/InlineSwatch.js:
902         (WebInspector.InlineSwatch.prototype._swatchElementClicked):
903         Add a window resize handler to reposition over the swatch element.
904
905         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
906         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._updatePopoverForSelectedNode):
907         (WebInspector.LayerTreeDetailsSidebarPanel): Deleted.
908         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._windowResized): Deleted.
909         * UserInterface/Views/TimelineDataGrid.js:
910         (WebInspector.TimelineDataGrid.prototype._showPopoverForSelectedNodeSoon):
911         (WebInspector.TimelineDataGrid): Deleted.
912         (WebInspector.TimelineDataGrid.prototype.closed): Deleted.
913         (WebInspector.TimelineDataGrid.prototype.handleEvent): Deleted.
914         (WebInspector.TimelineDataGrid.prototype._windowResized): Deleted.
915         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
916         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._addWatchExpressionButtonClicked):
917         (WebInspector.ScopeChainDetailsSidebarPanel.prototype.willDismissPopover): Deleted.
918         Replace custom popover repositioning with standard Popover handling.
919
920 2016-08-07  Matt Baker  <mattbaker@apple.com>
921
922         REGRESSION (r201245): switching between Computed and Visual Styles panels causes internal error
923         https://bugs.webkit.org/show_bug.cgi?id=160604
924         <rdar://problem/27723416>
925
926         Reviewed by Timothy Hatcher.
927
928         * UserInterface/Views/StyleDetailsPanel.js:
929         (WebInspector.StyleDetailsPanel.prototype.shown):
930         Only perform a layout if needed. Subclasses access node style
931         data during layout, which may not exist yet.
932
933 2016-08-06  Matt Baker  <mattbaker@apple.com>
934
935         REGRESSION (r203253): Node details sidebar flickers while resizing
936         https://bugs.webkit.org/show_bug.cgi?id=160631
937         <rdar://problem/27733024>
938
939         Reviewed by Timothy Hatcher.
940
941         Sidebar panel layouts can be expensive, and should be performed only
942         when necessary (i.e., when the panel is shown for the first time, or
943         model data changed while the panel was hidden).
944
945         * UserInterface/Views/Sidebar.js:
946         (WebInspector.Sidebar.prototype._recalculateWidth):
947
948         * UserInterface/Views/SidebarPanel.js:
949         (WebInspector.SidebarPanel.prototype.shown):
950
951         * UserInterface/Views/View.js:
952         (WebInspector.View.prototype.updateLayoutIfNeeded):
953         Update the layout if an initial layout was never performed.
954
955 2016-08-04  Matt Baker  <mattbaker@apple.com>
956
957         Web Inspector: UI polish for Edit Breakpoint dialog
958         https://bugs.webkit.org/show_bug.cgi?id=160566
959         <rdar://problem/27706378>
960
961         Reviewed by Timothy Hatcher.
962
963         * UserInterface/Images/BreakpointActionAdd.svg: Removed.
964         * UserInterface/Images/BreakpointActionRemove.svg: Removed.
965         Use Plus13.svg and Minus.svg instead.
966
967         * UserInterface/Views/BreakpointActionView.css:
968         (.breakpoint-action-button-container):
969         (.breakpoint-action-append-button,):
970         (.breakpoint-action-append-button):
971         (.breakpoint-action-remove-button):
972         Button styles should match Xcode.
973         (.breakpoint-action-append-button:active,): Deleted.
974         Brightness on activation no longer needed.
975
976         * UserInterface/Views/BreakpointActionView.js:
977         (WebInspector.BreakpointActionView):
978         Add a button container so buttons can float together.
979
980         * UserInterface/Views/BreakpointPopoverController.css:
981         (.wide .edit-breakpoint-popover-condition > .CodeMirror):
982         Increase condition field width by the same amount as the popover.
983
984 2016-08-04  Matt Baker  <mattbaker@apple.com>
985
986         Web Inspector: Popover's arrow is misplaced
987         https://bugs.webkit.org/show_bug.cgi?id=151236
988         <rdar://problem/23527296>
989
990         Reviewed by Brian Burg.
991
992         * UserInterface/Views/Popover.js:
993         (WebInspector.Popover.prototype._setAnchorPoint):
994         Drive-by style fix.
995         (WebInspector.Popover.prototype._drawFrame):
996         Position the arrow so that the arrow head doesn't overlap the
997         rounded corners of its edge.
998
999 2016-08-04  Matt Baker  <mattbaker@apple.com>
1000
1001         Web Inspector: Add placeholder graphs to TimelineOverview while editing
1002         https://bugs.webkit.org/show_bug.cgi?id=160485
1003         <rdar://problem/27670755>
1004
1005         Reviewed by Brian Burg.
1006
1007         Insert placeholder elements in TimelineOverview's graph container
1008         when editing instruments. This allows alternating overview graph styles
1009         to be shown for disabled instruments, and ensures that every tree element
1010         has a corresponding element in the overview during dragging/reordering
1011         of instruments (see https://webkit.org/b/157957).
1012
1013         * UserInterface/Views/TimelineOverview.js:
1014         (WebInspector.TimelineOverview.prototype._startEditingInstruments):
1015         (WebInspector.TimelineOverview.prototype._stopEditingInstruments):
1016
1017 2016-08-04  Matt Baker  <mattbaker@apple.com>
1018
1019         Web Inspector: UI polish for Open Quickly and Goto Line dialogs
1020         https://bugs.webkit.org/show_bug.cgi?id=159849
1021         <rdar://problem/27383068>
1022
1023         Reviewed by Brian Burg.
1024
1025         * UserInterface/Images/Search.svg: Added.
1026         Magnifying glass icon.
1027
1028         * UserInterface/Views/GoToLineDialog.css:
1029         (.go-to-line-dialog):
1030         (.go-to-line-dialog > div):
1031         (.go-to-line-dialog > div::before):
1032         * UserInterface/Views/OpenResourceDialog.css:
1033         (.open-resource-dialog > .field):
1034         (.open-resource-dialog > .field::before):
1035         (.open-resource-dialog.has-results > .tree-outline):
1036         (.open-resource-dialog > .tree-outline .item):
1037         Add search icon to left of the input field in both dialogs,
1038         and adjust styles to better match Xcode 8.
1039
1040         * UserInterface/Views/OpenResourceDialog.js:
1041         (WebInspector.OpenResourceDialog):
1042         Remove "input" event listener, as styles are now toggled in _updateFilter.
1043         (WebInspector.OpenResourceDialog.prototype._updateFilter):
1044         Toggle "has-results" and "non-empty" class names.
1045         (WebInspector.OpenResourceDialog.prototype._handleInputEvent): Deleted.
1046         (WebInspector.OpenResourceDialog.prototype._clear): Deleted.
1047         Moved class toggle to _updateFilter.
1048
1049 2016-08-03  Chris Dumez  <cdumez@apple.com>
1050
1051         Drop DocumentType.internalSubset attribute
1052         https://bugs.webkit.org/show_bug.cgi?id=160530
1053
1054         Reviewed by Alex Christensen.
1055
1056         Drop DocumentType.internalSubset attribute.
1057
1058         * UserInterface/Models/DOMNode.js:
1059         (WebInspector.DOMNode): Deleted.
1060         * UserInterface/Models/DOMSearchMatchObject.js:
1061         (WebInspector.DOMSearchMatchObject.titleForDOMNode): Deleted.
1062         * UserInterface/Views/DOMTreeElement.js:
1063         (WebInspector.DOMTreeElement.prototype._nodeTitleInfo): Deleted.
1064
1065 2016-08-03  Matt Baker  <mattbaker@apple.com>
1066
1067         Web Inspector: Cmd-L shortcut for Jump to Line conflicts with selecting URL of inspected page
1068         https://bugs.webkit.org/show_bug.cgi?id=158028
1069         <rdar://problem/26516663>
1070
1071         Reviewed by Timothy Hatcher.
1072
1073         Remove Command-L shortcut for opening the Line Number dialog, since
1074         we already support Control-G.
1075
1076         * UserInterface/Views/SourceCodeTextEditor.js:
1077         (WebInspector.SourceCodeTextEditor): Deleted.
1078
1079 2016-08-01  Nikita Vasilyev  <nvasilyev@apple.com>
1080
1081         Web Inspector: Don't set `width:calc(100% - 0px); left:0px` on console messages
1082         https://bugs.webkit.org/show_bug.cgi?id=160428
1083         <rdar://problem/27646033>
1084
1085         Reviewed by Timothy Hatcher.
1086
1087         Console messages inside console.group() are indented. Console messages outside of
1088         console.group() aren't and there is no reason to set inline styles that do nothing
1089         on each one of them.
1090
1091         * UserInterface/Views/LogContentView.js:
1092         (WebInspector.LogContentView.prototype.didAppendConsoleMessageView):
1093
1094 2016-08-01  Matt Baker  <mattbaker@apple.com>
1095
1096         Web Inspector: Grid column resizer elements positioned incorrectly
1097         https://bugs.webkit.org/show_bug.cgi?id=160311
1098         <rdar://problem/27595586>
1099
1100         Reviewed by Brian Burg.
1101
1102         Perform a resize layout on a newly shown tab content view if the tab
1103         browser was resized before showing the tab.
1104
1105         * UserInterface/Views/TabBrowser.js:
1106         (WebInspector.TabBrowser):
1107         (WebInspector.TabBrowser.prototype.layout):
1108         Mark all recent tab content views (except for the current view)
1109         as needing a resize layout.
1110
1111         (WebInspector.TabBrowser.prototype._tabBarItemSelected):
1112         If the tab browser was resized while the view was hidden, update the
1113         view's layout for the new content view container size.
1114
1115 2016-08-01  Matt Baker  <mattbaker@apple.com>
1116
1117         Web Inspector: Waterfall graph in Network tab shows too much whitespace/dead time
1118         https://bugs.webkit.org/show_bug.cgi?id=160373
1119
1120         Reviewed by Timothy Hatcher.
1121
1122         Track the start and end time separate from the ruler to remove
1123         leading/trailing whitespace in the graph. Also prevent network
1124         record bars from being clipped.
1125
1126         * UserInterface/Views/NetworkGridContentView.js:
1127         (WebInspector.NetworkGridContentView):
1128         (WebInspector.NetworkGridContentView.prototype.get zeroTime):
1129         Set equal to the ruler start time.
1130         (WebInspector.NetworkGridContentView.prototype.reset):
1131         Reset start and end time.
1132         (WebInspector.NetworkGridContentView.prototype.layout):
1133         Set the initial values for ruler start/zero time if needed.
1134         (WebInspector.NetworkGridContentView.prototype._networkTimelineRecordAdded):
1135         Set the start time if needed.
1136         Reduce debounce from 250ms to 150ms. This prevents the current time from
1137         exceeding the end time by as wide a margin, while keeping the current
1138         time "timer" from being restarted too frequently.
1139
1140         (WebInspector.NetworkGridContentView.prototype._stopUpdatingCurrentTime):
1141         Update the ruler end time and schedule a layout.
1142         Add padding equal to the time needed to draw a network bar at minimum width
1143         to prevent bars from being clipped.
1144
1145 2016-07-29  Matt Baker  <mattbaker@apple.com>
1146
1147         Web Inspector: Inactive/active network bar segments overlap when latency is zero
1148         https://bugs.webkit.org/show_bug.cgi?id=160147
1149         <rdar://problem/27516007>
1150
1151         Reviewed by Joseph Pecoraro.
1152
1153         TimelineRecordBar should hide the inactive segment when its duration
1154         is less than the minimum displayable size. The active segment can
1155         assume the whole width of the bar.
1156
1157         * UserInterface/Views/TimelineOverviewGraph.js:
1158         (WebInspector.TimelineOverviewGraph.prototype.get secondsPerPixel):
1159         Make secondsPerPixel available during TimelineRecordBars.refresh.
1160
1161         * UserInterface/Views/TimelineRecordBar.js:
1162         (WebInspector.TimelineRecordBar.prototype.refresh):
1163         Check inactive duration against the minimum display size,
1164         and add/remove DOM nodes and bar styles as needed.
1165
1166 2016-07-29  Nikita Vasilyev  <nvasilyev@apple.com>
1167
1168         REGRESSION (r195456): Web Inspector: Changing tabs in Styles sidebar shouldn't change sidebar's width
1169         https://bugs.webkit.org/show_bug.cgi?id=159646
1170         <rdar://problem/27286338>
1171
1172         Reviewed by Brian Burg.
1173
1174         Remember sidebar width on per tab basis. For example, Node, Styles, and Layers sidebar panels in
1175         Elements tab should all have the same width, but Resource sidebar panel in Debugger tab should NOT
1176         share its width Element tab's sidebar.
1177
1178         TabContentView stores the width but TabBrowser manages saving and restoring it.
1179         The same way collapsed sidebar state is handled.
1180
1181         * UserInterface/Views/Sidebar.js:
1182         (WebInspector.Sidebar.prototype.set collapsed):
1183         Don't change sidebar's width when sidebar panels change.
1184
1185         (WebInspector.Sidebar.prototype._recalculateWidth):
1186         (WebInspector.Sidebar.prototype.set selectedSidebarPanel): Deleted.
1187         Pass newWidth as an argument so it can be saved in TabBrowser.
1188
1189         * UserInterface/Views/SidebarPanel.js:
1190         (WebInspector.SidebarPanel): Deleted.
1191         (WebInspector.SidebarPanel.prototype.get savedWidth): Deleted.
1192         (WebInspector.SidebarPanel.prototype.sizeDidChange): Deleted.
1193         Remove the per sidebar panel width setting that was added in r195456.
1194
1195         * UserInterface/Views/TabBrowser.js:
1196         (WebInspector.TabBrowser):
1197         (WebInspector.TabBrowser.prototype._detailsSidebarWidthDidChange):
1198         (WebInspector.TabBrowser.prototype._showDetailsSidebarPanelsForTabContentView):
1199         * UserInterface/Views/TabContentView.js:
1200         (WebInspector.TabContentView):
1201         (WebInspector.TabContentView.prototype.get detailsSidebarWidthSetting):
1202         Store details sidebar width on TabContentView.
1203
1204 2016-07-29  Matt Baker  <mattbaker@apple.com>
1205
1206         Web Inspector: Assertion in NetworkGridContentView when updating data grid for the first time
1207         https://bugs.webkit.org/show_bug.cgi?id=160330
1208         <rdar://problem/27600905>
1209
1210         Reviewed by Brian Burg.
1211
1212         When the first grid node is added, a view layout and current time update
1213         are scheduled. A view layout occurring before the current time is updated
1214         should be skipped, since the ruler end time hasn't been set.
1215
1216         * UserInterface/Views/NetworkGridContentView.js:
1217         (WebInspector.NetworkGridContentView.prototype.layout):
1218         Skip layout until current time is updated.
1219         (WebInspector.NetworkGridContentView.prototype._update):
1220         Remove unused variables `startTime` and `endTime`. Don't force a layout
1221         if the elapsed time is zero.
1222
1223 2016-07-28  Chris Dumez  <cdumez@apple.com>
1224
1225         Parameters to Event.initEvent() should be mandatory
1226         https://bugs.webkit.org/show_bug.cgi?id=160320
1227
1228         Reviewed by Darin Adler.
1229
1230         Update WebInspector accordingly.
1231
1232         * UserInterface/Models/NativeFunctionParameters.js:
1233
1234 2016-07-28  Chris Dumez  <cdumez@apple.com>
1235
1236         First parameter to canvas.getContext() / probablySupportsContext() should be mandatory
1237         https://bugs.webkit.org/show_bug.cgi?id=160312
1238
1239         Reviewed by Darin Adler.
1240
1241         Update WebInspector accordingly.
1242
1243         * UserInterface/Models/NativeFunctionParameters.js:
1244
1245 2016-07-28  Matt Baker  <mattbaker@apple.com>
1246
1247         Web Inspector: Hiding a column which contains a TimelineRuler as the headerview, doesn't hide the headerView
1248         https://bugs.webkit.org/show_bug.cgi?id=160093
1249         <rdar://problem/27499300>
1250
1251         Reviewed by Joseph Pecoraro.
1252
1253         * UserInterface/Views/DataGrid.js:
1254         (WebInspector.DataGrid.prototype._positionHeaderViews):
1255         Remove early return so that a header view in a hidden column will have
1256         its width resized to zero, matching the column.
1257
1258 2016-07-28  Johan K. Jensen  <johan_jensen@apple.com>
1259
1260         Web Inspector: Waterfall view should be visible in Network tab and Network Timeline
1261         https://bugs.webkit.org/show_bug.cgi?id=160061
1262
1263         Reviewed by Joseph Pecoraro.
1264
1265         Adds a Timeline-column (waterfall) to the Network tab and Network Timeline.
1266
1267         * Localizations/en.lproj/localizedStrings.js:
1268         Add "Timeline" localized string.
1269
1270         * UserInterface/Views/NetworkGridContentView.js:
1271         (WebInspector.NetworkGridContentView):
1272         Add the Timeline-column with a TimelineRuler as the headerview,
1273         and properties for updating current time.
1274
1275         (WebInspector.NetworkGridContentView.prototype.get secondsPerPixel):
1276         (WebInspector.NetworkGridContentView.prototype.get startTime):
1277         (WebInspector.NetworkGridContentView.prototype.get currentTime):
1278         (WebInspector.NetworkGridContentView.prototype.get endTime):
1279         Acting as a graphDataSource used by TimelineDataGridNode.
1280
1281         (WebInspector.NetworkGridContentView.prototype.shown):
1282         (WebInspector.NetworkGridContentView.prototype.reset):
1283         (WebInspector.NetworkGridContentView.prototype.layout):
1284         Refresh graphs and update the TimelineRuler on layout changes.
1285
1286         (WebInspector.NetworkGridContentView.prototype._networkTimelineRecordAdded):
1287         Add listeners for when resources are finished to stop the timer.
1288
1289         (WebInspector.NetworkGridContentView.prototype._update):
1290         (WebInspector.NetworkGridContentView.prototype._startUpdatingCurrentTime):
1291         (WebInspector.NetworkGridContentView.prototype._stopUpdatingCurrentTime):
1292         Adding a timer which updates the TimelineRuler and the layout
1293         if any non-finished requests are running.
1294
1295         * UserInterface/Views/NetworkTimelineView.js:
1296         (WebInspector.NetworkTimelineView):
1297         Add the Timeline-column with a TimelineRuler as the headerview.
1298
1299         (WebInspector.NetworkTimelineView.prototype.get secondsPerPixel):
1300         (WebInspector.NetworkTimelineView.prototype.layout):
1301         Refresh graphs on layout changes.
1302
1303         * UserInterface/Views/TimelineDataGrid.css:
1304         (.tree-outline.timeline-data-grid .item:hover .subtitle):
1305         (.data-grid.timeline th):
1306         (.data-grid.timeline th.graph-column > .timeline-ruler):
1307         (.data-grid.timeline td.graph-column):
1308         (.data-grid.timeline td.graph-column > .cell-content):
1309         (.data-grid.timeline td.graph-column .timeline-record-bar):
1310
1311 2016-07-28  Chris Dumez  <cdumez@apple.com>
1312
1313         Parameter to table.deleteRow() / body.deleteRow() should be mandatory
1314         https://bugs.webkit.org/show_bug.cgi?id=160307
1315
1316         Reviewed by Ryosuke Niwa.
1317
1318         Update WebInspector accordingly.
1319
1320         * UserInterface/Models/NativeFunctionParameters.js:
1321
1322 2016-07-28  Chris Dumez  <cdumez@apple.com>
1323
1324         2 first parameters to input.setSelectionRange() should be mandatory
1325         https://bugs.webkit.org/show_bug.cgi?id=160310
1326
1327         Reviewed by Alex Christensen.
1328
1329         Update WebInspector accordingly.
1330
1331         * UserInterface/Models/NativeFunctionParameters.js:
1332
1333 2016-07-28  Chris Dumez  <cdumez@apple.com>
1334
1335         Parameter to tr.deleteCell() should be mandatory
1336         https://bugs.webkit.org/show_bug.cgi?id=160308
1337
1338         Reviewed by Ryosuke Niwa.
1339
1340         Report tr.deleteCell() parameter as mandatory.
1341
1342         * UserInterface/Models/NativeFunctionParameters.js:
1343
1344 2016-07-27  Nikita Vasilyev  <nvasilyev@apple.com>
1345
1346         Web Inspector: Visual Styles Sidebar should have only one column when it's narrow
1347         https://bugs.webkit.org/show_bug.cgi?id=159905
1348         <rdar://problem/27413248>
1349
1350         Reviewed by Joseph Pecoraro.
1351
1352         Many CSS values often get clipped in the two colunm layout. Change the layout to one colunm
1353         when visual style rows get too narrow.
1354
1355         * UserInterface/Views/VisualStyleDetailsPanel.css:
1356         (.sidebar > .panel.details.css-style .visual > .details-section .details-section > .content .group > .row):
1357         (.sidebar > .panel.details.css-style .visual > .details-section .details-section > .content .group > .metric-section-row):
1358         Wrap all rows except for position/padding/margin controls.
1359
1360         (.sidebar > .panel.details.css-style .visual > .details-section .details-section > .content .group > .row > .visual-style-property-container:not(.layout-reversed):last-child): Deleted.
1361         Margin between the first and the second column doesn't make sense one column layout.
1362         Set the margin in .visual-style-property-container instead.
1363
1364         * UserInterface/Views/VisualStyleDetailsPanel.js:
1365         (WebInspector.VisualStyleDetailsPanel.prototype._generateMetricSectionRows):
1366         * UserInterface/Views/VisualStylePropertyEditor.css:
1367         (.visual-style-property-container):
1368
1369 2016-07-27  Joseph Pecoraro  <pecoraro@apple.com>
1370
1371         [Mac] Web Inspector: CodeMirror-based editor bindings for Home and End don't match system behavior
1372         https://bugs.webkit.org/show_bug.cgi?id=160267
1373         <rdar://problem/27575553>
1374
1375         Reviewed by Brian Burg.
1376
1377         * UserInterface/Views/CodeMirrorEditor.js:
1378         (WebInspector.CodeMirrorEditor.create):
1379         (WebInspector.CodeMirrorEditor):
1380         Add some key map overrides for Home and End to better match system Mac
1381         behavior. This scrolls to the start or end of a document and does not
1382         change the cursor position.
1383
1384 2016-07-27  Brian Burg  <bburg@apple.com>
1385
1386         Regression(r203535): Uncaught Exception: TypeError: Not enough arguments at LayerTreeDataGridNode.js:47
1387         https://bugs.webkit.org/show_bug.cgi?id=160187
1388         <rdar://problem/27540435>
1389
1390         Reviewed by Eric Carlson.
1391
1392         After r203535, document.createTextNode() requires an argument.
1393
1394         * UserInterface/Views/LayerTreeDataGridNode.js:
1395         (WebInspector.LayerTreeDataGridNode.prototype.createCellContent):
1396         Since this use-site is for creating a cell in an unknown column,
1397         initialize it to '–'. Previously it would have been the string
1398         "undefined" or empty.
1399
1400 2016-07-24  Matt Baker  <mattbaker@apple.com>
1401
1402         Web Inspector: Filtering is broken in the Overview timeline view
1403         https://bugs.webkit.org/show_bug.cgi?id=160152
1404         <rdar://problem/27517481>
1405
1406         Reviewed by Joseph Pecoraro.
1407
1408         * UserInterface/Views/SourceCodeTimelineTimelineDataGridNode.js:
1409         (WebInspector.SourceCodeTimelineTimelineDataGridNode.prototype.filterableDataForColumn):
1410         Non-resource nodes should be filtered based on their display name.
1411
1412 2016-07-23  Nikita Vasilyev  <nvasilyev@apple.com>
1413
1414         REGRESSION (r202876): Web Inspector: Switching away from Console tab with a lot of messages is slow
1415         https://bugs.webkit.org/show_bug.cgi?id=160112
1416
1417         Reviewed by Joseph Pecoraro.
1418
1419         Showing NavigationSidebar before removing previous TabContentView can be very slow when
1420         TabContentView is ConsoleTabContentView with a lot of messages. The order of operations
1421         (show sidebar, change content view, show sidebar) caused more forced layouts. This patch
1422         reduces the number of forced layouts by changes the order to: show content view, show sidebar,
1423         show sidebar.
1424
1425         * UserInterface/Views/TabBrowser.js:
1426         (WebInspector.TabBrowser.prototype._tabBarItemSelected):
1427
1428 2016-07-20  Joseph Pecoraro  <pecoraro@apple.com>
1429
1430         Web Inspector: Pausing when Debugger tab is closed opens tab in wrong state
1431         https://bugs.webkit.org/show_bug.cgi?id=159946
1432         <rdar://problem/27429886>
1433
1434         Reviewed by Timothy Hatcher.
1435
1436         * UserInterface/Views/DebuggerSidebarPanel.js:
1437         (WebInspector.DebuggerSidebarPanel):
1438         At the end of construction, update the UI to match the current state
1439         of the world. Such as updating the UI if we are paused, or if the
1440         Timeline is capturing and we are temporarily disabling breakpoints.
1441
1442 2016-07-15  Timothy Hatcher  <timothy@apple.com>
1443
1444         Web Inspector: Make Open Quickly and Goto Line dialogs match Xcode 8
1445         https://bugs.webkit.org/show_bug.cgi?id=159823
1446         rdar://problem/27376501
1447
1448         Reviewed by Brian Burg.
1449
1450         * UserInterface/Views/GoToLineDialog.css:
1451         (.go-to-line-dialog):
1452         (.go-to-line-dialog > div > input):
1453         (.go-to-line-dialog > div > input::placeholder):
1454         (.go-to-line-dialog > div > img):
1455         (.go-to-line-dialog > div): Deleted.
1456         * UserInterface/Views/OpenResourceDialog.css:
1457         (.open-resource-dialog):
1458         (.open-resource-dialog > .field):
1459         (.open-resource-dialog > .field > input):
1460         (.open-resource-dialog > .field > input::placeholder):
1461         (.open-resource-dialog > .field > img):
1462         (.open-resource-dialog > .tree-outline .item): Deleted.
1463         (.open-resource-dialog > .tree-outline .item:first-child): Deleted.
1464
1465 2016-07-14  Joseph Pecoraro  <pecoraro@apple.com>
1466
1467         Web Inspector: Rename CCTNode to CallingContextTreeNode
1468         https://bugs.webkit.org/show_bug.cgi?id=159782
1469
1470         Reviewed by Timothy Hatcher.
1471
1472         * UserInterface/Models/CallingContextTree.js:
1473         * UserInterface/Models/CallingContextTreeNode.js:
1474         Extra to its own file and rename.
1475
1476         * UserInterface/Main.html:
1477         * UserInterface/Test.html:
1478         * UserInterface/TestStub.html:
1479         Include the new file.
1480
1481         * UserInterface/Views/ProfileDataGridNode.js:
1482         (WebInspector.ProfileDataGridNode):
1483         * UserInterface/Views/ProfileDataGridTree.js:
1484         (WebInspector.ProfileDataGridTree.prototype._updateCurrentFocusDetails):
1485         Rename shorthand "cctnode".
1486
1487 2016-07-14  Matt Baker  <mattbaker@apple.com>
1488
1489         Web Inspector: SidebarPanel classes should use View.layout instead of "refresh"
1490         https://bugs.webkit.org/show_bug.cgi?id=159745
1491         <rdar://problem/27335252>
1492
1493         Reviewed by Timothy Hatcher.
1494
1495         * UserInterface/Views/ApplicationCacheDetailsSidebarPanel.js:
1496         (WebInspector.ApplicationCacheDetailsSidebarPanel.prototype.set applicationCacheFrame):
1497         Use needsLayout.
1498
1499         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
1500         (WebInspector.CSSStyleDetailsSidebarPanel.prototype.layout):
1501         Move refresh logic to layout.
1502         (WebInspector.CSSStyleDetailsSidebarPanel.prototype.initialLayout):
1503         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._styleSheetAddedOrRemoved):
1504         Defer layout to coalesce updates.
1505         (WebInspector.CSSStyleDetailsSidebarPanel):
1506         (WebInspector.CSSStyleDetailsSidebarPanel.prototype.refresh): Deleted.
1507
1508         * UserInterface/Views/DOMDetailsSidebarPanel.js:
1509         (WebInspector.DOMDetailsSidebarPanel.prototype.set domNode):
1510         Use needsLayout.
1511
1512         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
1513         Move refresh logic to layout.
1514
1515         * UserInterface/Views/DetailsSidebarPanel.js:
1516         (WebInspector.DetailsSidebarPanel.prototype.shown): Deleted.
1517         Base class already forces a layout when shown.
1518         (WebInspector.DetailsSidebarPanel.prototype.needsRefresh): Deleted.
1519         No longer needed.
1520         (WebInspector.DetailsSidebarPanel.prototype.refresh): Deleted.
1521         Renamed layout.
1522         (WebInspector.DetailsSidebarPanel): Deleted.
1523
1524         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
1525         (WebInspector.LayerTreeDetailsSidebarPanel.prototype.supportsDOMNode):
1526         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._layerTreeDidChange):
1527         Use needsLayout.
1528         (WebInspector.LayerTreeDetailsSidebarPanel.prototype.shown):
1529         Base class already forces a layout when shown.
1530
1531         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
1532         (WebInspector.ResourceDetailsSidebarPanel.prototype.set resource):
1533         Use needsLayout.
1534
1535         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
1536         (WebInspector.ScopeChainDetailsSidebarPanel):
1537         (WebInspector.ScopeChainDetailsSidebarPanel.prototype.set callFrame):
1538         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._addWatchExpression):
1539         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._removeWatchExpression):
1540         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._clearAllWatchExpressions):
1541         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._refreshAllWatchExpressionsButtonClicked):
1542         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._didEvaluateExpression):
1543         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._mainResourceDidChange):
1544         Use needsLayout.
1545
1546 2016-07-14  Joseph Pecoraro  <pecoraro@apple.com>
1547
1548         Web Inspector: Maintain selected function when switching between different profile representations
1549         https://bugs.webkit.org/show_bug.cgi?id=159778
1550         <rdar://problem/27355913>
1551
1552         Reviewed by Timothy Hatcher.
1553
1554         * UserInterface/Models/CallingContextTree.js:
1555         (WebInspector.CCTNode):
1556         (WebInspector.CCTNode.prototype.get hash):
1557         (WebInspector.CCTNode.prototype.findOrMakeChild):
1558         (WebInspector.CCTNode.prototype.equals):
1559         Expose the hash so two nodes can be compared cheaply.
1560
1561         * UserInterface/Views/ProfileView.js:
1562         (WebInspector.ProfileView.prototype._repopulateDataGridFromTree):
1563         (WebInspector.ProfileView.prototype._restoreSharedState):
1564         (WebInspector.ProfileView.prototype._dataGridNodeSelected):
1565         Share data between multiple ProfileViews. Currently just remembering
1566         and restoring the selected function.
1567
1568         * UserInterface/Views/ScriptProfileTimelineView.js:
1569         (WebInspector.ScriptProfileTimelineView):
1570         (WebInspector.ScriptProfileTimelineView.prototype._showProfileViewForOrientation):
1571         Include the shared data when constructing new ProfileViews.
1572
1573 2016-07-13  Matt Baker  <mattbaker@apple.com>
1574
1575         Uncaught Exception: TypeError: null is not an object (evaluating 'this._contentViewContainer.currentContentView.showsFilterBar')
1576         https://bugs.webkit.org/show_bug.cgi?id=159696
1577         <rdar://problem/27312356>
1578
1579         Reviewed by Joseph Pecoraro.
1580
1581         * UserInterface/Views/TimelineRecordingContentView.js:
1582         (WebInspector.TimelineRecordingContentView.prototype._contentViewSelectionPathComponentDidChange):
1583         Early return if content view not visible, since the event is sent during
1584         tab teardown and the current TimelineView may be invalid.
1585
1586 2016-07-12  Joseph Pecoraro  <pecoraro@apple.com>
1587
1588         REGRESSION(r192789): Web Inspector: Log Value context menu appears twice
1589         https://bugs.webkit.org/show_bug.cgi?id=159681
1590         <rdar://problem/27304804>
1591
1592         Reviewed by Brian Burg.
1593
1594         In r192789 contextmenu events may bubble up so that multiple handlers
1595         may append ContextMenuItems. In nested ObjectTrees / ObjectPreviews
1596         this could result in duplicate items. Add a flag on the bubbling event
1597         so that we only include Object Tree context menu items for the deepest
1598         part of the Object Tree, but still allow bubbling up to the root.
1599
1600         * UserInterface/Views/ObjectPreviewView.js:
1601         (WebInspector.ObjectPreviewView.prototype._contextMenuHandler):
1602         (WebInspector.ObjectPreviewView):
1603         * UserInterface/Views/ObjectTreeBaseTreeElement.js:
1604         (WebInspector.ObjectTreeBaseTreeElement.prototype._contextMenuHandler):
1605
1606 2016-07-12  Johan K. Jensen  <johan_jensen@apple.com>
1607
1608         Web Inspector: ER: Copy as cURL
1609         https://bugs.webkit.org/show_bug.cgi?id=159380
1610
1611         Reviewed by Joseph Pecoraro.
1612
1613         Inspired by https://chromium.googlesource.com/chromium/src/+/b7c1115dbae65030ad96e773d9a270465a05f5c4/third_party/WebKit/Source/devtools/front_end/network/NetworkLogView.js
1614
1615         This "Copy as cURL" feature only approximates the original request as only some parts of
1616         that request is known to the frontend.
1617
1618         * UserInterface/Models/Resource.js:
1619         (WebInspector.Resource.prototype.generateCURLCommand.escapeStringPosix.escapeCharacter):
1620         (WebInspector.Resource.prototype.generateCURLCommand.escapeStringPosix):
1621         (WebInspector.Resource.prototype.generateCURLCommand):
1622         (WebInspector.Resource):
1623         * UserInterface/Views/ResourceTimelineDataGridNode.js:
1624         (WebInspector.ResourceTimelineDataGridNode.prototype.appendContextMenuItems):
1625
1626 2016-07-12  Joseph Pecoraro  <pecoraro@apple.com>
1627
1628         Web Inspector: Use separate files for TreeOutline/TreeElement and DataGrid/DataGridNode
1629         https://bugs.webkit.org/show_bug.cgi?id=159659
1630
1631         Reviewed by Timothy Hatcher.
1632
1633         * UserInterface/Main.html:
1634         * UserInterface/Views/DataGrid.js:
1635         * UserInterface/Views/DataGridNode.js: Added.
1636         * UserInterface/Views/TreeElement.js: Added.
1637         * UserInterface/Views/TreeOutline.js:
1638         Extra the component classes to their own file.
1639
1640 2016-07-11  Joseph Pecoraro  <pecoraro@apple.com>
1641
1642         Web Inspector: ProfileView sometimes shows Top Functions data despite Top Functions being disabled
1643         https://bugs.webkit.org/show_bug.cgi?id=159660
1644         <rdar://problem/27291647>
1645
1646         Reviewed by Timothy Hatcher.
1647
1648         * UserInterface/Views/ScriptProfileTimelineView.js:
1649         (WebInspector.ScriptProfileTimelineView.prototype._profileOrientationButtonClicked):
1650         Pass the value of the setting, not the setting itself.
1651
1652 2016-07-11  Nikita Vasilyev  <nvasilyev@apple.com>
1653
1654         Web Inspector: Transition and Animation sections in Visual Styles sidebar should have more spacing to their left
1655         https://bugs.webkit.org/show_bug.cgi?id=159633
1656         <rdar://problem/27281805>
1657
1658         Reviewed by Timothy Hatcher.
1659
1660         * UserInterface/Views/VisualStyleDetailsPanel.css:
1661         (.visual-style-property-container.animation):
1662
1663 2016-07-08  Nikita Vasilyev  <nvasilyev@apple.com>
1664
1665         Web Inspector: Command-Shift-S in the Styles sidebar should always show the save dialog
1666         https://bugs.webkit.org/show_bug.cgi?id=156858
1667         <rdar://problem/25859098>
1668
1669         Reviewed by Timothy Hatcher.
1670
1671         * UserInterface/Views/CSSStyleDeclarationSection.js:
1672         (WebInspector.CSSStyleDeclarationSection):
1673
1674 2016-07-07  Joseph Pecoraro  <pecoraro@apple.com>
1675
1676         Web Inspector, regression: JS/JSON pretty-printing sporadically broken in STP8
1677         https://bugs.webkit.org/show_bug.cgi?id=159511
1678         <rdar://problem/27218435>
1679
1680         Reviewed by Timothy Hatcher.
1681
1682         * UserInterface/Workers/Formatter/FormatterWorker.js:
1683         (FormatterWorker.prototype.formatJavaScript):
1684         Attempt to format invalid JSON that can be evaluated to an object.
1685
1686 2016-07-07  Timothy Hatcher  <timothy@apple.com>
1687
1688         Web Inspector: scrolled Snapshot list is reset to top and drawn blank after switching back from Snapshot Comparison view
1689         https://bugs.webkit.org/show_bug.cgi?id=158218
1690         rdar://problem/26545000
1691
1692         Reviewed by Brian Burg.
1693
1694         * UserInterface/Views/ClusterContentView.js:
1695         (WebInspector.ClusterContentView.prototype.get scrollableElements): Added.
1696         A default implementation for all cluster views.
1697
1698         * UserInterface/Views/DOMStorageContentView.js:
1699         (WebInspector.DOMStorageContentView.prototype.get scrollableElements): Deleted.
1700         This was duplicated in the class, removed one.
1701
1702         * UserInterface/Views/HeapAllocationsTimelineView.js:
1703         (WebInspector.HeapAllocationsTimelineView): Initialize _snapshotListScrollTop.
1704         (WebInspector.HeapAllocationsTimelineView.prototype.get scrollableElements): Added. Return elements
1705         based on what is showing.
1706
1707         (WebInspector.HeapAllocationsTimelineView.prototype.showHeapSnapshotList): Restore the scroll position
1708         of the DataGrid after it is added to the view.
1709
1710         (WebInspector.HeapAllocationsTimelineView.prototype.showHeapSnapshotTimelineRecord): Save the scroll position
1711         of the DataGrid before it is removed from the view.
1712
1713         * UserInterface/Views/ScriptClusterTimelineView.js:
1714         (WebInspector.ScriptClusterTimelineView.prototype.get scrollableElements): Deleted. Handled by the base class now.
1715
1716 2016-07-06  Timothy Hatcher  <timothy@apple.com>
1717
1718         Web Inspector: REGRESSION: Hitting ⌘T in Web Inspector no longer opens in new tab in Safari
1719         https://bugs.webkit.org/show_bug.cgi?id=159487
1720         rdar://problem/27188047
1721
1722         Change Command-T to Command-Option-T to open a new tab.
1723
1724         I also changed Command-1, etc. to Command-Option-1, etc. to switch tabs. The number commands
1725         conflicted similarly with Safari and didn't work for me as a Web Inspector shortcut at all.
1726         We can't use Command-Shift because of Command-Shift-3 and Command-Shift-4 for screenshots.
1727
1728         Reviewed by Joseph Pecoraro.
1729
1730         * UserInterface/Base/Main.js:
1731         (WebInspector.contentLoaded):
1732
1733 2016-07-06  Joseph Pecoraro  <pecoraro@apple.com>
1734
1735         Web Inspector: sometimes reloading a page with main resource selected will show an empty content view
1736         https://bugs.webkit.org/show_bug.cgi?id=158069
1737         <rdar://problem/26516710>
1738
1739         Reviewed by Timothy Hatcher.
1740
1741         * UserInterface/Views/DebuggerSidebarPanel.js:
1742         (WebInspector.DebuggerSidebarPanel.prototype.showDefaultContentView):
1743         Continue until we get one that works.
1744
1745         * UserInterface/Views/NavigationSidebarPanel.js:
1746         (WebInspector.NavigationSidebarPanel.prototype.showDefaultContentViewForTreeElement):
1747         Avoid showing a content view for a background tab if it could steal
1748         the content view from a foreground tab. This is a targeted fix for
1749         reload + tab content view loading behavior. A more general fix would
1750         be reducing the work done by non-foreground tabs.
1751
1752         * UserInterface/Views/TabBrowser.js:
1753         (WebInspector.TabBrowser.prototype._tabBarItemSelected):
1754         Update navigation sidebar first so it is set when showing the TabContentView.
1755
1756 2016-07-06  Brian Burg  <bburg@apple.com>
1757
1758         Web Inspector: Uncaught Exception reporter should include the currently dispatching protocol event or request/response if applicable
1759         https://bugs.webkit.org/show_bug.cgi?id=159320
1760         <rdar://problem/27117754>
1761
1762         Reviewed by Timothy Hatcher and Joseph Pecoraro.
1763
1764         Keep track of the currently dispatched protocol response or protocol event and make
1765         them available to the uncaught exception reporter. If an internal exception is reported
1766         while dispatching an event or response, dump the protocol message(s) into the pre-filled
1767         bug report.
1768
1769         * UserInterface/Debug/UncaughtExceptionReporter.js:
1770         (stringifyAndTruncateObject): Added.
1771         Rearrange the code that generates the pre-filled report so it's easier to add optional sections.
1772
1773         * UserInterface/Protocol/InspectorBackend.js:
1774         (InspectorBackendClass):
1775         (InspectorBackendClass.prototype.get currentDispatchState): Expose the dispatching state.
1776         (InspectorBackendClass.prototype._sendCommandToBackendWithCallback):
1777         (InspectorBackendClass.prototype._sendCommandToBackendExpectingPromise):
1778         Store the originating command request with the pendingResponse data so that we can examine
1779         the originating request if the response causes an error. This will cause request message objects
1780         to be garbage-collected after their responses are dispatched rather than when the request is sent.
1781         But, I don't forsee this being a performance problem since we should always get a command response
1782         and pending command responses do not typically accumulate except when the inspector first loads.
1783
1784         (InspectorBackendClass.prototype._dispatchResponse): Save the response being dispatched.
1785         (InspectorBackendClass.prototype._dispatchResponseToCallback): Simplify exception reporting.
1786         (InspectorBackendClass.prototype._dispatchEvent): Save the event being dispatched.
1787
1788 2016-07-05  Timothy Hatcher  <timothy@apple.com>
1789
1790         Web Inspector: Switch last uses of -webkit-linear-gradient() to linear-gradient()
1791         https://bugs.webkit.org/show_bug.cgi?id=159438
1792         rdar://problem/27183417
1793
1794         Reviewed by Joseph Pecoraro.
1795
1796         * UserInterface/Views/RenderingFrameTimelineOverviewGraph.css:
1797         (.timeline-overview-graph.rendering-frame > .frame-marker):
1798         (body.window-inactive .timeline-overview-graph.rendering-frame > .frame-marker):
1799         * UserInterface/Views/TimelineRecordFrame.css:
1800         (.timeline-record-frame.tall):
1801         (.timeline-record-frame.selected):
1802         (body.window-inactive .timeline-record-frame.selected):
1803
1804 2016-07-05  Timothy Hatcher  <timothy@apple.com>
1805
1806         Web Inspector: Drop -webkit-calc() in completions and a single use
1807         https://bugs.webkit.org/show_bug.cgi?id=159435
1808         rdar://problem/27179340
1809
1810         Reviewed by Dean Jackson.
1811
1812         * UserInterface/Models/CSSKeywordCompletions.js:
1813         * UserInterface/Views/VisualStylePropertyEditorLink.css:
1814         (.visual-style-property-editor-link > .visual-style-property-editor-link-border):
1815
1816 2016-07-05  Timothy Hatcher  <timothy@apple.com>
1817
1818         Web Inspector: Drop the prefix from -webkit-image-set()
1819         https://bugs.webkit.org/show_bug.cgi?id=159433
1820         rdar://problem/27178887
1821
1822         Reviewed by Dean Jackson.
1823
1824         * UserInterface/Models/CSSKeywordCompletions.js:
1825         * UserInterface/Views/ApplicationCacheIcons.css:
1826         (.application-cache-manifest .icon):
1827         (.application-cache-frame .icon):
1828         * UserInterface/Views/CookieIcon.css:
1829         (.cookie-icon .icon):
1830         * UserInterface/Views/DOMStorageIcons.css:
1831         (.local-storage-icon .icon):
1832         (.session-storage-icon .icon):
1833         * UserInterface/Views/DatabaseIcon.css:
1834         (.database-icon .icon):
1835         * UserInterface/Views/DatabaseTableIcon.css:
1836         (.database-table-icon .icon):
1837         * UserInterface/Views/FolderIcon.css:
1838         (.folder-icon .icon):
1839         * UserInterface/Views/GradientSlider.css:
1840         (.gradient-slider-knob):
1841         (.gradient-slider-knob.selected):
1842         * UserInterface/Views/HoverMenu.css:
1843         (.hover-menu > img):
1844         * UserInterface/Views/ResourceIcons.css:
1845         (.resource-icon .icon):
1846         (.resource-icon.resource-type-document .icon):
1847         (.resource-icon.resource-type-image .icon):
1848         (.resource-icon.resource-type-font .icon):
1849         (.resource-icon.resource-type-stylesheet .icon):
1850         (.resource-icon.resource-type-script .icon):
1851         (.anonymous-script-icon .icon):
1852         (.source-map-resource.resource-icon .icon):
1853         (.source-map-resource.resource-icon.resource-type-stylesheet .icon):
1854         (.source-map-resource.resource-icon.resource-type-script .icon):
1855         (.large .resource-icon .icon):
1856         (.large .resource-icon.resource-type-document .icon):
1857         (.large .resource-icon.resource-type-image .icon):
1858         (.large .resource-icon.resource-type-font .icon):
1859         (.large .resource-icon.resource-type-stylesheet .icon):
1860         (.large .resource-icon.resource-type-script .icon):
1861         (.large .anonymous-script-icon .icon):
1862         (.large .source-map-resource.resource-icon .icon):
1863         (.large .source-map-resource.resource-icon.resource-type-stylesheet .icon):
1864         (.large .source-map-resource.resource-icon.resource-type-script .icon):
1865         * UserInterface/Views/Slider.css:
1866         (.slider > img):
1867         (.slider > img.dragging):
1868         * UserInterface/Views/SourceCodeTextEditor.css:
1869         (.hover-menu.color > img):
1870         * UserInterface/Views/TextEditor.css:
1871         (.text-editor > .CodeMirror .has-breakpoint .CodeMirror-linenumber::before):
1872         (.text-editor > .CodeMirror .breakpoint-resolved .CodeMirror-linenumber::before):
1873         (.text-editor > .CodeMirror .execution-line .CodeMirror-linenumber::after):
1874         * UserInterface/Views/TimelineIcons.css:
1875         (body:not(.mac-platform, .windows-platform) .network-icon .icon):
1876         (body:not(.mac-platform, .windows-platform) .network-icon.large .icon):
1877         (body:not(.mac-platform, .windows-platform) .layout-icon .icon):
1878         (body:not(.mac-platform, .windows-platform) .layout-icon.large .icon):
1879         (body:not(.mac-platform, .windows-platform) .script-icon .icon):
1880         (body:not(.mac-platform, .windows-platform) .script-icon.large .icon):
1881         (body:not(.mac-platform, .windows-platform) .rendering-frame-icon .icon):
1882         (body:not(.mac-platform, .windows-platform) .memory-icon .icon):
1883         (body:not(.mac-platform, .windows-platform) .heap-allocations-icon .icon):
1884         (body:not(.mac-platform, .windows-platform) .stopwatch-icon .icon):
1885
1886 2016-07-02  Joseph Pecoraro  <pecoraro@apple.com>
1887
1888         Web Inspector: CallFrame console.assert seen in tests (sourceCodeLocation instanceof SourceCodeLocation)
1889         https://bugs.webkit.org/show_bug.cgi?id=159368
1890
1891         Reviewed by Timothy Hatcher.
1892
1893         * UserInterface/Test.html:
1894         SourceCodeLocation was already included earlier. This redefines it and
1895         thereby breaks some things.
1896
1897 2016-07-02  Joseph Pecoraro  <pecoraro@apple.com>
1898
1899         inspector/debugger/command-line-api-exception.html flakily times out on mac
1900         https://bugs.webkit.org/show_bug.cgi?id=152029
1901         <rdar://problem/23813812>
1902
1903         Reviewed by Timothy Hatcher.
1904
1905         * UserInterface/Base/Object.js:
1906         (WebInspector.Object.addEventListener):
1907         Return the listener, this makes it cleaner to write tests.
1908
1909 2016-07-01  Joseph Pecoraro  <pecoraro@apple.com>
1910
1911         Web Inspector: Make enabling protocol logging in inspector tests easy to remember
1912         https://bugs.webkit.org/show_bug.cgi?id=159323
1913
1914         Reviewed by Brian Burg.
1915
1916         Now you just need to type InspectorTest.debug() or
1917         ProtocolTest.debug() and it will include stderr logging.
1918
1919         * UserInterface/Test/FrontendTestHarness.js:
1920         (FrontendTestHarness.prototype.debug):
1921         * UserInterface/Test/ProtocolTestHarness.js:
1922         (ProtocolTestHarness.prototype.debug):
1923         (ProtocolTestHarness):
1924         * UserInterface/Test/TestHarness.js:
1925         (TestHarness.prototype.debug):
1926
1927 2016-06-30  Matt Baker  <mattbaker@apple.com>
1928
1929         Unreviewed build fix.
1930
1931         * Localizations/en.lproj/localizedStrings.js:
1932         Add "Area" localized string.
1933
1934 2016-06-30  Joseph Pecoraro  <pecoraro@apple.com>
1935
1936         Web Inspector: Wrong function name next to scope
1937         https://bugs.webkit.org/show_bug.cgi?id=158210
1938         <rdar://problem/26543093>
1939
1940         Reviewed by Timothy Hatcher.
1941
1942         * UserInterface/Controllers/DebuggerManager.js:
1943         (WebInspector.DebuggerManager.prototype._scopeChainNodeFromPayload):
1944         Include new payload data in the construction call.
1945         All the new data is optional, so we gracefully handle
1946         legacy backends.
1947
1948         * UserInterface/Models/ScopeChainNode.js:
1949         (WebInspector.ScopeChainNode):
1950         (WebInspector.ScopeChainNode.prototype.get type):
1951         (WebInspector.ScopeChainNode.prototype.get objects):
1952         (WebInspector.ScopeChainNode.prototype.get name):
1953         (WebInspector.ScopeChainNode.prototype.get location):
1954         (WebInspector.ScopeChainNode.prototype.get hash):
1955         Hash is a rough (name:sourceId:line:column) string for quick comparisons.
1956
1957         (WebInspector.ScopeChainNode.prototype.makeLocalScope):
1958         Make this an action you take on a scope, to avoid having to
1959         do it at construction time, or making it a generic setting.
1960
1961         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
1962         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
1963         This was wrong before. Move the work to CallFrame
1964         and change it to be correct.
1965
1966         * UserInterface/CallFrame.js:
1967         (WebInspector.CallFrame.prototype.mergedScopeChain):
1968
1969         This transforms the scope chain for a call frame from:
1970         
1971              scope1  scope2  scope3  scope4  scope5  scope6  scope7
1972               foo     foo     foo     bar     bar      -       -
1973              Block  Closure Closure Closure Closure   GLE     GBL
1974
1975         To:
1976              scope1  scope2&3   scope4&5  scope6  scope7
1977               foo      foo*       bar*      -       -
1978              Block    Local     Closure    GLE     GBL
1979
1980         Doing a few things:
1981
1982             - Merge the first two Closure scopes sharing a location.
1983               These are the "var" and "let" Closure scopes in a function,
1984               and it is better to present these together in the UI.
1985
1986             - Mark the first Closure scope within a function (*). When
1987               this is displayed in the UI, we can provide the name of
1988               the function: "Closure Scope (name)", and we even have
1989               location information that we can use to display a goto
1990               arrow if needed.
1991
1992             - Make the first Closure scope the Local scope if it
1993               matches the Call Frame's function name. This lets us
1994               display the section as "Local Variables".
1995
1996 2016-06-30  Matt Baker  <mattbaker@apple.com>
1997
1998         Web Inspector: add pixel area column to layout timeline view
1999         https://bugs.webkit.org/show_bug.cgi?id=148677
2000         <rdar://problem/22518762>
2001
2002         Reviewed by Timothy Hatcher.
2003
2004         The view can simply add the column. LayoutTimelineDataGridNode
2005         already includes area data and cell formatting.
2006
2007         * UserInterface/Views/LayoutTimelineView.js:
2008         (WebInspector.LayoutTimelineView):
2009
2010 2016-06-30  Brian Burg  <bburg@apple.com>
2011
2012         Web Inspector: the last normal tab cannot be closed with "Close Tab" context menu item
2013         https://bugs.webkit.org/show_bug.cgi?id=159317
2014         <rdar://problem/27042491>
2015
2016         Reviewed by Timothy Hatcher.
2017
2018         * UserInterface/Views/TabBarItem.js:
2019         (WebInspector.TabBarItem.prototype._handleContextMenuEvent):
2020         (WebInspector.TabBarItem): fix the expression that controls whether the item is disabled.
2021
2022 2016-06-30  Nikita Vasilyev  <nvasilyev@apple.com>
2023
2024         Web Inspector: Add "spring" to transition-timing-function value autocompletion
2025         https://bugs.webkit.org/show_bug.cgi?id=159313
2026         <rdar://problem/27114269>
2027
2028         Reviewed by Timothy Hatcher.
2029
2030         * UserInterface/Models/CSSKeywordCompletions.js:
2031
2032 2016-06-30  Commit Queue  <commit-queue@webkit.org>
2033
2034         Unreviewed, rolling out r202659.
2035         https://bugs.webkit.org/show_bug.cgi?id=159305
2036
2037         The test for this change times out on mac-wk2 debug and caused
2038         an existing test to crash. (Requested by ryanhaddad on
2039         #webkit).
2040
2041         Reverted changeset:
2042
2043         "Web Inspector: Wrong function name next to scope"
2044         https://bugs.webkit.org/show_bug.cgi?id=158210
2045         http://trac.webkit.org/changeset/202659
2046
2047 2016-06-29  Joseph Pecoraro  <pecoraro@apple.com>
2048
2049         Web Inspector: Wrong function name next to scope
2050         https://bugs.webkit.org/show_bug.cgi?id=158210
2051         <rdar://problem/26543093>
2052
2053         Reviewed by Brian Burg.
2054
2055         * UserInterface/Controllers/DebuggerManager.js:
2056         (WebInspector.DebuggerManager.prototype._scopeChainNodeFromPayload):
2057         Include new payload data in the construction call.
2058         All the new data is optional, so we gracefully handle
2059         legacy backends.
2060
2061         * UserInterface/Models/ScopeChainNode.js:
2062         (WebInspector.ScopeChainNode):
2063         (WebInspector.ScopeChainNode.prototype.get type):
2064         (WebInspector.ScopeChainNode.prototype.get objects):
2065         (WebInspector.ScopeChainNode.prototype.get name):
2066         (WebInspector.ScopeChainNode.prototype.get location):
2067         (WebInspector.ScopeChainNode.prototype.get hash):
2068         Hash is a rough (name:sourceId:line:column) string for quick comparisons.
2069
2070         (WebInspector.ScopeChainNode.prototype.makeLocalScope):
2071         Make this an action you take on a scope, to avoid having to
2072         do it at construction time, or making it a generic setting.
2073
2074         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
2075         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
2076         This was wrong before. Move the work to CallFrame
2077         and change it to be correct.
2078
2079         * UserInterface/CallFrame.js:
2080         (WebInspector.CallFrame.prototype.mergedScopeChain):
2081
2082         This transforms the scope chain for a call frame from:
2083         
2084              scope1  scope2  scope3  scope4  scope5  scope6  scope7
2085               foo     foo     foo     bar     bar      -       -
2086              Block  Closure Closure Closure Closure   GLE     GBL
2087
2088         To:
2089              scope1  scope2&3   scope4&5  scope6  scope7
2090               foo      foo*       bar*      -       -
2091              Block    Local     Closure    GLE     GBL
2092
2093         Doing a few things:
2094
2095             - Merge the first two Closure scopes sharing a location.
2096               These are the "var" and "let" Closure scopes in a function,
2097               and it is better to present these together in the UI.
2098
2099             - Mark the first Closure scope within a function (*). When
2100               this is displayed in the UI, we can provide the name of
2101               the function: "Closure Scope (name)", and we even have
2102               location information that we can use to display a goto
2103               arrow if needed.
2104
2105             - Make the first Closure scope the Local scope if it
2106               matches the Call Frame's function name. This lets us
2107               display the section as "Local Variables".
2108
2109 2016-06-29  Brian Burg  <bburg@apple.com>
2110
2111         Web Inspector: Uncaught Exception page never shows if exception is thrown while processing a protocol event
2112         https://bugs.webkit.org/show_bug.cgi?id=159182
2113
2114         Reviewed by Joseph Pecoraro.
2115
2116         Since we catch exceptions raised during the handling of protocol responses and events, there
2117         is no way for these exceptions to trigger the global exception handler that shows the Uncaught
2118         Exception Reporter sheet. We should show these in the sheet because it makes them get fixed faster.
2119
2120         Add a new entry point, WebInspector.reportInternalError, that takes an error or string and
2121         a free-form map of strings to strings for storing additional information such as message data.
2122         Pass the error and any other relevant details to this entry point, which decides whether to
2123         show the uncaught exception reporter or quietly log the error to Inspector^2 console.
2124
2125         In future patches, I would like to do the following once the common errors are fixed:
2126          - enable reporting via Uncaught Exception Reporter for all engineering builds
2127          - move internal console.error call sites to use WebInspector.reportInternalError
2128
2129         * UserInterface/Base/Main.js: Add reportInternalError, which redirects to the uncaught
2130         exception reporter sheet or does console.error. It also adds a console.assert that could
2131         cause the debugger to pause if desired.
2132
2133         * UserInterface/Debug/UncaughtExceptionReporter.css:
2134         (.sheet-container): Make the report scrollable now that we could potentially show a lot of text.
2135
2136         * UserInterface/Debug/UncaughtExceptionReporter.js:
2137         (handleError): Also pass along the 'details' poperty.
2138         (formattedEntry): Refactor the code so it additionally prints out the keys and values of
2139         the 'details' property. It does not do any coercions, so callers must convert values to strings.
2140
2141         * UserInterface/Protocol/InspectorBackend.js:
2142         (InspectorBackendClass.prototype._dispatchResponse): Inlined a function.
2143         (InspectorBackendClass.prototype._dispatchResponseToCallback):
2144         (InspectorBackendClass.prototype._dispatchEvent):
2145         Report uncaught exceptions via WebInspector.reportInternalError.
2146
2147         (InspectorBackendClass.prototype._reportProtocolError): Deleted, inlined into the single use site.
2148
2149 2016-06-29  Joseph Pecoraro  <pecoraro@apple.com>
2150
2151         Web Inspector: Show Shadow Root type in DOM Tree
2152         https://bugs.webkit.org/show_bug.cgi?id=159236
2153         <rdar://problem/27068521>
2154
2155         Reviewed by Timothy Hatcher.
2156
2157         * Localizations/en.lproj/localizedStrings.js:
2158         "Shadow Content (type)" string.
2159
2160         * UserInterface/Models/DOMNode.js:
2161         (WebInspector.DOMNode):
2162         (WebInspector.DOMNode.prototype.shadowRoots):
2163         (WebInspector.DOMNode.prototype.shadowRootType):
2164         Initialize state and add accessors.
2165
2166         * UserInterface/Views/DOMTreeElement.js:
2167         (WebInspector.DOMTreeElement.shadowRootTypeDisplayName):
2168         (WebInspector.DOMTreeElement.prototype._nodeTitleInfo):
2169         Better string when an element is a Shadow Root.
2170
2171         * UserInterface/Views/DOMTreeElementPathComponent.js:
2172         (WebInspector.DOMTreeElementPathComponent):
2173         Better to check the Shadow Root type.
2174
2175         * UserInterface/Views/DOMTreeOutline.css:
2176         (.tree-outline.dom .html-fragment.shadow):
2177         Opacity looks poor when there is a selection. Switch to gray.
2178
2179 2016-06-28  Nikita Vasilyev  <nvasilyev@apple.com>
2180
2181         REGRESSION (r188730): Web Inspector: Warning icons incorrectly positioned in CSS Rules sidebar
2182         https://bugs.webkit.org/show_bug.cgi?id=157869
2183         <rdar://problem/26356520>
2184
2185         Reviewed by Timothy Hatcher.
2186
2187         Before r188730, CSS text always had a line break as a prefix. r188730 started trimming text.
2188         This patch keeps trimming unnecessary whitespace but brings back required line break prefix.
2189
2190         * UserInterface/Models/CSSStyleDeclaration.js:
2191         (WebInspector.CSSStyleDeclaration.prototype.set text):
2192         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
2193         Make PrefixWhitespace and SuffixWhitespace public.
2194
2195         (WebInspector.CSSStyleDeclarationTextEditor.prototype._formattedContent):
2196         (WebInspector.CSSStyleDeclarationTextEditor.prototype._updateTextMarkers.update):
2197         (WebInspector.CSSStyleDeclarationTextEditor.prototype._updateTextMarkers):
2198         Remove an if conditional as it's always true.
2199
2200 2016-06-28  Brian Burg  <bburg@apple.com>
2201
2202         Web Inspector: QuickConsole should update its selection when RuntimeManager.defaultExecutionContextIdentifier changes
2203         https://bugs.webkit.org/show_bug.cgi?id=159183
2204
2205         Reviewed by Timothy Hatcher.
2206
2207         Currently, the UI listens for state changes in the Frame tree to decide when to reset
2208         the selected execution context back to its default value. This is no good, because this
2209         should happen even if we have no UI (i.e., testing models only). The UI should simply
2210         display changes to the model rather than driving them based on other model changes.
2211
2212         Move the logic to reset the execution context into RuntimeManager. When the selected
2213         context changes, an event is fired which causes the QuickConsole to rebuild its path components.
2214
2215         * UserInterface/Controllers/RuntimeManager.js:
2216         (WebInspector.RuntimeManager):
2217         (WebInspector.RuntimeManager.prototype.set defaultExecutionContextIdentifier):
2218         Fire an event when the execution context actually changes.
2219
2220         (WebInspector.RuntimeManager.prototype._frameExecutionContextsCleared):
2221         Added. If the selected context was cleared, reset back to default.
2222
2223         * UserInterface/Models/Frame.js:
2224         (WebInspector.Frame.prototype.clearExecutionContexts):
2225         Include the contexts that were cleared so clients can match against them.
2226
2227         * UserInterface/Views/QuickConsole.js:
2228         (WebInspector.QuickConsole):
2229         Use the proper constant name. Both the old and new names evaluated to `undefined`.
2230         No need to keep track of the selected path component, it will always match the
2231         defaultExecutionContextIdentifier in RuntimeManager.
2232
2233         (WebInspector.QuickConsole.prototype.get selectedExecutionContextIdentifier):
2234         (WebInspector.QuickConsole.prototype.set selectedExecutionContextIdentifier):
2235         Forward to RuntimeManager. This name is less awkward for the UI code that manages selections.
2236
2237         (WebInspector.QuickConsole.prototype._executionContextPathComponentsToDisplay):
2238         Special-case for the main frame execution context.
2239
2240         (WebInspector.QuickConsole.prototype._framePageExecutionContextsChanged):
2241         Remove indirection.
2242
2243         (WebInspector.QuickConsole.prototype._frameExecutionContextsCleared):
2244         Fix the guard to handle undefined execution contexts in the case where it represents the main frame (undefined).
2245
2246         (WebInspector.QuickConsole.prototype._defaultExecutionContextChanged):
2247         Rebuild when the model changes.
2248
2249         (WebInspector.QuickConsole.prototype._pathComponentSelected): Simplify.
2250         (WebInspector.QuickConsole.prototype.get executionContextIdentifier):
2251         (WebInspector.QuickConsole.prototype._removeExecutionContextPathComponentForFrame):
2252         Move the fallback selection behavior into RuntimeManager.
2253
2254         (WebInspector.QuickConsole.prototype._updateExecutionContextPathComponentForFrame): Deleted.
2255         This has been dead code ever since we removed iOS 6 legacy support.
2256
2257 2016-06-27  Joseph Pecoraro  <pecoraro@apple.com>
2258
2259         Web Inspector: When modifying sessionStorage, localStorage gets updated
2260         https://bugs.webkit.org/show_bug.cgi?id=159181
2261         <rdar://problem/27043447>
2262
2263         Reviewed by Timothy Hatcher.
2264
2265         * UserInterface/Test/Test.js:
2266         (WebInspector.loaded):
2267         Add registration for StorageManager and StorageObserver.
2268
2269 2016-06-27  Brian Burg  <bburg@apple.com>
2270
2271         Web Inspector: RuntimeManager should not use view object WebInspector.quickConsole
2272         https://bugs.webkit.org/show_bug.cgi?id=128092
2273         <rdar://problem/15966526>
2274
2275         Reviewed by Timothy Hatcher.
2276
2277         This is a layering violation which makes it harder to use RuntimeManager.evaluateInInspectedWindow
2278         from a testing context where the QuickConsole view does not exist.
2279
2280         Store the selected execution context identifier on RuntimeManager and use it
2281         when doing subsequent evaluations that act on the currently selected frame.
2282
2283         * UserInterface/Controllers/RuntimeManager.js:
2284         (WebInspector.RuntimeManager.prototype.evaluateInInspectedWindow):
2285         (WebInspector.RuntimeManager.prototype.saveResult):
2286         Use local state.
2287
2288         (WebInspector.RuntimeManager.prototype.get defaultExecutionContextIdentifier):
2289         (WebInspector.RuntimeManager.prototype.set defaultExecutionContextIdentifier):
2290         Added.
2291
2292         (WebInspector.RuntimeManager):
2293         * UserInterface/Models/ExecutionContext.js:
2294         (WebInspector.ExecutionContext):
2295         Move the symbolic name for the top level execution context to RuntimeManager.
2296
2297         * UserInterface/Test/Test.js:
2298         (WebInspector.loaded): No need to stub out WebInspector.QuickConsole any more.
2299
2300         * UserInterface/Views/QuickConsole.js:
2301         (WebInspector.QuickConsole.prototype._framePageExecutionContextsChanged):
2302         (WebInspector.QuickConsole.prototype._removeExecutionContextPathComponentForFrame):
2303         (WebInspector.QuickConsole.prototype._updateExecutionContextPathComponentForFrame):
2304         (WebInspector.QuickConsole.prototype._pathComponentSelected):
2305         For now, set RuntimeManager's selected execution context whenever we set the
2306         selected path component. In a future patch, we should invert the dependency and have
2307         the selected component change whenever RuntimeManager.defaultExecutionContext changes.
2308
2309 2016-06-23  Joseph Pecoraro  <pecoraro@apple.com>
2310
2311         Web Inspector: first heap snapshot taken when a page is reloaded happens before the reload navigation
2312         https://bugs.webkit.org/show_bug.cgi?id=158995
2313         <rdar://problem/26923778>
2314
2315         Reviewed by Brian Burg.
2316
2317         Let instruments decide to do work or not based on programmatic
2318         (backend initiated) starts and stop.
2319
2320         Programmatic start can happen due to Auto Capture or console.profile.
2321         Programmatic stop can happen due to console.profileEnd.
2322
2323         For example, this allows the frontend to avoid sending agents start/stop
2324         messages when the backend would have already started/stopped the agents.
2325
2326         * UserInterface/Controllers/TimelineManager.js:
2327         (WebInspector.TimelineManager):
2328         (WebInspector.TimelineManager.prototype.startCapturing):
2329         (WebInspector.TimelineManager.prototype.capturingStopped):
2330         (WebInspector.TimelineManager.prototype.autoCaptureStarted):
2331         (WebInspector.TimelineManager.prototype.programmaticCaptureStarted):
2332         Call Recording.start/stop with a programmatic flag so the frontend
2333         instruments can perform a more informed start/stop.
2334
2335         * UserInterface/Models/TimelineRecording.js:
2336         (WebInspector.TimelineRecording.prototype.start):
2337         (WebInspector.TimelineRecording.prototype.stop):
2338         Let the instruments decide to do work based on the start/stop
2339         being initiated by the backend or not.
2340
2341         * UserInterface/Models/HeapAllocationsInstrument.js:
2342         (WebInspector.HeapAllocationsInstrument.prototype.startInstrumentation):
2343         (WebInspector.HeapAllocationsInstrument.prototype.stopInstrumentation):
2344         * UserInterface/Models/Instrument.js:
2345         (WebInspector.Instrument.startLegacyTimelineAgent):
2346         (WebInspector.Instrument.prototype.startInstrumentation):
2347         (WebInspector.Instrument.prototype.stopInstrumentation):
2348         (WebInspector.Instrument):
2349         * UserInterface/Models/MemoryInstrument.js:
2350         (WebInspector.MemoryInstrument.prototype.startInstrumentation):
2351         (WebInspector.MemoryInstrument.prototype.stopInstrumentation):
2352         (WebInspector.MemoryInstrument):
2353         * UserInterface/Models/NetworkInstrument.js:
2354         * UserInterface/Models/ScriptInstrument.js:
2355         (WebInspector.ScriptInstrument.prototype.startInstrumentation):
2356         (WebInspector.ScriptInstrument.prototype.stopInstrumentation):
2357         (WebInspector.ScriptInstrument):
2358         Avoid sending start/stop tracking messages when programmatic.
2359         This still allows the instruments to do their own frontend tracking,
2360         such as the Heap agent triggering periodic snapshots.
2361
2362 2016-06-23  Joseph Pecoraro  <pecoraro@apple.com>
2363
2364         Web Inspector: Snapshots should be cleared at some point
2365         https://bugs.webkit.org/show_bug.cgi?id=157907
2366         <rdar://problem/26373610>
2367
2368         Reviewed by Timothy Hatcher.
2369
2370         Invalidate HeapSnapshotProxy objects when the page navigates.
2371         This allows us to clear our frontend data for the snapshots.
2372         When a snapshot is invalidated, it is disabled in the UI.
2373         This means you cannot select the snapshot or see content
2374         views for the snapshot. If you are in a snapshot when it is
2375         invalidated, you are taken out to the snapshot list.
2376
2377         * UserInterface/Main.html:
2378         New files.
2379
2380         * UserInterface/Proxies/HeapSnapshotProxy.js:
2381         (WebInspector.HeapSnapshotProxy):
2382         (WebInspector.HeapSnapshotProxy.invalidateSnapshotProxies):
2383         (WebInspector.HeapSnapshotProxy.prototype.get invalid):
2384         (WebInspector.HeapSnapshotProxy.prototype._invalidate):
2385         Keep track of valid snapshots, and provide a static method to invalidate them.
2386
2387         (WebInspector.HeapSnapshotProxy.prototype.updateForCollectionEvent):
2388         (WebInspector.HeapSnapshotProxy.prototype.allocationBucketCounts):
2389         (WebInspector.HeapSnapshotProxy.prototype.instancesWithClassName):
2390         (WebInspector.HeapSnapshotProxy.prototype.update):
2391         (WebInspector.HeapSnapshotProxy.prototype.nodeWithIdentifier):
2392         UI should only act on valid snapshots.
2393
2394         * UserInterface/Proxies/HeapSnapshotDiffProxy.js:
2395         (WebInspector.HeapSnapshotDiffProxy.prototype.get invalid):
2396         (WebInspector.HeapSnapshotDiffProxy.prototype.updateForCollectionEvent):
2397         (WebInspector.HeapSnapshotDiffProxy.prototype.allocationBucketCounts):
2398         (WebInspector.HeapSnapshotDiffProxy.prototype.instancesWithClassName):
2399         (WebInspector.HeapSnapshotDiffProxy.prototype.update):
2400         (WebInspector.HeapSnapshotDiffProxy.prototype.nodeWithIdentifier):
2401         UI should only act on valid snapshots.
2402
2403         * UserInterface/Proxies/HeapSnapshotWorkerProxy.js:
2404         (WebInspector.HeapSnapshotWorkerProxy.prototype._mainResourceDidChange):
2405         Invalidate and discard snapshots when the main frame navigates.
2406
2407         (WebInspector.HeapSnapshotWorkerProxy.prototype._handleMessage):
2408         (WebInspector.HeapSnapshotWorkerProxy):
2409         * UserInterface/Workers/HeapSnapshot/HeapSnapshotWorker.js:
2410         (HeapSnapshotWorker.prototype.clearSnapshots):
2411         (HeapSnapshotWorker.prototype._handleMessage):
2412         (HeapSnapshotWorker):
2413         A message may come in for a snapshot before it has been cleared.
2414         If that is the case, the object may not exist. Return an error so
2415         that the callback can be deleted on the calling side.
2416
2417         * UserInterface/Views/HeapAllocationsTimelineDataGridNodePathComponent.js:
2418         (WebInspector.HeapAllocationsTimelineDataGridNodePathComponent.prototype.get previousSibling):
2419         (WebInspector.HeapAllocationsTimelineDataGridNodePathComponent.prototype.get nextSibling):
2420         (WebInspector.HeapAllocationsTimelineDataGridNodePathComponent):
2421         Don't show invalid snapshots in page component picker.
2422
2423         * UserInterface/Views/HeapAllocationsTimelineOverviewGraph.css:
2424         (.timeline-overview-graph.heap-allocations > img.snapshot.invalid):
2425         * UserInterface/Views/HeapAllocationsTimelineDataGridNode.js:
2426         (WebInspector.HeapAllocationsTimelineDataGridNode):
2427         (WebInspector.HeapAllocationsTimelineDataGridNode.prototype.createCellContent):
2428         (WebInspector.HeapAllocationsTimelineDataGridNode.prototype.createCells):
2429         (WebInspector.HeapAllocationsTimelineDataGridNode.prototype._heapSnapshotInvalidated):
2430         Give invalid snapshots an invalidated appearance in the snapshot list.
2431
2432         * UserInterface/Views/HeapAllocationsTimelineOverviewGraph.js:
2433         (WebInspector.HeapAllocationsTimelineOverviewGraph.prototype.layout):
2434         * UserInterface/Views/HeapAllocationsTimelineView.css:
2435         (.timeline-view.heap-allocations > .data-grid tr.invalid):
2436         (.timeline-view.heap-allocations > .data-grid:not(:focus, .force-focus) tr.selected.invalid):
2437         Give invalid snapshots an invalidated appearance in the overview graph.
2438
2439         * UserInterface/Views/HeapAllocationsTimelineView.js:
2440         (WebInspector.HeapAllocationsTimelineView):
2441         (WebInspector.HeapAllocationsTimelineView.prototype.get selectionPathComponents):
2442         (WebInspector.HeapAllocationsTimelineView.prototype.closed):
2443         (WebInspector.HeapAllocationsTimelineView.prototype._heapSnapshotCollectionEvent.updateHeapSnapshotForEvent):
2444         (WebInspector.HeapAllocationsTimelineView.prototype._heapSnapshotCollectionEvent):
2445         (WebInspector.HeapAllocationsTimelineView.prototype._heapSnapshotInvalidated):
2446         (WebInspector.HeapAllocationsTimelineView.prototype._updateCompareHeapSnapshotButton):
2447         (WebInspector.HeapAllocationsTimelineView.prototype._dataGridNodeSelected):
2448         Handle interactions when snapshots in the list are invalidated.
2449
2450 2016-06-22  Brian Burg  <bburg@apple.com>
2451
2452         Web Inspector: don't start auto capturing if the Inspector window is not visible
2453         https://bugs.webkit.org/show_bug.cgi?id=159014
2454
2455         Reviewed by Joseph Pecoraro.
2456         <rdar://problem/26931269>
2457
2458         Followup, add a missing super.closed() call mentioned in review comments.
2459
2460         * UserInterface/Views/TimelineTabContentView.js:
2461         (WebInspector.TimelineTabContentView.prototype.closed):
2462
2463 2016-06-22  Brian Burg  <bburg@apple.com>
2464
2465         Web Inspector: don't start auto capturing if the Inspector window is not visible
2466         https://bugs.webkit.org/show_bug.cgi?id=159014
2467         <rdar://problem/26931269>
2468
2469         Reviewed by Joseph Pecoraro.
2470
2471         TimelineTabContentView should not tell the timeline manager to enable
2472         auto-capturing unless the Web Inspector UI is visible. If it is preloaded
2473         but not shown to the user, then auto-capturing may inadvertently disable
2474         the debugger, causing it to miss `debugger` statements and not bring the
2475         inspector to front.
2476
2477         * UserInterface/Controllers/TimelineManager.js:
2478         (WebInspector.TimelineManager.prototype.set autoCaptureOnPageLoad):
2479         Bail out if nothing changed. Coerce to a boolean since the backend requires a boolean.
2480
2481         * UserInterface/Views/TimelineTabContentView.js:
2482         (WebInspector.TimelineTabContentView): Listen for UI visibility changes.
2483         (WebInspector.TimelineTabContentView.prototype.shown):
2484         Enable auto-capturing if the UI is visible.
2485
2486         (WebInspector.TimelineTabContentView.prototype.closed): Added.
2487         Remove listeners on global objects so this tab doesn't leak.
2488
2489         (WebInspector.TimelineTabContentView.prototype._inspectorVisibilityChanged):
2490         Update the auto-capturing setting if the UI became visible or not visible.
2491
2492 2016-06-22  Nikita Vasilyev  <nvasilyev@apple.com>
2493
2494         Web Inspector: Simplify CSS rule for ContentBrowser navigation bar items
2495         https://bugs.webkit.org/show_bug.cgi?id=159000
2496
2497         Reviewed by Timothy Hatcher.
2498
2499         * UserInterface/Views/ContentBrowser.css:
2500         (.content-browser > .navigation-bar > .item):
2501         Both these values result in 28px, but `100%` is simplier.
2502
2503 2016-06-21  Nikita Vasilyev  <nvasilyev@apple.com>
2504
2505         REGRESSION(r201177): Web Inspector: ContentBrowser navigation bar should fit on a single line
2506         https://bugs.webkit.org/show_bug.cgi?id=158700
2507         <rdar://problem/26772058>
2508
2509         Reviewed by Joseph Pecoraro.
2510
2511         * UserInterface/Views/ContentBrowser.css:
2512         (.content-browser > .navigation-bar > .item):
2513         Set the height to 28px, as it was before r201177.
2514         Make it one pixel shorter than the navigation bar for better vertical alignment.
2515
2516 2016-06-20  Joseph Pecoraro  <pecoraro@apple.com>
2517
2518         Web Inspector: UncaughtExceptionReporter should handle null event.error
2519         https://bugs.webkit.org/show_bug.cgi?id=158971
2520
2521         Reviewed by Brian Burg.
2522
2523         * UserInterface/Debug/UncaughtExceptionReporter.js:
2524         Since `typeof null === "object"` handle uncaught exceptions where the
2525         Error object itself is null.
2526
2527 2016-06-20  Joseph Pecoraro  <pecoraro@apple.com>
2528
2529         Web Inspector: Snapshot List should show the total size and the total live size
2530         https://bugs.webkit.org/show_bug.cgi?id=157904
2531         <rdar://problem/26372833>
2532
2533         Reviewed by Brian Burg.
2534
2535         Include the live size of a snapshot in the snapshot list.
2536
2537         * Localizations/en.lproj/localizedStrings.js:
2538         New "Live Size" string.
2539
2540         * UserInterface/Workers/HeapSnapshot/HeapSnapshot.js:
2541         (HeapSnapshot):
2542         (HeapSnapshot.updateCategoriesAndMetadata):
2543         (HeapSnapshot.prototype.update):
2544         (HeapSnapshot.prototype.serialize):
2545         (HeapSnapshotDiff):
2546         (HeapSnapshotDiff.prototype.update):
2547         (HeapSnapshot.buildCategories): Deleted.
2548         (HeapSnapshot.prototype.updateCategories): Deleted.
2549         (HeapSnapshotDiff.prototype.updateCategories): Deleted.
2550         * UserInterface/Proxies/HeapSnapshotDiffProxy.js:
2551         (WebInspector.HeapSnapshotDiffProxy.prototype.updateForCollectionEvent):
2552         (WebInspector.HeapSnapshotDiffProxy.prototype.update):
2553         (WebInspector.HeapSnapshotDiffProxy.prototype.updateCategories): Deleted.
2554         * UserInterface/Proxies/HeapSnapshotProxy.js:
2555         (WebInspector.HeapSnapshotProxy):
2556         (WebInspector.HeapSnapshotProxy.deserialize):
2557         (WebInspector.HeapSnapshotProxy.prototype.get liveSize):
2558         (WebInspector.HeapSnapshotProxy.prototype.updateForCollectionEvent):
2559         (WebInspector.HeapSnapshotProxy.prototype.update):
2560         (WebInspector.HeapSnapshotProxy.prototype.updateCategories): Deleted.
2561         Rename "updateCategories" to "update" and update both categories
2562         and metadata, like the liveSize.
2563
2564         * UserInterface/Views/HeapAllocationsTimelineDataGridNode.js:
2565         (WebInspector.HeapAllocationsTimelineDataGridNode):
2566         (WebInspector.HeapAllocationsTimelineDataGridNode.prototype.createCellContent):
2567         (WebInspector.HeapAllocationsTimelineDataGridNode.prototype._heapSnapshotCollectedNodes):
2568         Update live size after collection.
2569
2570         * UserInterface/Views/HeapAllocationsTimelineView.js:
2571         (WebInspector.HeapAllocationsTimelineView):
2572         Include a live size column in the DataGrid.
2573         (WebInspector.HeapAllocationsTimelineView.prototype.closed):
2574         Cleanup listeners appropriately.
2575
2576 2016-06-20  Joseph Pecoraro  <pecoraro@apple.com>
2577
2578         Web Inspector: console.profile should use the new Sampling Profiler
2579         https://bugs.webkit.org/show_bug.cgi?id=153499
2580         <rdar://problem/24352431>
2581
2582         Reviewed by Timothy Hatcher.
2583
2584         * UserInterface/Controllers/TimelineManager.js:
2585         (WebInspector.TimelineManager.prototype.programmaticCaptureStarted):
2586         (WebInspector.TimelineManager.prototype.programmaticCaptureStopped):
2587         (WebInspector.TimelineManager.prototype.scriptProfilerProgrammaticCaptureStarted):
2588         (WebInspector.TimelineManager.prototype.scriptProfilerProgrammaticCaptureStopped):
2589         For programmatic captures, automatically show the Script Timeline, since
2590         that is guarenteed to have been started by the backend. Start capturing
2591         without creating a new recording.
2592
2593         * UserInterface/Models/TimelineRecording.js:
2594         (WebInspector.TimelineRecording.prototype.stop):
2595         (WebInspector.TimelineRecording.prototype.addScriptInstrumentForProgrammaticCapture):
2596         When stopping for programmatic capture we don't need to disable
2597         instruments, the backend would have already done this.
2598
2599         * UserInterface/Protocol/ScriptProfilerObserver.js:
2600         (WebInspector.ScriptProfilerObserver.prototype.programmaticCaptureStarted):
2601         (WebInspector.ScriptProfilerObserver.prototype.programmaticCaptureStopped):
2602         (WebInspector.ScriptProfilerObserver):
2603         * UserInterface/Protocol/TimelineObserver.js:
2604         (WebInspector.TimelineObserver.prototype.programmaticCaptureStarted):
2605         (WebInspector.TimelineObserver.prototype.programmaticCaptureStopped):
2606         (WebInspector.TimelineObserver):
2607         Pass through Web and JSContext programmatic capture events.
2608
2609 2016-06-19  Nikita Vasilyev  <nvasilyev@apple.com>
2610
2611         Web Inspector: Remove Sidebar z-index:0 workaround for scrollbars and position:sticky section headers
2612         https://bugs.webkit.org/show_bug.cgi?id=158882
2613
2614         Reviewed by Darin Adler.
2615
2616         The z-index:0 workaround is no longer needed as it doesn't change anything.
2617
2618         * UserInterface/Views/Sidebar.css:
2619         (.sidebar > .panel): Deleted.
2620
2621 2016-06-17  Commit Queue  <commit-queue@webkit.org>
2622
2623         Unreviewed, rolling out r202152.
2624         https://bugs.webkit.org/show_bug.cgi?id=158897
2625
2626         The new test is very unstable, timing out frequently
2627         (Requested by ap on #webkit).
2628
2629         Reverted changeset:
2630
2631         "Web Inspector: console.profile should use the new Sampling
2632         Profiler"
2633         https://bugs.webkit.org/show_bug.cgi?id=153499
2634         http://trac.webkit.org/changeset/202152
2635
2636 2016-06-16  Joseph Pecoraro  <pecoraro@apple.com>
2637
2638         Web Inspector: console.profile should use the new Sampling Profiler
2639         https://bugs.webkit.org/show_bug.cgi?id=153499
2640         <rdar://problem/24352431>
2641
2642         Reviewed by Timothy Hatcher.
2643
2644         * UserInterface/Controllers/TimelineManager.js:
2645         (WebInspector.TimelineManager.prototype.programmaticCaptureStarted):
2646         (WebInspector.TimelineManager.prototype.programmaticCaptureStopped):
2647         (WebInspector.TimelineManager.prototype.scriptProfilerProgrammaticCaptureStarted):
2648         (WebInspector.TimelineManager.prototype.scriptProfilerProgrammaticCaptureStopped):
2649         For programmatic captures, automatically show the Script Timeline, since
2650         that is guarenteed to have been started by the backend. Start capturing
2651         without creating a new recording.
2652
2653         * UserInterface/Models/TimelineRecording.js:
2654         (WebInspector.TimelineRecording.prototype.stop):
2655         (WebInspector.TimelineRecording.prototype.addScriptInstrumentForProgrammaticCapture):
2656         When stopping for programmatic capture we don't need to disable
2657         instruments, the backend would have already done this.
2658
2659         * UserInterface/Protocol/ScriptProfilerObserver.js:
2660         (WebInspector.ScriptProfilerObserver.prototype.programmaticCaptureStarted):
2661         (WebInspector.ScriptProfilerObserver.prototype.programmaticCaptureStopped):
2662         (WebInspector.ScriptProfilerObserver):
2663         * UserInterface/Protocol/TimelineObserver.js:
2664         (WebInspector.TimelineObserver.prototype.programmaticCaptureStarted):
2665         (WebInspector.TimelineObserver.prototype.programmaticCaptureStopped):
2666         (WebInspector.TimelineObserver):
2667         Pass through Web and JSContext programmatic capture events.
2668
2669 2016-06-16  Joseph Pecoraro  <pecoraro@apple.com>
2670
2671         REGRESSION (r201538): Web Inspector: Border over Allocations Views is too thick
2672         https://bugs.webkit.org/show_bug.cgi?id=158846
2673
2674         Reviewed by Timothy Hatcher.
2675
2676         * UserInterface/Views/HeapAllocationsTimelineView.css:
2677         (.timeline-view.heap-allocations > .content-view-container > .content-view): Deleted.
2678
2679 2016-06-16  Matt Baker  <mattbaker@apple.com>
2680
2681         Unreviewed build fix.
2682
2683         * UserInterface/Views/DataGrid.js:
2684         (WebInspector.DataGrid.prototype.createSettings):
2685         "showColumn" -> "setColumnVisible".
2686
2687 2016-06-16  Matt Baker  <mattbaker@apple.com>
2688
2689         Web Inspector: DataGrid should manage its own settings
2690         https://bugs.webkit.org/show_bug.cgi?id=158675
2691         <rdar://problem/26761338>
2692
2693         Reviewed by Timothy Hatcher.
2694
2695         Move grid sorting settings (sort order, column identifier) into DataGrid,
2696         removing duplicated code from various views. A new grid method, "createSettings",
2697         takes an identifier which is used as a prefix for naming the grid's settings.
2698
2699         So that the new behavior is easy to use and hard to misuse, default values
2700         for each setting are set to the current value of the associated property.
2701         The result is that:
2702
2703             grid.sortColumnIdentifier = "columnA";
2704             grid.createSettings("myGrid");
2705
2706         will use "columnA" as the default value the first time the setting is created.
2707
2708         * UserInterface/Views/ApplicationCacheFrameContentView.js:
2709         (WebInspector.ApplicationCacheFrameContentView.prototype._createDataGrid):
2710         * UserInterface/Views/CookieStorageContentView.js:
2711         (WebInspector.CookieStorageContentView.prototype._rebuildTable):
2712         * UserInterface/Views/DOMStorageContentView.js:
2713         (WebInspector.DOMStorageContentView):
2714         * UserInterface/Views/DataGrid.js:
2715         (WebInspector.DataGrid):
2716         (WebInspector.DataGrid.prototype.createSettings):
2717         (WebInspector.DataGrid.prototype.get identifier): Deleted.
2718         (WebInspector.DataGrid.prototype.set identifier): Deleted.
2719         (WebInspector.DataGrid.prototype.set sortOrderSetting): Deleted.
2720         (WebInspector.DataGrid.prototype.set sortColumnIdentifierSetting): Deleted.
2721         * UserInterface/Views/HeapAllocationsTimelineView.js:
2722         (WebInspector.HeapAllocationsTimelineView):
2723         * UserInterface/Views/HeapSnapshotContentView.js:
2724         (WebInspector.HeapSnapshotContentView):
2725         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
2726         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._buildDataGridSection):
2727         * UserInterface/Views/LayoutTimelineView.js:
2728         (WebInspector.LayoutTimelineView):
2729         * UserInterface/Views/NetworkGridContentView.js:
2730         (WebInspector.NetworkGridContentView):
2731         * UserInterface/Views/NetworkTimelineView.js:
2732         (WebInspector.NetworkTimelineView):
2733         * UserInterface/Views/ProfileView.js:
2734         (WebInspector.ProfileView):
2735         * UserInterface/Views/RenderingFrameTimelineView.js:
2736         (WebInspector.RenderingFrameTimelineView):
2737         * UserInterface/Views/ScriptDetailsTimelineView.js:
2738         (WebInspector.ScriptDetailsTimelineView):
2739
2740 2016-06-15  Joseph Pecoraro  <pecoraro@apple.com>
2741
2742         Uncaught Exception: TypeError: undefined is not an object (evaluating 'imageElement.classList')
2743         https://bugs.webkit.org/show_bug.cgi?id=158808
2744         <rdar://problem/26821034>
2745
2746         Reviewed by Brian Burg.
2747
2748         * UserInterface/Views/HeapAllocationsTimelineOverviewGraph.js:
2749         (WebInspector.HeapAllocationsTimelineOverviewGraph.prototype._updateSnapshotMarkers):
2750         If the record is out of the layout bounds of the overview graph, the overview graph
2751         may not have created an image element yet, so bail. Later, when the image element
2752         is created, it would get the appropriate style if the record is selected.
2753
2754 2016-06-14  Matt Baker  <mattbaker@apple.com>
2755
2756         Web Inspector: Rename DataGrid.showColumn to setColumnVisible
2757         https://bugs.webkit.org/show_bug.cgi?id=158764
2758         <rdar://problem/26801448>
2759
2760         Reviewed by Joseph Pecoraro.
2761
2762         * UserInterface/Views/DataGrid.js:
2763         (WebInspector.DataGrid):
2764         Drive-by update to initialize "this._columnChooserEnabled".
2765
2766         (WebInspector.DataGrid.prototype.set identifier):
2767         (WebInspector.DataGrid.prototype.insertColumn):
2768         (WebInspector.DataGrid.prototype._collapseColumnGroupWithCell):
2769         Use new method name.
2770
2771         (WebInspector.DataGrid.prototype._contextMenuInHeader):
2772         Drive-by style update.
2773
2774 2016-06-14  Matt Baker  <mattbaker@apple.com>
2775
2776         Web Inspector: Storage tab should allow hiding columns in the cookies grid
2777         https://bugs.webkit.org/show_bug.cgi?id=158767
2778         <rdar://problem/26803568>
2779
2780         Reviewed by Joseph Pecoraro.
2781
2782         * UserInterface/Views/CookieStorageContentView.js:
2783         (WebInspector.CookieStorageContentView.prototype._rebuildTable):
2784         Enable column chooser, exclude Name and Value columns.
2785
2786 2016-06-14  Nikita Vasilyev  <nvasilyev@apple.com>
2787
2788         Web Inspector: Visual Sidebar: Remove "Text -> Content" subsection
2789         https://bugs.webkit.org/show_bug.cgi?id=158758
2790         <rdar://problem/26799628>
2791
2792         Reviewed by Timothy Hatcher.
2793
2794         "content" CSS property only works with pseudo elements ::before and ::after.
2795         It doesn't do anything for regular (non pseudo) elements. Remove it to
2796         reduce UI clutter.
2797
2798         * UserInterface/Views/VisualStyleDetailsPanel.js:
2799         (WebInspector.VisualStyleDetailsPanel.prototype.initialLayout):
2800         (WebInspector.VisualStyleDetailsPanel.prototype._populateContentSection): Deleted.
2801         * UserInterface/Views/VisualStylePropertyEditor.css:
2802         (.visual-style-property-container > *:first-child:matches(.visual-style-property-value-container)): Deleted.
2803
2804 2016-06-14  Joseph Pecoraro  <pecoraro@apple.com>
2805
2806         Web Inspector: Rename Timeline.setAutoCaptureInstruments to Timeline.setInstruments
2807         https://bugs.webkit.org/show_bug.cgi?id=158762
2808
2809         Reviewed by Timothy Hatcher.
2810
2811         * UserInterface/Controllers/TimelineManager.js:
2812         (WebInspector.TimelineManager.prototype._updateAutoCaptureInstruments):
2813         (WebInspector.TimelineManager):
2814
2815 2016-06-14  Benjamin Poulain  <bpoulain@apple.com>
2816
2817         Add the unprefixed version of the pseudo element ::placeholder
2818         https://bugs.webkit.org/show_bug.cgi?id=158653
2819
2820         Reviewed by Dean Jackson.
2821
2822         * UserInterface/Views/FilterBar.css:
2823         (.filter-bar > input[type="search"]::placeholder):
2824         (.filter-bar > input[type="search"]::-webkit-input-placeholder): Deleted.
2825         * UserInterface/Views/FindBanner.css:
2826         (.find-banner.console-find-banner > input[type="search"]::placeholder):
2827         (.find-banner.console-find-banner > input[type="search"]::-webkit-input-placeholder): Deleted.
2828         * UserInterface/Views/GoToLineDialog.css:
2829         (.go-to-line-dialog > div > input::placeholder):
2830         (.go-to-line-dialog > div > input::-webkit-input-placeholder): Deleted.
2831         * UserInterface/Views/OpenResourceDialog.css:
2832         (.open-resource-dialog > .field > input::placeholder):
2833         (.open-resource-dialog > .field > input::-webkit-input-placeholder): Deleted.
2834         * UserInterface/Views/SearchBar.css:
2835         (.search-bar > input[type="search"]::placeholder):
2836         (.search-bar > input[type="search"]::-webkit-input-placeholder): Deleted.
2837         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.css:
2838
2839 2016-06-14  Nikita Vasilyev  <nvasilyev@apple.com>
2840
2841         Web Inspector: Introduce --navigation-bar-height CSS variable
2842         https://bugs.webkit.org/show_bug.cgi?id=158752
2843
2844         Reviewed by Timothy Hatcher.
2845
2846         Abstract a commonly repeated height value (29px) into a variable.
2847
2848         * UserInterface/Views/CSSStyleDetailsSidebarPanel.css:
2849         (.sidebar > .panel.details.css-style > .content.has-filter-bar):
2850         * UserInterface/Views/DebuggerSidebarPanel.css:
2851         (.sidebar > .panel.navigation.debugger > :matches(.content, .empty-content-placeholder)):
2852         * UserInterface/Views/FilterBar.css:
2853         (.filter-bar):
2854         * UserInterface/Views/NavigationBar.css:
2855         (.navigation-bar):
2856         * UserInterface/Views/NavigationSidebarPanel.css:
2857         (.sidebar > .panel.navigation > .content):
2858         (.sidebar > .panel.navigation > .overflow-shadow.top):
2859         * UserInterface/Views/NetworkSidebarPanel.css:
2860         (.sidebar > .panel.navigation.network > .title-bar):
2861         * UserInterface/Views/ResourceSidebarPanel.css:
2862         (.sidebar > .panel.navigation.resource > :matches(.content, .empty-content-placeholder)):
2863         * UserInterface/Views/SearchSidebarPanel.css:
2864         (.sidebar > .panel.navigation.search > :matches(.content, .empty-content-placeholder)):
2865         (.sidebar > .panel.navigation.search > .search-bar):
2866         * UserInterface/Views/Sidebar.css:
2867         (.sidebar.has-navigation-bar > .panel):
2868         * UserInterface/Views/StorageSidebarPanel.css:
2869         (.sidebar > .panel.navigation.storage > :matches(.content, .empty-content-placeholder)):
2870         * UserInterface/Views/TimelineRecordingContentView.css:
2871         (.content-view.timeline-recording > .content-browser .recording-progress):
2872         * UserInterface/Views/Variables.css:
2873         (:root):
2874
2875 2016-06-14  Saam Barati  <sbarati@apple.com>
2876
2877         Follow up to: Web Inspector: Call Trees view should have a 'Top Functions'-like mode
2878         https://bugs.webkit.org/show_bug.cgi?id=158555
2879         <rdar://problem/26712544>
2880
2881         Unreviewed follow up patch.
2882
2883         - Move a long if-else sequence to a switch statement.
2884         - Fix a copy-paste typo in a Symbol(.) enum.
2885
2886         * UserInterface/Models/CallingContextTree.js:
2887         (WebInspector.CallingContextTree.prototype.updateTreeWithStackTrace):
2888
2889 2016-06-13  Joseph Pecoraro  <pecoraro@apple.com>
2890
2891         Web Inspector: Show Exception Stack in UncaughtExceptionReporter view
2892         https://bugs.webkit.org/show_bug.cgi?id=158657
2893         <rdar://problem/26754441>
2894
2895         Reviewed by Darin Adler.
2896
2897         * UserInterface/Debug/UncaughtExceptionReporter.css:
2898         (.uncaught-exception-sheet li):
2899         Make newlines significant.
2900
2901         * UserInterface/Debug/UncaughtExceptionReporter.js:
2902         (unblockEventHandlers):
2903         (handleError):
2904         (handleLinkClick):
2905         (formattedEntry):
2906         Format the exception and a possible stack with a bit of sanitizing.
2907
2908 2016-06-13  Matt Baker  <mattbaker@apple.com>
2909
2910         Web Inspector: Filter Records not applying to new records
2911         https://bugs.webkit.org/show_bug.cgi?id=158213
2912         <rdar://problem/26543912>
2913
2914         Reviewed by Timothy Hatcher.
2915
2916         This patch makes the following improvements to timeline grid filtering:
2917
2918             - Records are filtered as they are added to the grid.
2919             - Timeline view no longer triggers a filter refresh while the
2920               current time changes while recording.
2921             - Filters are refreshed whenever the current timeline view changes.
2922
2923         * UserInterface/Views/DataGrid.js:
2924         (WebInspector.DataGrid.prototype.hasFilters):
2925         Helper function to check for custom and text filters.
2926
2927         (WebInspector.DataGrid.prototype._applyFiltersToNodeAndDispatchEvent):
2928         Encapsulate node state change and event dispatch, which was previously
2929         done in multiple places.
2930
2931         (WebInspector.DataGrid.prototype.insertChild):
2932         Filter incoming node if needed.
2933
2934         (WebInspector.DataGrid.prototype._updateFilter.createIteratorForNodesToBeFiltered):
2935         (WebInspector.DataGrid.prototype._updateFilter):
2936         (WebInspector.DataGrid.prototype.yieldableTaskWillProcessItem):
2937         Use new convenience functions.
2938
2939         (WebInspector.DataGrid.prototype.hasCustomFilters): Deleted.
2940         Renamed `hasFilters`.
2941
2942         * UserInterface/Views/TimelineRecordingContentView.js:
2943         (WebInspector.TimelineRecordingContentView.prototype._currentContentViewDidChange):
2944         Refresh grid filters on view change.
2945
2946         * UserInterface/Views/TimelineView.js:
2947         (WebInspector.TimelineView.prototype.set startTime):
2948         (WebInspector.TimelineView.prototype.set endTime):
2949         Schedule filter change notification when selection bounds changes.
2950
2951         (WebInspector.TimelineView.prototype._timesDidChange):
2952         (WebInspector.TimelineView.prototype._scheduleFilterDidChange):
2953         (WebInspector.TimelineView):
2954
2955 2016-06-13  Saam Barati  <sbarati@apple.com>
2956
2957         Web Inspector: Call Trees view should have a 'Top Functions'-like mode
2958         https://bugs.webkit.org/show_bug.cgi?id=158555
2959         <rdar://problem/26712544>
2960
2961         Reviewed by Timothy Hatcher.
2962
2963         This patch adds a Top Functions view that is similar to Instruments'
2964         Top Functions view. I really wanted to add this view because I've
2965         been doing a lot of performance debugging and I've exclusively 
2966         used the Top Functions view and I want the Inspector to also have
2967         this view. I like to think of it as a more sophisticated version of the bottom-up view.
2968         
2969         Top Functions works by treating every frame as a root in the tree.
2970         Top functions view then presents a list of "roots". This is the same
2971         as all other views, which also present a list of roots, but in this case,
2972         every frame is a root. Bottom Up is great for nailing in specific performance
2973         problems in exactly one frame. But Bottom Up doesn't give you good context about where
2974         a specific frame is in the call tree and how frames are related by having
2975         a caller or some path of shared callers. For example, consider this call tree:
2976                  (program)
2977                  /        \
2978                 /          \
2979            (many nodes...)  
2980               / 
2981              /
2982             (parent)
2983             /   \
2984            /     \
2985          (leaf1)  (leaf2)
2986         
2987         Suppose that 'leaf1' is super hot, and 'leaf2' is moderately hot.
2988         If we look at this through Bottom Up view, we will see 'leaf1'
2989         is super hot, but it will take more scrolling to see that 'leaf2'
2990         is moderately hot. Lets say that 'parent' is also moderately hot,
2991         but that the majority of its time isn't self time. With Bottom Up view,
2992         there is no good way to see that 'leaf1' and 'leaf2' are both nodes under 'parent'.
2993         With Top Down, you can find this information, but it requires a ton of drilling down into
2994         the tree (i.e, you must expand past the 'many nodes...' I drew above). It's inconvenient to
2995         use Top Down here for indentation alone. Bottom up will tell you that 'leaf1' is super hot,
2996         and that 'leaf2' and 'parent' are moderately hot, but it doesn't show how they're related
2997         in the original tree. It's important to see that 'parent's total time is very high
2998         because it itself is moderately hot, and it has a child node that is super hot, and
2999         another child that's moderately 'hot'. For the sake of this example, let's pretend
3000         that 85% of the program's time is spent inside 'parent'. Seeing this information through
3001         'Top Functions' is easy because this information filters to the top of the list. Specifically,
3002         when using 'Top Functions' sorted by Total Time. Because every node is a root, there will be
3003         a top-level entry for every frame in the program. Specifically, there will be a top-level node
3004         for 'parent' in my above example. Because I've sorted this view by Total Time, I will see '(program)'
3005         first. That's because 100% of execution time is under the '(program)' frame. Then, I might see
3006         a few other nodes that also run the entire time because '(program)' calls them, and they eventually
3007         call into other things that never leave the stack. These will also have time ranges near 100%.
3008         But, only a few nodes after that, I'll see 'parent' in the list because it accounts for 85% of
3009         execution time. Immediately, I will see that it has some self time, and that it has two child
3010         nodes that have self time. This is really helpful.
3011         
3012         Let's consider another example where it's not easy in Top Down to get the full picture of 'parent':
3013                    (program)
3014                     /  |  \
3015                  (... many nodes...)
3016                   /           \
3017             (many nodes...)   (many nodes...)
3018                  /             \
3019                parent         parent
3020                  |              |
3021                 leaf1          leaf2
3022         
3023         
3024         If we viewed this program in Top Down, we don't get a full picture of 'parent'
3025         because it has its time distributed in two different subsections of the tree.
3026         Specifically, lets say it has 70% of time in the leaf1 path, and 30% of the
3027         time in the leaf2 path. We want a way to see these things together. It's impossible
3028         to do this in Top Down or Bottom Up. But, in Top Functions view, we get the view that
3029         we want to see because we treat 'parent' as a root of the tree. Because we do this,
3030         we will create the following sub tree in the Top Functions view:
3031                 parent
3032                /      \
3033              leaf1   leaf2
3034         This happens naturally because when 'parent' is a root, we add all its children
3035         to its subtree.
3036         
3037         Constructing this tree is really easy. What we do is take any arbitrary stack
3038         trace of length n, and treat is as n separate stack traces. Specifically, we
3039         perform the following operation for any stack trace S.
3040         
3041         S = [A, B, C, D]
3042         (A is the entry frame, and D is the top of the stack).
3043         We will transform this into a list of stack traces S' like so:
3044         S' = [[A, B, C, D], [B, C, D], [C, D], [D]]
3045         
3046         If we then run the normal top down tree algorithm on this set of stack
3047         traces, all nodes get treated as roots, and voila, we get the Top Functions view.
3048
3049         * Localizations/en.lproj/localizedStrings.js:
3050         * UserInterface/Controllers/TimelineManager.js:
3051         * UserInterface/Main.html:
3052         * UserInterface/Models/CallingContextTree.js:
3053         * UserInterface/Models/TimelineRecording.js:
3054         * UserInterface/Views/ScriptProfileTimelineView.js:
3055         * UserInterface/Views/TextToggleButtonNavigationItem.css: Added.
3056         * UserInterface/Views/TextToggleButtonNavigationItem.js: Added.
3057
3058 2016-06-13  Matt Baker  <mattbaker@apple.com>
3059
3060         Web Inspector: Add ability to show/hide DataGird columns
3061         https://bugs.webkit.org/show_bug.cgi?id=158676
3062         <rdar://problem/26761573>
3063
3064         Reviewed by Timothy Hatcher.
3065
3066         Make it possible to show/hide grid columns using the grid header
3067         context menu. This patch enables the new behavior for most of the
3068         timeline grids.
3069
3070         * UserInterface/Views/DataGrid.js:
3071         (WebInspector.DataGrid):
3072         (WebInspector.DataGrid.prototype.get identifier):
3073         (WebInspector.DataGrid.prototype.set identifier):
3074         An identifier for the grid instance, for managing per-grid settings.
3075         Setting the id causes settings to be created, and their values to be
3076         applied to the grid.
3077
3078         (WebInspector.DataGrid.prototype.get columnChooserEnabled):
3079         (WebInspector.DataGrid.prototype.set columnChooserEnabled):
3080         Enable showing/hiding columns via the grid header.
3081
3082         (WebInspector.DataGrid.prototype.insertColumn):
3083         (WebInspector.DataGrid.prototype.showColumn):
3084         Set column visibility and hidden column setting, then perform layout.
3085
3086         (WebInspector.DataGrid.prototype._collapseColumnGroupWithCell):
3087         (WebInspector.DataGrid.prototype._contextMenuInHeader):
3088         Create column chooser menu items if necessary.
3089
3090         (WebInspector.DataGrid.prototype._showColumn): Deleted.
3091         (WebInspector.DataGrid.prototype._hideColumn): Deleted.
3092         Replaced by `showColumn`.
3093
3094         * UserInterface/Views/LayoutTimelineView.js:
3095         (WebInspector.LayoutTimelineView):
3096         Always show "type" and "name" columns.
3097
3098         * UserInterface/Views/NetworkTimelineView.js:
3099         (WebInspector.NetworkTimelineView):
3100         * UserInterface/Views/RenderingFrameTimelineView.js:
3101         (WebInspector.RenderingFrameTimelineView):
3102         * UserInterface/Views/ScriptDetailsTimelineView.js:
3103         (WebInspector.ScriptDetailsTimelineView):
3104         Always show "name" column.
3105
3106         * UserInterface/Views/TimelineDataGrid.js:
3107         (WebInspector.TimelineDataGrid):
3108         Enable column chooser.
3109
3110 2016-06-10  Joseph Pecoraro  <pecoraro@apple.com>
3111
3112         Web Inspector: <template> content should not be hidden as Shadow Content
3113         https://bugs.webkit.org/show_bug.cgi?id=158654
3114
3115         Reviewed by Ryosuke Niwa.
3116
3117         * Localizations/en.lproj/localizedStrings.js:
3118         New "Template Content" string.
3119
3120         * UserInterface/Models/DOMNode.js:
3121         (WebInspector.DOMNode):
3122         Don't treat template content as shadow content.
3123
3124         * UserInterface/Views/DOMTreeElement.js:
3125         (WebInspector.DOMTreeElement.prototype._nodeTitleInfo):
3126         Custom string for template content fragment.
3127
3128 2016-06-10  Matt Baker  <mattbaker@apple.com>
3129
3130         Web Inspector: heap snapshot comparison view shows nothing if later snapshot is chosen first
3131         https://bugs.webkit.org/show_bug.cgi?id=158584
3132         <rdar://problem/26727849>
3133
3134         Reviewed by Timothy Hatcher.
3135
3136         ALways compare the the later snapshot to the earlier snapshot,
3137         regardless of selection order.
3138
3139         * UserInterface/Views/HeapAllocationsTimelineView.js:
3140         (WebInspector.HeapAllocationsTimelineView):
3141         (WebInspector.HeapAllocationsTimelineView.prototype._dataGridNodeSelected):
3142         Swap shapshots if the first has a greater identifier than the second.
3143         Drive-by cleanup: null out `_baselineDataGridNode` since it isn't used
3144         after the comparison completes.
3145
3146 2016-06-10  Matt Baker  <mattbaker@apple.com>
3147
3148         Web Inspector: rendering frames timeline "60fps" horizontal guide is mispositioned after switching timeline modes
3149         https://bugs.webkit.org/show_bug.cgi?id=158587
3150         <rdar://problem/26728174>
3151
3152         Reviewed by Timothy Hatcher.
3153
3154         When the view mode changes we iterate over all overview graphs, updating
3155         their visibility as needed. Graphs being shown perform layout, even though
3156         the overview's state is in transition: its offset height may still change.
3157
3158         A simple fix is to use TimelineOverviewGraph.height instead of the graph
3159         element's offset height when performing layout.
3160
3161         * UserInterface/Views/RenderingFrameTimelineOverviewGraph.js:
3162         (WebInspector.RenderingFrameTimelineOverviewGraph.prototype.layout):
3163
3164 2016-06-10  Matt Baker  <mattbaker@apple.com>
3165
3166         REGRESSION (r201538): Web Inspector: 1px gap above timeline progress view
3167         https://bugs.webkit.org/show_bug.cgi?id=158626
3168
3169         Reviewed by Joseph Pecoraro.
3170
3171         Adjust progress view top position to account for grid border changes.
3172
3173         * UserInterface/Views/TimelineRecordingContentView.css:
3174         (.content-view.timeline-recording > .content-browser .recording-progress):
3175
3176 2016-06-10  Matt Baker  <mattbaker@apple.com>
3177
3178         Web Inspector: REGRESSION (r201538): Web Inspector: Border under JS Call Trees content view is too thick
3179         https://bugs.webkit.org/show_bug.cgi?id=158624
3180         <rdar://problem/26743633>
3181
3182         Reviewed by Joseph Pecoraro.
3183
3184         Remove top border from <th> elements.
3185
3186         * UserInterface/Views/ProfileView.css:
3187         (.profile > .data-grid th): Deleted.
3188
3189 2016-06-09  Joseph Pecoraro  <pecoraro@apple.com>
3190
3191         REGRESSION: Web Inspector: IndexedDB does not show ObjectStore data
3192         https://bugs.webkit.org/show_bug.cgi?id=158592
3193         <rdar://problem/26730696>
3194
3195         Reviewed by Timothy Hatcher.
3196
3197         * UserInterface/Views/DataGrid.js:
3198         (WebInspector.DataGrid.prototype._noteRowRemoved):
3199         (WebInspector.DataGridNode.prototype._detach):
3200         When rows are removed in the non-Virtual DataGrids, we should
3201         actually remove the row.
3202
3203         * UserInterface/Views/IndexedDatabaseObjectStoreContentView.js:
3204         (WebInspector.IndexedDatabaseObjectStoreContentView):
3205         (WebInspector.IndexedDatabaseObjectStoreContentView.prototype._fetchMoreData.processEntries):
3206         (WebInspector.IndexedDatabaseObjectStoreContentView.prototype._fetchMoreData):
3207         Don't use the delete operator. Use a boolean.
3208
3209 2016-06-09  Nikita Vasilyev  <nvasilyev@apple.com>
3210
3211         Web Inspector: Support Command-P for quick open
3212         https://bugs.webkit.org/show_bug.cgi?id=158579
3213         <rdar://problem/26726751>
3214
3215         Reviewed by Timothy Hatcher.
3216
3217         * UserInterface/Base/Main.js:
3218         (WebInspector.contentLoaded):
3219
3220 2016-06-09  Nikita Vasilyev  <nvasilyev@apple.com>
3221
3222         REGRESSION (r194717): Web Inspector: Elements tab: an element loses focus when selected by Up/Down key
3223         https://bugs.webkit.org/show_bug.cgi?id=157768
3224         <rdar://problem/26311155>
3225
3226         Reviewed by Timothy Hatcher.
3227
3228         Remove _previousFocusedSection and _newInspectorRuleSelector since it was used only
3229         to focus on a newly created section (added by clicking on "+" button).
3230
3231         Introduce _inspectorSection and _isInspectorSectionPendingFocus.
3232
3233         * UserInterface/Views/CSSStyleDeclarationSection.js:
3234         (WebInspector.CSSStyleDeclarationSection.prototype.cssStyleDeclarationTextEditorBlurActiveEditor): Deleted.
3235         (WebInspector.CSSStyleDeclarationSection.prototype._handleSelectorPaste): Deleted.
3236         No longer needed, it was only used by _previousFocusedSection and _newInspectorRuleSelector.
3237
3238         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
3239         (WebInspector.CSSStyleDeclarationTextEditor.): Deleted.
3240         No londer needed, it was only used by _previousFocusedSection.
3241
3242         * UserInterface/Views/RulesStyleDetailsPanel.js:
3243         (WebInspector.RulesStyleDetailsPanel):
3244         (WebInspector.RulesStyleDetailsPanel.prototype.refresh.appendStyleSection):
3245         (WebInspector.RulesStyleDetailsPanel.prototype.newRuleButtonClicked):
3246         (WebInspector.RulesStyleDetailsPanel.prototype.nodeStylesRefreshed):
3247         (WebInspector.RulesStyleDetailsPanel.prototype.cssStyleDeclarationSectionEditorFocused): Deleted.
3248         (WebInspector.RulesStyleDetailsPanel.prototype.cssStyleDeclarationSectionBlurActiveEditor): Deleted.
3249         (WebInspector.RulesStyleDetailsPanel.prototype.cssStyleDeclarationSectionFocusNewInspectorRuleWithSelector): Deleted.
3250
3251 2016-06-08  Joseph Pecoraro  <pecoraro@apple.com>
3252
3253         REGRESSION: Web Inspector: Should be able to evaluate "{a:1, b:2}" in the console
3254         https://bugs.webkit.org/show_bug.cgi?id=158548
3255         <rdar://problem/26708513>
3256
3257         Reviewed by Timothy Hatcher.
3258
3259         * UserInterface/Controllers/RuntimeManager.js:
3260         (WebInspector.RuntimeManager.prototype.evaluateInInspectedWindow):
3261         Switch the many parameters to an options dictionary.
3262         Include a new option for sourceURL appender, so that
3263         Console evaluations can have its own append.
3264
3265         * UserInterface/Controllers/JavaScriptLogViewController.js:
3266         (WebInspector.JavaScriptLogViewController.prototype.consolePromptTextCommitted):
3267         Use the appendWebInspectorConsoleEvaluationSourceURL appender.
3268
3269         * UserInterface/Controllers/JavaScriptRuntimeCompletionProvider.js:
3270         (WebInspector.JavaScriptRuntimeCompletionProvider.prototype.completionControllerCompletionsNeeded.evaluated):
3271         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
3272         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateWatchExpressionsSection.):
3273         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateWatchExpressionsSection):
3274         Use the new options dictionary.
3275
3276 2016-06-08  Brian Burg  <bburg@apple.com>
3277
3278         Web Inspector: an error is encountered when trying to delete nodes that have children
3279         https://bugs.webkit.org/show_bug.cgi?id=158541
3280         <rdar://problem/26705901>
3281
3282         Reviewed by Timothy Hatcher.
3283
3284         * UserInterface/Views/DOMTreeElement.js:
3285         (WebInspector.DOMTreeElement.prototype.adjustCollapsedRange):
3286         Offset into the array variable instead of a variable holding its length.
3287
3288 2016-06-08  Brian Burg  <bburg@apple.com>
3289
3290         Web Inspector: DOMTreeOutline selection areas should be created and updated lazily
3291         https://bugs.webkit.org/show_bug.cgi?id=158513
3292         <rdar://problem/26689646>
3293
3294         Reviewed by Timothy Hatcher.
3295
3296         Selection areas for DOMTreeElements are used for several things: drag markers,
3297         element hover styles, element selection styles, and showing forced pseudo states
3298         for an element. Fortunately it's easy to tell when any of these things is necessary.
3299
3300         Change DOMTreeOutline and DOMTreeElement so they don't create selection areas
3301         unless they are needed for one of these tasks. This significantly reduces
3302         forced layouts that are required to update the selection area height in case the
3303         element has new attributes that cause the tag to become more or less wrapped.
3304
3305         * UserInterface/Views/DOMTreeElement.js:
3306         (WebInspector.DOMTreeElement.prototype.set hovered):
3307         Modernize this method a bit.
3308
3309         (WebInspector.DOMTreeElement.prototype.updateSelectionArea):
3310         If a selection area is not necessary, don't create one.
3311         If one exists and it's not needed, then remove it.
3312
3313         (WebInspector.DOMTreeElement.prototype.onattach):
3314         Remove redundant calls to updateSelection(). This is already called in
3315         updateTitle().
3316
3317         (WebInspector.DOMTreeElement.prototype.onselect):
3318         Ask the DOMTreeOutline to update the selection rather than forcing the
3319         element to do it. This is consistent with other updates to user selection.
3320
3321         (WebInspector.DOMTreeElement.prototype._insertInLastAttributePosition):
3322         (WebInspector.DOMTreeElement.prototype._startEditingAsHTML.dispose):
3323         (WebInspector.DOMTreeElement.prototype._startEditingAsHTML):
3324         Use renamed method.
3325
3326         (WebInspector.DOMTreeElement.prototype.updateTitle):
3327         Add a comment to explain why the selection area is nulled out here.
3328
3329         (WebInspector.DOMTreeElement.prototype.get pseudoClassesEnabled):
3330         (WebInspector.DOMTreeElement.prototype._nodePseudoClassesDidChange):
3331         Update the selection area in case one does not exist for this tree element.
3332         The indicator for forced pseudo classes is a pseudo element of the selection area.
3333
3334         (WebInspector.DOMTreeElement.prototype.updateSelection): Renamed.
3335         (WebInspector.DOMTreeElement.prototype.onexpand):
3336         (WebInspector.DOMTreeElement.prototype.oncollapse):
3337         Remove redundant calls to updateSelection(). This is already called in
3338         updateTitle().
3339
3340         * UserInterface/Views/DOMTreeOutline.css:
3341         (.tree-outline.dom):
3342         (.tree-outline.dom li.hovered:not(.selected) .selection-area):
3343         (.tree-outline.dom li .selection-area):
3344         (.tree-outline.dom li.selected .selection-area):
3345         (.tree-outline.dom li.elements-drag-over .selection-area):
3346         (.tree-outline.dom:focus li.selected .selection-area):
3347         (.tree-outline.dom li.pseudo-class-enabled > .selection-area::before):
3348         (.tree-outline.dom:focus li.selected.pseudo-class-enabled > .selection-area::before):
3349         (.tree-outline.dom li.hovered:not(.selected) .selection): Deleted.
3350         (.tree-outline.dom li .selection): Deleted.
3351         (.tree-outline.dom li.selected .selection): Deleted.
3352         (.tree-outline.dom li.elements-drag-over .selection): Deleted.
3353         (.tree-outline.dom:focus li.selected .selection): Deleted.
3354         (.tree-outline.dom li.pseudo-class-enabled > .selection::before): Deleted.
3355         (.tree-outline.dom:focus li.selected.pseudo-class-enabled > .selection::before): Deleted.
3356         Rename the selector to be less ambiguous.
3357
3358         * UserInterface/Views/DOMTreeOutline.js:
3359         (WebInspector.DOMTreeOutline.prototype.updateSelection): Simplify. The call
3360         to update the selection area will bail out if there is nothing to be done.
3361
3362         (WebInspector.DOMTreeOutline.prototype.findTreeElement):
3363         (WebInspector.DOMTreeOutline.prototype._onmousemove):
3364         (WebInspector.DOMTreeOutline.prototype._onmouseout):
3365         Clean up and use let and arrow functions.
3366
3367         (WebInspector.DOMTreeOutline.prototype._ondragover):
3368         (WebInspector.DOMTreeOutline.prototype._clearDragOverTreeElementMarker):
3369         Clear the dragging element before updating the selection area since it looks at
3370         the dragging element to determine whether anything needs to be done.
3371
3372         * UserInterface/Views/FormattedValue.css:
3373         (.formatted-node > .tree-outline.dom li.hovered:not(.selected) .selection-area):
3374         (.formatted-node > .tree-outline.dom li.hovered:not(.selected) .selection): Deleted.
3375         Rename the selector to be less ambiguous.
3376
3377 2016-06-08  Brian Burg  <bburg@apple.com>
3378
3379         Uncaught Exception in TimelineDataGrid._updatePopoverForSelectedNode()
3380         https://bugs.webkit.org/show_bug.cgi?id=158502
3381         <rdar://problem/26687038>
3382
3383         Reviewed by Joseph Pecoraro.
3384
3385         * UserInterface/Views/TimelineDataGrid.js:
3386         (WebInspector.TimelineDataGrid.prototype._updatePopoverForSelectedNode):
3387         It appears that this expression was moved around since it accesses
3388         targetFrame before it's initialized. Check rect.size.height directly.
3389
3390 2016-06-08  Brian Burg  <bburg@apple.com>
3391
3392         Web Inspector: reduce redundant attribute modification updates in DOMTreeUpdater and DOMTreeElement
3393         https://bugs.webkit.org/show_bug.cgi?id=158504
3394         <rdar://problem/25561452>
3395
3396         Reviewed by Timothy Hatcher.
3397
3398         When the frontend gets lots of DOM.attributeModified events, it forwards these on to
3399         DOMTreeUpdater, which pushes a record for every single modification. It then updates
3400         the DOM elements with the attibute changes on an animation frame. However, since it
3401         doesn't do any deduplication of the modification records, a lot of time is wasted
3402         on updating DOMTreeElements with intermediate (non-final) attribute values.
3403
3404         This patch rewrites DOMTreeUpdater to precisely track which nodes and attributes
3405         of each node need to be updated on the next animation frame. This is done using
3406         Sets and Maps that only hold onto the most recent attribute values rather than
3407         pushing a record object for every single mutation.
3408
3409         This improves the performance of the Elements tab on an SVG particle simulator
3410         dramatically so that the Inspector will not immediately hang. It still only achieves
3411         a few updates per second in this case, so there is still optimization to be done on
3412         the frontend and throttling to be done on the backend.
3413
3414         * UserInterface/Views/DOMTreeElement.js:
3415         (WebInspector.DOMTreeElement):
3416         (WebInspector.DOMTreeElement.prototype.attributeDidChange):
3417         (WebInspector.DOMTreeElement.prototype._buildAttributeDOM):
3418         (WebInspector.DOMTreeElement.prototype._markNodeChanged):
3419         (WebInspector.DOMTreeElement.prototype._nodeChangedAnimationEnd):
3420         (WebInspector.DOMTreeElement.prototype._fireDidChange):
3421         (WebInspector.DOMTreeElement.prototype.nodeStateChanged): Deleted.
3422         Simplify the list of modified attributes a little bit. This still uses a worklist
3423         approach, so it's possible that duplicate updates for the same attribute could accumulate
3424         if DOMTreeUpdater pushes updates faster than DOMTreeElement can render them.
3425
3426         * UserInterface/Views/DOMTreeUpdater.js:
3427         (WebInspector.DOMTreeUpdater):
3428         (WebInspector.DOMTreeUpdater.prototype._attributesUpdated):
3429         (WebInspector.DOMTreeUpdater.prototype._characterDataModified):
3430         (WebInspector.DOMTreeUpdater.prototype._nodeAttributeModified):
3431         (WebInspector.DOMTreeUpdater.prototype._nodeInserted):
3432         (WebInspector.DOMTreeUpdater.prototype._nodeRemoved):
3433         (WebInspector.DOMTreeUpdater.prototype._childNodeCountUpdated):
3434         (WebInspector.DOMTreeUpdater.prototype._updateModifiedNodes):
3435         (WebInspector.DOMTreeUpdater.prototype._reset):
3436         Rewrite this class to separately track insertions, deletions, and modifications. Use
3437         Sets and Maps so redundant entries are not kept around. Split the main work loop
3438         and use fewer enum-like properties to control how each DOM element change is handled.
3439
3440         Attempt to update all inserted children before modifying their attributes. This
3441         wasn't done previously, but enough duplicate attribute modifications occurred that
3442         usually some of them would be processed after being added to the tree. There is only
3443         one chance to do this now.
3444
3445 2016-06-08  Nikita Vasilyev  <nvasilyev@apple.com>
3446
3447         REGRESSION (r158219): Web Inspector: Border under the default Timeline content view is too thick
3448         https://bugs.webkit.org/show_bug.cgi?id=158533
3449
3450         Reviewed by Timothy Hatcher.
3451
3452         * UserInterface/Views/OverviewTimelineView.css:
3453         (.timeline-view.overview > .data-grid th): Deleted.
3454
3455 2016-06-08  Timothy Hatcher  <timothy@apple.com>
3456
3457         Web Inspector: Command-W should not close Web Inspector tabs; it should close the window
3458         https://bugs.webkit.org/show_bug.cgi?id=158538
3459         rdar://problem/26699215
3460
3461         Reviewed by Brian Burg.
3462
3463         * UserInterface/Views/TabBrowser.js:
3464         (WebInspector.TabBrowser): Change shortcut to Command-Shift-W.
3465
3466 2016-06-07  Brian Burg  <bburg@apple.com>
3467
3468         Web Inspector: reduce timer churn when processing many DOM.attributeModified messages
3469         https://bugs.webkit.org/show_bug.cgi?id=158491
3470         <rdar://problem/25561452>
3471
3472         Reviewed by Timothy Hatcher.
3473
3474         When the backend sends thousands of DOM.attributeModified events to the frontend, it
3475         slows to a crawl. This is partly because redundant messages are being sent, and
3476         because the frontend is taking too long to render attribute updates in the elements tab.
3477
3478         This patch is a first step to improve performance by reducing unnecessary work. It
3479         coalesces all attribute state updates to only happen once per animation frame. This
3480         reduces timer churn because we previously used a debouncing timer with interval of 0ms,
3481         and that had to be cleared and restarted on every call. This change also eliminates
3482         forced layouts when updating the selection highlights, since the DOM tree outline has
3483         been reflowed by the time we start updating selections in a requestAnimationFrame callback.
3484
3485         There is still a lot of optimization to be done here, but this reduces the problem
3486         considerably by keeping the event loop clear and making it obvious which selection
3487         update operations are still too expensive.
3488
3489         * UserInterface/Base/Utilities.js:
3490         Add a 'onNextFrame' proxy to Object. It works like debounce, except it coalesces calls
3491         up until the next animation frame rather than a fixed timeout. It also does not extend
3492         the timeout interval for each call.
3493
3494         * UserInterface/Views/DOMTreeUpdater.js:
3495         (WebInspector.DOMTreeUpdater.prototype._attributesUpdated):
3496         (WebInspector.DOMTreeUpdater.prototype._characterDataModified):
3497         (WebInspector.DOMTreeUpdater.prototype._nodeInserted):
3498         (WebInspector.DOMTreeUpdater.prototype._nodeRemoved):
3499         (WebInspector.DOMTreeUpdater.prototype._updateModifiedNodes):
3500         Update on the next frame rather than on a zero delay timeout.
3501
3502         * UserInterface/Views/TreeOutline.js:
3503         (WebInspector.TreeOutline.WebInspector.TreeElement.prototype.didChange):
3504         (WebInspector.TreeOutline.WebInspector.TreeElement.prototype._fireDidChange):
3505         Update on the next frame rather than on a zero delay timeout.
3506
3507 2016-06-07  Nikita Vasilyev  <nvasilyev@apple.com>
3508
3509         REGRESSION (r158219): Web Inspector: Border under Memory content view is too thick
3510         https://bugs.webkit.org/show_bug.cgi?id=158495
3511         <rdar://problem/26683428>
3512
3513         Reviewed by Timothy Hatcher.
3514
3515         * UserInterface/Views/MemoryTimelineView.css:
3516         (.timeline-view.memory): Deleted.
3517
3518 2016-06-07  Brian Burg  <bburg@apple.com>
3519
3520         Web Inspector: add a keyboard shortcut to open the new tab tab
3521         https://bugs.webkit.org/show_bug.cgi?id=158365
3522         <rdar://problem/26631897>
3523
3524         Unreviewed, fix a typo introduced in r201692.
3525         This caused the new tab button to stop working.
3526
3527         * UserInterface/Base/Main.js:
3528         (WebInspector._updateNewTabButtonState):
3529
3530 2016-06-05  Matt Baker  <mattbaker@apple.com>
3531
3532         REGRESSION (r201686): Web Inspector: Fix typo causing an internal error
3533         https://bugs.webkit.org/show_bug.cgi?id=158392
3534         <rdar://problem/26640467>
3535
3536         Reviewed by Joseph Pecoraro.
3537
3538         * UserInterface/Views/HeapAllocationsTimelineOverviewGraph.js:
3539         Fixed typo.
3540
3541 2016-06-04  Brian Burg  <bburg@apple.com>
3542
3543         Web Inspector: add a keyboard shortcut to open the new tab tab
3544         https://bugs.webkit.org/show_bug.cgi?id=158365
3545         <rdar://problem/26631897>
3546
3547         Reviewed by Timothy Hatcher.
3548
3549         Make Cmd-t show the new tab tab if it's not already open and
3550         there is at least one tab type that's not currently in the tab bar.
3551
3552         * UserInterface/Base/Main.js:
3553         (WebInspector.contentLoaded):
3554         (WebInspector._updateNewTabButtonState):
3555         (WebInspector.showNewTabTab):
3556         (WebInspector.isNewTabWithTypeAllowed):
3557         Clean up the code that decides whether we can show the new tab tab.
3558         It is now a special case inside WebInspector.isNewTabWithTypeAllowed.
3559
3560         * UserInterface/Views/NewTabContentView.js:
3561         (WebInspector.NewTabContentView.prototype._updateShownTabs):
3562         Use Array.from.
3563
3564 2016-06-04  Matt Baker  <mattbaker@apple.com>
3565
3566         Web Inspector: discontinuous recordings should have discontinuities in the timeline memory graph
3567         https://bugs.webkit.org/show_bug.cgi?id=158052
3568         <rdar://problem/26516695>
3569
3570         Reviewed by Joseph Pecoraro.
3571
3572         Add gaps to the overview and category line charts where discontinuities
3573         exist in the timeline recording.
3574
3575         * UserInterface/Models/Timeline.js:
3576         (WebInspector.Timeline.prototype.recordsInTimeRange):
3577         Replaces `_visibleRecords` methods found in various views.
3578
3579         * UserInterface/Models/TimelineRecording.js:
3580         (WebInspector.TimelineRecording.prototype.reset):
3581         (WebInspector.TimelineRecording.prototype.addDiscontinuity):
3582         (WebInspector.TimelineRecording.prototype.discontinuitiesInTimeRange):
3583         Allow discontinuities to be added to the recording, and have a means to
3584         look up gaps within a time range.
3585
3586         * UserInterface/Views/HeapAllocationsTimelineOverviewGraph.js:
3587         (WebInspector.HeapAllocationsTimelineOverviewGraph.prototype._visibleRecords): Deleted.
3588         Replaced by Timeline helper method.
3589
3590         * UserInterface/Views/MemoryTimelineOverviewGraph.js:
3591         (WebInspector.MemoryTimelineOverviewGraph.prototype.layout.insertDiscontinuity):
3592         (WebInspector.MemoryTimelineOverviewGraph.prototype.layout):
3593         Insert zero-points into the chart at discontinuity boundaries to create
3594         gaps. Data points for records immediately before or after a gap are extended
3595         to the edge of the discontinuity.
3596
3597         (WebInspector.MemoryTimelineOverviewGraph.prototype._visibleRecords): Deleted.
3598         Replaced by Timeline helper method.
3599
3600         * UserInterface/Views/MemoryTimelineView.js:
3601         (WebInspector.MemoryTimelineView.prototype.layout):
3602         Insert zero-points into each category chart at discontinuity boundaries
3603         to create gaps.
3604
3605         Insert zero-points into the chart to create gaps.
3606         (WebInspector.MemoryTimelineView.prototype._visibleRecords): Deleted.
3607         Replaced by Timeline helper method.
3608
3609         * UserInterface/Views/TimelineOverview.js:
3610         (WebInspector.TimelineOverview.prototype.discontinuitiesInTimeRange):
3611         Forward to the TimelineRecording, which isn't exposed to clients.
3612
3613         * UserInterface/Views/TimelineRecordingContentView.js:
3614         (WebInspector.TimelineRecordingContentView):
3615         (WebInspector.TimelineRecordingContentView.prototype._capturingStarted):
3616         (WebInspector.TimelineRecordingContentView.prototype._capturingStopped):
3617         (WebInspector.TimelineRecordingContentView.prototype._recordingReset):
3618         Track discontinuities (recording stop followed by a start) and add them
3619         to the current recording.
3620
3621 2016-06-03  Brian Burg  <bburg@apple.com>
3622
3623         Web Inspector: add a keyboard shortcut to close the current tab bar item
3624         https://bugs.webkit.org/show_bug.cgi?id=158363
3625         <rdar://problem/22677254>
3626
3627         Reviewed by Timothy Hatcher.
3628
3629         Make Cmd-w close the current tab. This matches Safari's keyboard shortcut.
3630
3631         * UserInterface/Views/TabBrowser.js:
3632         (WebInspector.TabBrowser):
3633         Don't do anything if the New Tab tab is the only tab bar item besides the
3634         pinned "new tab" button.
3635
3636 2016-06-03  Brian Burg  <bburg@apple.com>
3637
3638         Web Inspector: setter for debugging flag InspectorBackend.dumpInspectorTimeStats does not work
3639         https://bugs.webkit.org/show_bug.cgi?id=158366
3640
3641         Reviewed by Timothy Hatcher.
3642
3643         * UserInterface/Protocol/InspectorBackend.js:
3644         (InspectorBackendClass.prototype.set dumpInspectorTimeStats):
3645         Actually update the backing member when the setter is called.
3646
3647 2016-06-03  Nikita Vasilyev  <nvasilyev@apple.com>
3648
3649         Web Inspector: Remove unused WebInspector.CSSCompletions methods
3650         https://bugs.webkit.org/show_bug.cgi?id=158352
3651
3652         Reviewed by Joseph Pecoraro.
3653
3654         * UserInterface/Models/CSSCompletions.js:
3655         (WebInspector.CSSCompletions.prototype.firstStartsWith): Deleted.
3656         (WebInspector.CSSCompletions.prototype.isLonghandPropertyName): Deleted.
3657         (WebInspector.CSSCompletions.prototype.longhandsForShorthand): Deleted.
3658
3659 2016-06-03  Joseph Pecoraro  <pecoraro@apple.com>
3660
3661         Web Inspector: Update NativeFunctionParameters (FontFaceSet, HTMLSlotElement, EventTarget)
3662         https://bugs.webkit.org/show_bug.cgi?id=158333
3663
3664         Reviewed by Brian Burg.
3665
3666         * UserInterface/Models/NativeFunctionParameters.js:
3667         Replace FontLoader with FontFaceSet. Add HTMLSlotElement API.
3668         EventTarget is now actually in the prototype chain, so add it as
3669         a first class citizen and keep mixing it in for legacy backends.
3670
3671 2016-06-02  Joseph Pecoraro  <pecoraro@apple.com>
3672
3673         Web Inspector: Modernize Array.prototype.every/some callsites to arrow functions
3674         https://bugs.webkit.org/show_bug.cgi?id=158330
3675
3676         Reviewed by Brian Burg.
3677
3678         * UserInterface/Controllers/DOMTreeManager.js:
3679         (WebInspector.DOMTreeManager.prototype._updateContentFlowFromPayload):
3680         * UserInterface/Models/ProfileNode.js:
3681         (WebInspector.ProfileNode):
3682         * UserInterface/Models/ScopeChainNode.js:
3683         (WebInspector.ScopeChainNode):
3684         * UserInterface/Models/StackTrace.js:
3685         (WebInspector.StackTrace):
3686         * UserInterface/Models/StructureDescription.js:
3687         (WebInspector.StructureDescription):
3688         * UserInterface/Models/TypeDescription.js:
3689         (WebInspector.TypeDescription):
3690         * UserInterface/Protocol/InspectorBackend.js:
3691         (InspectorBackend.Command.prototype.supports):
3692         * UserInterface/Views/ContentViewContainer.js:
3693         (WebInspector.ContentViewContainer.prototype.showContentView):
3694         * UserInterface/Views/NavigationSidebarPanel.js:
3695         (WebInspector.NavigationSidebarPanel.prototype._checkElementsForPendingViewStateCookie.treeElementMatchesCookie):
3696         (WebInspector.NavigationSidebarPanel.prototype._checkElementsForPendingViewStateCookie):
3697         * UserInterface/Views/ScopeBar.js:
3698         (WebInspector.ScopeBar.prototype.get selectedItems):
3699         (WebInspector.ScopeBar.prototype.hasNonDefaultItemSelected):
3700         * UserInterface/Views/TabContentView.js:
3701         (WebInspector.TabContentView):
3702         (WebInspector.TabContentView.console.assert): Deleted.
3703
3704 2016-06-02  Joseph Pecoraro  <pecoraro@apple.com>
3705
3706         Web Inspector: Modernize some function expressions that bind(this) to arrow functions
3707         https://bugs.webkit.org/show_bug.cgi?id=158315
3708
3709         Reviewed by Brian Burg.
3710
3711         Convert a common "function(x) { ... }.bind(this)" pattern to use arrow
3712         functions "(x) => { ... }", which lexically binds `this`, slightly faster,
3713         and uses less memory.
3714
3715         * UserInterface/Base/Main.js:
3716         (WebInspector._updateNewTabButtonState):
3717         * UserInterface/Controllers/BreakpointPopoverController.js:
3718         (WebInspector.BreakpointPopoverController.prototype._createPopoverContent):
3719         * UserInterface/Controllers/TypeTokenAnnotator.js:
3720         (WebInspector.TypeTokenAnnotator.prototype.insertAnnotations):
3721         (WebInspector.TypeTokenAnnotator.prototype.insertAnnotations.): Deleted.
3722         * UserInterface/Models/RenderingFrameTimelineRecord.js:
3723         (WebInspector.RenderingFrameTimelineRecord.prototype._calculateDurationRemainder):
3724         (WebInspector.RenderingFrameTimelineRecord):
3725         * UserInterface/Models/Resource.js:
3726         (WebInspector.Resource.prototype.requestContent):
3727         * UserInterface/Models/Script.js:
3728         (WebInspector.Script.prototype.requestScriptSyntaxTree):
3729         (WebInspector.Script.prototype.requestScriptSyntaxTree.makeSyntaxTreeAndCallCallback): Deleted.
3730         * UserInterface/Models/SourceCodeLocation.js:
3731         (WebInspector.SourceCodeLocation.prototype.populateLiveDisplayLocationString):
3732         * UserInterface/Models/WrappedPromise.js:
3733         (WebInspector.WrappedPromise):
3734         * UserInterface/Views/BreakpointActionView.js:
3735         (WebInspector.BreakpointActionView.prototype._updateBody):
3736         * UserInterface/Views/BreakpointTreeElement.js:
3737         (WebInspector.BreakpointTreeElement.prototype._dataUpdated):
3738         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
3739         (WebInspector.CSSStyleDeclarationTextEditor.prototype._updateTextMarkers.update):
3740         (WebInspector.CSSStyleDeclarationTextEditor.prototype._updateTextMarkers):
3741         * UserInterface/Views/DefaultDashboardView.js:
3742         (WebInspector.DefaultDashboardView.prototype._appendElementForNamedItem.set item):
3743         (WebInspector.DefaultDashboardView.prototype._appendElementForNamedItem):
3744         * UserInterface/Views/ErrorObjectView.js:
3745         (WebInspector.ErrorObjectView.prototype.update):
3746         * UserInterface/Views/GeneralTreeElement.js:
3747         (WebInspector.GeneralTreeElement.prototype.onattach):
3748         (WebInspector.GeneralTreeElement.prototype.onattach.this._boundContextMenuEventHandler): Deleted.
3749         * UserInterface/Views/InlineSwatch.js:
3750         (WebInspector.InlineSwatch.prototype._getNextValidHEXFormat):
3751         (WebInspector.InlineSwatch):
3752         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
3753         (WebInspector.LayerTreeDetailsSidebarPanel.prototype.refresh):
3754         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._showPopoverForSelectedNode):
3755         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._contentForPopover):
3756         * UserInterface/Views/LogContentView.js:
3757         (WebInspector.LogContentView.prototype._mouseup):
3758         * UserInterface/Views/NavigationSidebarPanel.js:
3759         (WebInspector.NavigationSidebarPanel.prototype._checkElementsForPendingViewStateCookie):
3760         * UserInterface/Views/ObjectTreeBaseTreeElement.js:
3761         (WebInspector.ObjectTreeBaseTreeElement.prototype.createGetterElement):
3762         (WebInspector.ObjectTreeBaseTreeElement.prototype.createGetterElement.): Deleted.
3763         * UserInterface/Views/ObjectTreePropertyTreeElement.js:
3764         (WebInspector.ObjectTreePropertyTreeElement.prototype._updateEntries):
3765         * UserInterface/Views/ObjectTreeView.js:
3766         (WebInspector.ObjectTreeView.prototype._updateEntries):
3767         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
3768         (WebInspector.ResourceDetailsSidebarPanel.prototype._refreshImageSizeSection):
3769         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
3770         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._addWatchExpressionButtonClicked):
3771         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._objectTreeElementAddContextMenuItems):
3772         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._addWatchExpressionButtonClicked.this._codeMirror.addKeyMap): Deleted.
3773         * UserInterface/Views/TabBar.js:
3774         * UserInterface/Views/VisualStylePropertyEditor.js:
3775         (WebInspector.VisualStylePropertyEditor.prototype._checkDependencies):
3776
3777 2016-05-31  Nikita Vasilyev  <nvasilyev@apple.com>
3778
3779         Web Inspector: Storage DataGrids have a half-pixel transparent/white border below the header
3780         https://bugs.webkit.org/show_bug.cgi?id=156699
3781         <rdar://problem/25778260>
3782
3783         Reviewed by Timothy Hatcher.
3784
3785         Increase the width of the border below the DataGrid's header to match the border in the left sidebar.
3786
3787         * UserInterface/Views/DataGrid.css:
3788         (.data-grid > .header-wrapper):
3789
3790 2016-05-31  Nikita Vasilyev  <nvasilyev@apple.com>
3791
3792         Web Inspector: Snapshot List scroll bar occludes border of containing view in top-right
3793         https://bugs.webkit.org/show_bug.cgi?id=158219
3794         <rdar://problem/26545018>
3795
3796         Reviewed by Timothy Hatcher.
3797
3798         * UserInterface/Views/TimelineDataGrid.css:
3799         (.data-grid.timeline th): Deleted.
3800         * UserInterface/Views/TimelineRecordingContentView.css:
3801         (.content-view.timeline-recording > .content-browser > .navigation-bar):
3802         Make the border line span across the whole navigation bar, not just its table cells.
3803
3804 2016-05-30  Brian Burg  <bburg@apple.com>
3805
3806         Web Inspector: Timelines: "-0.000ms" in Self Time
3807         https://bugs.webkit.org/show_bug.cgi?id=158162
3808         <rdar://problem/26523350>
3809
3810         Reviewed by Darin Adler.
3811
3812         Values such as -0.0000 and +0.00001 seem to indicate there is
3813         some floating point error accumulating in profile node data.
3814         Since the sampling profiler isn't accurate to that precision,
3815         let's clean up the data so near-zero numbers are simply zero.
3816
3817         * UserInterface/Models/ProfileNode.js:
3818         Round selfTime down to zero if it's less than the
3819         smallest value we would show in the user interface.
3820
3821 2016-05-30  Brian Burg  <bburg@apple.com>
3822
3823         Web Inspector: Uncaught exception page should pre-populate the bug's URL with the inspected page URL
3824         https://bugs.webkit.org/show_bug.cgi?id=158055
3825         <rdar://problem/26516693>
3826
3827         Reviewed by Saam Barati.
3828
3829         * UserInterface/Debug/UncaughtExceptionReporter.js:
3830         Include the encoded URL in the query string if it is not empty.
3831
3832 2016-05-30  Matt Baker  <mattbaker@apple.com>
3833
3834         Web Inspector: Right-clicking in Snapshot's DataGrid throws an exception
3835         https://bugs.webkit.org/show_bug.cgi?id=157934
3836         <rdar://problem/26380910>
3837
3838         Reviewed by Brian Burg.
3839
3840         Check that click event target is actually a cell, as it can be a row
3841         when focusing the table after dismissing a popup menu.
3842
3843         * UserInterface/Views/DataGrid.js:
3844         (WebInspector.DataGridNode.prototype.isEventWithinDisclosureTriangle):
3845
3846 2016-05-27  Joseph Pecoraro  <pecoraro@apple.com>
3847
3848         Web Inspector: Not all transitively dominated nodes display their retained size
3849         https://bugs.webkit.org/show_bug.cgi?id=158174
3850
3851         Reviewed by Timothy Hatcher.
3852
3853         * UserInterface/Views/HeapSnapshotInstanceDataGridNode.js:
3854         (WebInspector.HeapSnapshotInstanceDataGridNode.prototype._isDominatedByNonBaseParent):
3855         Use the parent reference changing in the loop instead of always using the same parent.
3856
3857 2016-05-27  Devin Rousso  <dcrousso+webkit@gmail.com>
3858
3859         Web Inspector: Add indicators to show nesting levels inside DOM Tree
3860         https://bugs.webkit.org/show_bug.cgi?id=157468
3861         <rdar://problem/26162640>
3862
3863         Reviewed by Timothy Hatcher.
3864
3865         Add CSS rules to give all expanded node children lists a small line on the
3866         left border indicating that all items under the line are descendants.
3867
3868         * UserInterface/Views/DOMTreeOutline.css:
3869         (.tree-outline.dom li .selection):
3870         (.tree-outline.dom li > span):
3871         (.tree-outline.dom ol):
3872         (.tree-outline.dom .tree-outline.dom li:matches(.hovered, .selected) + ol.children.expanded):
3873         (.tree-outline.dom li.selected + ol.children.expanded):
3874         (.tree-outline.dom li.parent::before):
3875
3876 2016-05-26  Matt Baker  <mattbaker@apple.com>
3877
3878         Uncaught Exception: TypeError: undefined is not an object (evaluating 'records[endIndex].endTime')
3879         https://bugs.webkit.org/show_bug.cgi?id=158057
3880
3881         Reviewed by Timothy Hatcher.
3882
3883         * UserInterface/Views/TimelineRecordingContentView.js:
3884         (WebInspector.TimelineRecordingContentView.prototype._updateTimelineViewTimes):
3885         When the entire recording is selected, rendering frames should use the
3886         record count as its end time instead of the recording's end time.
3887
3888 2016-05-25  Joseph Pecoraro  <pecoraro@apple.com>
3889
3890         Web Inspector: Uncaught Exception: TypeError: undefined is not an object (evaluating 'collectionData.affectedSnapshots')
3891         https://bugs.webkit.org/show_bug.cg