6ce7509cbf7d9a4d478d108dddf177ae00dd7371
[WebKit-https.git] / Source / WebInspectorUI / ChangeLog
1 2016-01-21  Devin Rousso  <dcrousso+webkit@gmail.com>
2
3         Web Inspector: Add toggle-able list of classes for each element
4         https://bugs.webkit.org/show_bug.cgi?id=152678
5
6         Reviewed by Timothy Hatcher.
7
8         Adds a button to the CSS sidebar that, when toggled, displays a section
9         directly above it containing all the classes for the selected node that,
10         when toggled, adds or removes the class from the node.
11
12         * Localizations/en.lproj/localizedStrings.js:
13
14         * UserInterface/Protocol/RemoteObject.js:
15         (WebInspector.RemoteObject.prototype.callFunction.mycallback):
16         (WebInspector.RemoteObject.prototype.callFunction):
17         Add extra handling of arguments to allow nicer looking calls by other classes.
18
19         * UserInterface/Views/CSSStyleDetailsSidebarPanel.css:
20         Changed next-sibling selector (+) to general-sibling selector (~).
21
22         (.sidebar > .panel.details.css-style > .content ~ :matches(.options-container, .class-list-container)):
23         (.sidebar > .panel.details.css-style > .content:not(.supports-new-rule, .has-filter-bar) ~ :matches(.options-container, .class-list-container)):
24         (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle):
25         (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle.selected):
26         (.sidebar > .panel.details.css-style > .content ~ .options-container > .toggle-class-toggle:not(.selected):hover):
27         (.sidebar > .panel.details.css-style > .content ~ .class-list-container):
28         (.sidebar > .panel.details.css-style > .content ~ .class-list-container[hidden]):
29         (.sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class):
30         (.sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class > input[type="checkbox"]):
31         (.sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class > .add-class-icon):
32         (.sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class > .class-name-input):
33         (.sidebar > .panel.details.css-style > .content ~ .class-list-container > .new-class:not(.active) > .class-name-input):
34         (.sidebar > .panel.details.css-style > .content ~ .class-list-container > *:matches(.new-class, .class-toggle)):
35
36         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
37         (WebInspector.CSSStyleDetailsSidebarPanel):
38         Also changed the few instances of "var" to "let".
39
40         (WebInspector.CSSStyleDetailsSidebarPanel.prototype.refresh):
41         (WebInspector.CSSStyleDetailsSidebarPanel.prototype.addEventListeners):
42         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._handleNodeAttributeModified):
43         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._handleNodeAttributeRemoved):
44         Adds listeners to the DOMNode specifically listening for changes to the
45         class attribute and repopulates the class toggle list if fired.
46
47         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._classToggleButtonClicked):
48         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._addClassContainerClicked):
49         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._addClassInputKeyPressed):
50         If the Enter key is pressed, add a new class equal to the input value.
51
52         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._addClassInputBlur):
53         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._populateClassToggles):
54         Loops through all the classes, including previously removed ones, for the
55         selected node and creates a toggle for each.
56
57         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._createToggleForClassName.classNameToggleChanged):
58         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._createToggleForClassName):
59         Creates a toggle element for the given className and adds it to the container.
60
61         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._toggleClass.resolvedNode.toggleClass):
62         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._toggleClass.resolvedNode):
63         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._toggleClass):
64         Uses the Element.classList to toggle the given className on the selected node.
65
66 2016-01-20  Saam barati  <sbarati@apple.com>
67
68         Web Inspector: Hook the sampling profiler into the Timelines UI
69         https://bugs.webkit.org/show_bug.cgi?id=152766
70         <rdar://problem/24066360>
71
72         Reviewed by Joseph Pecoraro.
73
74         The main change in this patch is to swap in the SamplingProfiler
75         in place of the LegacyProfiler. To do this, we've created a data
76         structure called CallingContextTree which aggregates the SamplingProfiler's
77         data into an easy to manage tree. To see how the data structure works,
78         consider the following program:
79         ```
80         function bar() { // run code here for a long time. }
81         function baz() { // run code here for a long time. }
82         function foo() { bar(); baz(); }
83         foo();
84         ```
85         From this program, we will create a tree like this:
86                         (program)
87                             |
88                             |
89                            foo
90                            | |
91                           /   \
92                          /     \
93                         bar     baz
94         
95         From this type of tree, we can easily create a CPUProfile payload
96         object. Because the Timelines UI knows how to interact with the
97         CPUProfile object and display it, we currently map the tree to this object
98         to make it trivially easy to display the SamplingProfiler's data. In the future,
99         we may want to find ways to work directly with the CallingContextTree instead
100         of mapping it into another object.
101
102         * Localizations/en.lproj/localizedStrings.js:
103         * UserInterface/Controllers/TimelineManager.js:
104         * UserInterface/Main.html:
105         * UserInterface/Models/CallingContextTree.js: Added.
106         * UserInterface/Models/ScriptInstrument.js:
107         * UserInterface/Protocol/ScriptProfilerObserver.js:
108         * UserInterface/TestStub.html:
109         * UserInterface/Views/ScriptTimelineView.js:
110
111 2016-01-19  Joseph Pecoraro  <pecoraro@apple.com>
112
113         Web Inspector: Uncaught exception when logging an Error object
114         https://bugs.webkit.org/show_bug.cgi?id=153258
115         <rdar://problem/24249068>
116
117         Reviewed by Timothy Hatcher.
118
119         * UserInterface/Views/ErrorObjectView.js:
120         (WebInspector.ErrorObjectView):
121         Initialize members that are used later for clarity.
122
123         (WebInspector.ErrorObjectView.prototype.collapse):
124         (WebInspector.ErrorObjectView.prototype.expand):
125         This never has a previewView, remove it.
126
127         (WebInspector.ErrorObjectView.prototype.appendTitleSuffix):
128         Add the suffix ("= $1") after the description and before the
129         content tree outline.
130
131 2016-01-19  Nikita Vasilyev  <nvasilyev@apple.com>
132
133         Web Inspector: Subclasses of WebInspector.Object shouldn't overwrite this._listeners
134         https://bugs.webkit.org/show_bug.cgi?id=153268
135         <rdar://problem/24252766>
136
137         Reviewed by Timothy Hatcher.
138
139         * UserInterface/Base/Object.js:
140         (WebInspector.Object.prototype.dispatchEventToListeners):
141         Add a console.assert.
142
143         * UserInterface/Views/BreakpointTreeElement.js:
144         (WebInspector.BreakpointTreeElement):
145         (WebInspector.BreakpointTreeElement.prototype.onattach):
146         (WebInspector.BreakpointTreeElement.prototype.ondetach):
147         * UserInterface/Views/ProbeSetDataGrid.js:
148         (WebInspector.ProbeSetDataGrid):
149         (WebInspector.ProbeSetDataGrid.prototype.closed):
150         * UserInterface/Views/ProbeSetDetailsSection.js:
151         (WebInspector.ProbeSetDetailsSection):
152         (WebInspector.ProbeSetDetailsSection.prototype.closed):
153         Replace all instances of "this._listeners" with "this._listenerSet".
154
155 2016-01-19  Timothy Hatcher  <timothy@apple.com>
156
157         Web Inspector: Add protocol version for iOS 9.3
158         https://bugs.webkit.org/show_bug.cgi?id=153256
159         rdar://problem/24247951
160
161         Reviewed by Joseph Pecoraro.
162
163         * UserInterface/Protocol/Legacy/9.3/InspectorBackendCommands.js: Added.
164         * Versions/Inspector-iOS-9.3.json: Added.
165
166 2016-01-19  Joseph Pecoraro  <pecoraro@apple.com>
167
168         REGRESSION: Web Inspector: Hovering linkified node references should show node highlight
169         https://bugs.webkit.org/show_bug.cgi?id=153248
170         <rdar://problem/24245518>
171
172         Reviewed by Timothy Hatcher.
173
174         * UserInterface/Base/DOMUtilities.js:
175         Show the complete node highlight details (colors and node info).
176
177 2016-01-19  Nikita Vasilyev  <nvasilyev@apple.com>
178
179         Web Inspector: WebInspector.Object.addEventListener is O(n), make it O(1)
180         https://bugs.webkit.org/show_bug.cgi?id=152422
181         <rdar://problem/24038047>
182
183         Reviewed by Timothy Hatcher.
184
185         Slow addEventListener was the main cause of Console sluggishness[1].
186
187         This patch changes:
188         addEventListener from O(n) to O(1)
189         removeEventListener from O(n) to O(1)
190
191         Now, addEventListener and removeEventListener take <1ms regardless of the
192         number of listeners attached.
193
194         removeEventListener(null, null, thisObject), a special case when all events
195         for thisObject are removed, was improved from O(n^2) to O(n).
196
197         * UserInterface/Base/LinkedList.js: Added.
198         (LinkedList):
199         (LinkedList.prototype.clear):
200         (LinkedList.prototype.get last):
201         (LinkedList.prototype.push):
202         (LinkedList.prototype.remove):
203         (LinkedList.prototype.forEach):
204         (LinkedList.prototype.toArray):
205         (LinkedList.prototype.toJSON):
206         (LinkedListNode):
207         LinkedList ensures O(1) time complexity for push and remove operations.
208
209         * UserInterface/Base/ListMultimap.js: Added.
210         (ListMultimap):
211         (ListMultimap.prototype.get size):
212         (ListMultimap.prototype.add):
213         (ListMultimap.prototype.delete):
214         (ListMultimap.prototype.deleteAll):
215         (ListMultimap.prototype.has):
216         (ListMultimap.prototype.clear):
217         (ListMultimap.prototype.forEach):
218         (ListMultimap.prototype.toArray):
219         (ListMultimap.prototype.toJSON):
220         ListMultimap unsures O(1) time complexity for add, has and delete operations.
221         ListMultimap preserves insertion order by using a LinkedList.
222
223         * UserInterface/Base/Object.js:
224         (WebInspector.Object):
225         (WebInspector.Object.addEventListener):
226         (WebInspector.Object.removeEventListener):
227         (WebInspector.Object.hasEventListeners):
228         (WebInspector.Object.retainedObjectsWithPrototype):
229         (WebInspector.Object.prototype.dispatchEventToListeners):
230         Replace this._listeners[eventType] from array of objects to ListMultimap.
231
232         * UserInterface/Main.html:
233         * UserInterface/Test.html:
234         * UserInterface/TestStub.html:
235
236 2016-01-19  Matt Baker  <mattbaker@apple.com>
237
238         Web Inspector: cleanup TreeOutline class and separate styles from NavigationSidebarPanel
239         https://bugs.webkit.org/show_bug.cgi?id=153146
240         <rdar://problem/24213071>
241
242         Reviewed by Timothy Hatcher.
243
244         This patch consolidates and simplifies the tree outline styles that were previously
245         defined across various classes. A new stylesheet, TreeOutline.css, includes all
246         the styles needed to create a basic TreeOutline.
247
248         In addition, certain tree features which were previously controlled by manually
249         toggling class names have been promoted to properties of TreeOutline:
250          - compact: tree elements have reduced vertical spacing. Used by object trees.
251            The compact and large settings are mutually exclusive.
252          - large: tree elements (and their icons) are large. Used by TimelinesSidebarPanel.
253            Previously there existed a `small` class name which was enabled in every
254            case except TimelineSidebarPanel's Timelines tree. Since it was the rule rather
255            than the exception the class has been removed and is now the default style.
256          - disclosureButtons: control the appearance of disclosure buttons.
257          - customIndent: control use of generated style rules.
258
259         * UserInterface/Main.html:
260         New CSS file.
261
262         * UserInterface/Views/ApplicationCacheFrameTreeElement.js:
263         (WebInspector.ApplicationCacheFrameTreeElement): Deleted.
264         * UserInterface/Views/BreakpointTreeElement.js:
265         (WebInspector.BreakpointTreeElement): Deleted.
266         * UserInterface/Views/CallFrameTreeElement.js:
267         (WebInspector.CallFrameTreeElement): Deleted.
268         * UserInterface/Views/ContentFlowTreeElement.js:
269         (WebInspector.ContentFlowTreeElement): Deleted.
270         Removed call to obsolete TreeOutline.prototype.small setter.
271
272         * UserInterface/Views/DOMTreeOutline.css:
273         (.tree-outline.dom):
274         (.tree-outline.dom li.hovered:not(.selected) .selection):
275         (.tree-outline.dom li .selection):
276         (.tree-outline.dom li.selected .selection):
277         (.tree-outline.dom li.elements-drag-over .selection):
278         (.tree-outline.dom:focus li.selected .selection):
279         (.tree-outline.dom li.selected > span::after):
280         (.tree-outline.dom:focus li.selected > span::after):
281         (.tree-outline.dom ol):
282         (.tree-outline.dom ol.children):
283         (.tree-outline.dom ol.children.expanded):
284         (.tree-outline.dom li):
285         (.tree-outline.dom li.pseudo-class-enabled > .selection::before):
286         (.tree-outline.dom.single-node li):
287         (.tree-outline.dom:focus li.selected):
288         (.tree-outline.dom:focus li.selected.pseudo-class-enabled > .selection::before):
289         (.tree-outline.dom:focus li.selected *):
290         (.tree-outline.dom li.parent):
291         (.tree-outline.dom li .html-tag.close):
292         (.tree-outline.dom li.parent::before):
293         (.tree-outline.dom:focus li.parent.selected::before):
294         (.tree-outline.dom li.parent.expanded::before):
295         (.tree-outline.dom:focus li.parent.expanded.selected::before):
296         (.tree-outline.dom .html-text-node.large):
297         (.tree-outline.dom .html-pseudo-element):
298         (.tree-outline.dom .html-fragment.shadow):
299         (.showing-find-banner .tree-outline.dom .search-highlight):
300         (.dom-tree-outline): Deleted.
301         (.dom-tree-outline li.hovered:not(.selected) .selection): Deleted.
302         (.dom-tree-outline li .selection): Deleted.
303         (.dom-tree-outline li.selected .selection): Deleted.
304         (.dom-tree-outline li.elements-drag-over .selection): Deleted.
305         (.dom-tree-outline:focus li.selected .selection): Deleted.
306         (.dom-tree-outline li.selected > span::after): Deleted.
307         (.dom-tree-outline:focus li.selected > span::after): Deleted.
308         (.dom-tree-outline ol): Deleted.
309         (.dom-tree-outline ol.children): Deleted.
310         (.dom-tree-outline ol.children.expanded): Deleted.
311         (.dom-tree-outline li): Deleted.
312         (.dom-tree-outline li.pseudo-class-enabled > .selection::before): Deleted.
313         (.dom-tree-outline.single-node li): Deleted.
314         (.dom-tree-outline:focus li.selected): Deleted.
315         (.dom-tree-outline:focus li.selected.pseudo-class-enabled > .selection::before): Deleted.
316         (.dom-tree-outline:focus li.selected *): Deleted.
317         (.dom-tree-outline li.parent): Deleted.
318         (.dom-tree-outline li .html-tag.close): Deleted.
319         (.dom-tree-outline li.parent::before): Deleted.
320         (.dom-tree-outline:focus li.parent.selected::before): Deleted.
321         (.dom-tree-outline li.parent.expanded::before): Deleted.
322         (.dom-tree-outline:focus li.parent.expanded.selected::before): Deleted.
323         (.dom-tree-outline .html-text-node.large): Deleted.
324         (.dom-tree-outline .html-pseudo-element): Deleted.
325         (.dom-tree-outline .html-fragment.shadow): Deleted.
326         (.showing-find-banner .dom-tree-outline .search-highlight): Deleted.
327         Updated selectors with new tree outline class names.
328
329         * UserInterface/Views/DOMTreeOutline.js:
330         (WebInspector.DOMTreeOutline):
331         Use default TreeOutline DOM element, and simplify element class name.
332
333         * UserInterface/Views/DatabaseTableTreeElement.js:
334         (WebInspector.DatabaseTableTreeElement): Deleted.
335         * UserInterface/Views/DatabaseTreeElement.js:
336         (WebInspector.DatabaseTreeElement): Deleted.
337         Removed call to obsolete TreeOutline.prototype.small setter.
338
339         * UserInterface/Views/ErrorObjectView.css:
340         (.error-object:not(.expanded) .tree-outline):
341         (.error-object .tree-outline):
342         (.error-object:not(.expanded) .error-object-outline): Deleted.
343         (.error-object-outline): Deleted.
344         Updated selectors with new tree outline class names.
345
346         * UserInterface/Views/ErrorObjectView.js:
347         (WebInspector.ErrorObjectView): Deleted.
348         Removed unused tree outline class name.
349
350         * UserInterface/Views/FolderTreeElement.js:
351         (WebInspector.FolderTreeElement): Deleted.
352         Removed call to obsolete TreeOutline.prototype.small setter.
353
354         * UserInterface/Views/FormattedValue.css:
355         (.formatted-node > .tree-outline.dom):
356         (.formatted-node > .tree-outline.dom ol):
357         (.formatted-node > .tree-outline.dom li):
358         (.formatted-node > .tree-outline.dom li.hovered:not(.selected) .selection):
359         (.formatted-node > .dom-tree-outline): Deleted.
360         (.formatted-node > .dom-tree-outline ol): Deleted.
361         (.formatted-node > .dom-tree-outline li): Deleted.
362         (.formatted-node > .dom-tree-outline li.hovered:not(.selected) .selection): Deleted.
363         Updated selectors with new tree outline class names.
364
365         * UserInterface/Views/GeneralTreeElement.js:
366         (WebInspector.GeneralTreeElement.prototype._updateTitleTooltip):
367         (WebInspector.GeneralTreeElement.prototype.get small): Deleted.
368         (WebInspector.GeneralTreeElement.prototype.set small): Deleted.
369         (WebInspector.GeneralTreeElement.prototype.get twoLine): Deleted.
370         (WebInspector.GeneralTreeElement.prototype.set twoLine): Deleted.
371         Removed properties `small` and `twoLine`. The first is no longer needed as
372         it is now the default tree element style. The second was not being used.
373
374         * UserInterface/Views/IndexedDatabaseObjectStoreIndexTreeElement.js:
375         (WebInspector.IndexedDatabaseObjectStoreIndexTreeElement): Deleted.
376         * UserInterface/Views/IndexedDatabaseObjectStoreTreeElement.js:
377         (WebInspector.IndexedDatabaseObjectStoreTreeElement): Deleted.
378         * UserInterface/Views/IndexedDatabaseTreeElement.js:
379         (WebInspector.IndexedDatabaseTreeElement): Deleted.
380         Removed call to obsolete TreeOutline.prototype.small setter.
381
382         * UserInterface/Views/IssueTreeElement.css:
383         (.navigation-sidebar-panel-content-tree-outline .item.small.issue .icon): Deleted.
384         No longer needed.
385
386         * UserInterface/Views/IssueTreeElement.js:
387         (WebInspector.IssueTreeElement): Deleted.
388         Removed call to obsolete TreeOutline.prototype.small setter.
389
390         * UserInterface/Views/LayoutTimelineView.css:
391         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .tree-outline.layout .item .subtitle):
392         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .navigation-sidebar-panel-content-tree-outline.layout .item .subtitle): Deleted.
393         Updated selectors with new tree outline class names.
394
395         * UserInterface/Views/LogTreeElement.js:
396         (WebInspector.LogTreeElement): Deleted.
397         Removed call to obsolete TreeOutline.prototype.small setter.
398
399         * UserInterface/Views/NavigationSidebarPanel.css:
400         (.navigation-sidebar-panel-content-tree-outline .children): Deleted.
401         (.navigation-sidebar-panel-content-tree-outline .children.expanded): Deleted.
402         (.navigation-sidebar-panel-content-tree-outline .item): Deleted.
403         (.navigation-sidebar-panel-content-tree-outline.hide-disclosure-buttons > .children): Deleted.
404         (.navigation-sidebar-panel-content-tree-outline > .children.hide-disclosure-buttons > .children): Deleted.
405         (.navigation-sidebar-panel-content-tree-outline:not(.hide-disclosure-buttons) .item:not(.parent) .icon): Deleted.
406         (.navigation-sidebar-panel-content-tree-outline.hide-disclosure-buttons .item.small): Deleted.
407         (.navigation-sidebar-panel-content-tree-outline .item .disclosure-button): Deleted.
408         (.navigation-sidebar-panel-content-tree-outline.hide-disclosure-buttons .item .disclosure-button): Deleted.
409         (.navigation-sidebar-panel-content-tree-outline .item.parent .disclosure-button): Deleted.
410         (.navigation-sidebar-panel-content-tree-outline:matches(:focus, .force-focus) .item.selected .disclosure-button): Deleted.
411         (.navigation-sidebar-panel-content-tree-outline .item.expanded .disclosure-button): Deleted.
412         (.navigation-sidebar-panel-content-tree-outline:matches(:focus, .force-focus) .item.selected.expanded .disclosure-button): Deleted.
413         (.navigation-sidebar-panel-content-tree-outline .item .icon): Deleted.
414         (.navigation-sidebar-panel-content-tree-outline .item .status): Deleted.
415         (.navigation-sidebar-panel-content-tree-outline .item .status:empty): Deleted.
416         (.navigation-sidebar-panel-content-tree-outline .item.selected): Deleted.
417         (.navigation-sidebar-panel-content-tree-outline:matches(:focus, .force-focus) .item.selected): Deleted.
418         (body.window-inactive .navigation-sidebar-panel-content-tree-outline .item.selected): Deleted.
419         (.navigation-sidebar-panel-content-tree-outline .item .titles): Deleted.
420         (.navigation-sidebar-panel-content-tree-outline .item .highlighted): Deleted.
421         (.navigation-sidebar-panel-content-tree-outline .item .titles.no-subtitle): Deleted.
422         (.navigation-sidebar-panel-content-tree-outline .item .title::after): Deleted.
423         (.navigation-sidebar-panel-content-tree-outline .item .subtitle): Deleted.
424         (.navigation-sidebar-panel-content-tree-outline:matches(:focus, .force-focus) .item.selected .subtitle): Deleted.
425         (.navigation-sidebar-panel-content-tree-outline .item .subtitle:empty): Deleted.
426         (.navigation-sidebar-panel-content-tree-outline .item.small): Deleted.
427         (.navigation-sidebar-panel-content-tree-outline .item.small.two-line): Deleted.
428         (.navigation-sidebar-panel-content-tree-outline .item.small .icon): Deleted.
429         (.navigation-sidebar-panel-content-tree-outline .item.small .status): Deleted.
430         (.navigation-sidebar-panel-content-tree-outline .item.small .status .indeterminate-progress-spinner): Deleted.
431         (.navigation-sidebar-panel-content-tree-outline .item.small .titles): Deleted.
432         (.navigation-sidebar-panel-content-tree-outline .item.small.two-line .status): Deleted.
433         (.navigation-sidebar-panel-content-tree-outline .item.small.two-line .titles): Deleted.
434         (.navigation-sidebar-panel-content-tree-outline .item.small.two-line .titles.no-subtitle): Deleted.
435         (.navigation-sidebar-panel-content-tree-outline .item.small .subtitle): Deleted.
436         (.navigation-sidebar-panel-content-tree-outline .item.small.two-line .icon): Deleted.
437         (.navigation-sidebar-panel-content-tree-outline .item.small:not(.two-line) .title::after): Deleted.
438         (.navigation-sidebar-panel-content-tree-outline .item.small:not(.two-line) .subtitle::before): Deleted.
439         Generic tree outline styles removed, cleaned up, and relocated to TreeOutline.css.
440
441         * UserInterface/Views/NavigationSidebarPanel.js:
442         Removed static property HideDisclosureButtonsStyleClassName, which is now
443         encapsulated by TreeOutline.
444         (WebInspector.NavigationSidebarPanel.prototype.createContentTreeOutline):
445         Use default TreeOutline DOM element instead of creating it.
446         (WebInspector.NavigationSidebarPanel): Deleted.
447         Remove call to generate style rules.
448         (WebInspector.NavigationSidebarPanel.prototype._generateStyleRulesIfNeeded): Deleted.
449         Moved to TreeOutline.js.
450
451         * UserInterface/Views/NetworkSidebarPanel.css:
452         (.sidebar > .panel.navigation.network.network-grid-content-view-showing .tree-outline.network-grid .item .subtitle):
453         (.sidebar > .panel.navigation.network > .content > .tree-outline):
454         (.sidebar > .panel.navigation.network.network-grid-content-view-showing > .content > .tree-outline):
455         (.sidebar > .panel.navigation.network.network-grid-content-view-showing .navigation-sidebar-panel-content-tree-outline.network-grid .item .subtitle): Deleted.
456         (.sidebar > .panel.navigation.network > .content > .navigation-sidebar-panel-content-tree-outline): Deleted.
457         (.sidebar > .panel.navigation.network.network-grid-content-view-showing > .content > .navigation-sidebar-panel-content-tree-outline): Deleted.
458         Updated selectors with new tree outline class names.
459
460         * UserInterface/Views/NetworkSidebarPanel.js:
461         (WebInspector.NetworkSidebarPanel):
462         Disable tree outline disclosure buttons.
463
464         * UserInterface/Views/NetworkTimelineView.css:
465         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .tree-outline.network .item .subtitle):
466         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .navigation-sidebar-panel-content-tree-outline.network .item .subtitle): Deleted.
467         Updated selectors with new tree outline class names.
468
469         * UserInterface/Views/NetworkTimelineView.js:
470         (WebInspector.NetworkTimelineView):
471         Disable tree outline disclosure buttons.
472
473         * UserInterface/Views/ObjectTreeArrayIndexTreeElement.css:
474         (.object-tree-array-index .index-value .object-tree .tree-outline.object):
475         (.object-tree-array-index .index-value .formatted-node .tree-outline.dom):
476         (.object-tree-array-index .index-value .object-tree .object-tree-outline): Deleted.
477         (.object-tree-array-index .index-value .formatted-node .dom-tree-outline): Deleted.
478         Updated selectors with new tree outline class names.
479
480         * UserInterface/Views/ObjectTreeBaseTreeElement.js:
481         (WebInspector.ObjectTreeBaseTreeElement): Deleted.
482         Removed call to obsolete TreeOutline.prototype.small setter.
483
484         * UserInterface/Views/ObjectTreePropertyTreeElement.css:
485         (.tree-outline .item.object-tree-property):
486         (.item.object-tree-property.prototype-property):
487         (.item.object-tree-property.prototype-property + ol):
488         (.object-tree-property): Deleted.
489         (.object-tree-property > .titles): Deleted.
490         (.object-tree-property > .disclosure-button): Deleted.
491         (.object-tree-property.parent > .disclosure-button): Deleted.
492         (.object-tree-property.parent.expanded > .disclosure-button): Deleted.
493         (.object-tree-property > .icon): Deleted.
494         (.object-tree-property.prototype-property): Deleted.
495         (.object-tree-property.prototype-property + ol): Deleted.
496         Updated selectors with new tree outline class names, removed styles which
497         are now provided by TreeOutline.css.
498
499         * UserInterface/Views/ObjectTreeView.css:
500         (.object-tree .tree-outline.object):
501         (.object-tree.expanded > .tree-outline.object):
502         (.tree-outline.object):
503         (.object-tree.properties-only .tree-outline.object):
504         (.tree-outline.object li):
505         (.tree-outline.object ol):
506         (.tree-outline.object ol.expanded):
507         (.tree-outline.object li .empty-message):
508         (.object-tree .object-tree-outline): Deleted.
509         (.object-tree.expanded > .object-tree-outline): Deleted.
510         (.object-tree-outline): Deleted.
511         (.object-tree.properties-only .object-tree-outline): Deleted.
512         (.object-tree-outline li): Deleted.
513         (.object-tree-outline ol): Deleted.
514         (.object-tree-outline ol.expanded): Deleted.
515         (.object-tree-outline li .empty-message): Deleted.
516         Updated selectors with new tree outline class names.
517
518         * UserInterface/Views/ObjectTreeView.js:
519         (WebInspector.ObjectTreeView):
520         Use default TreeOutline DOM element, and simplify element class name.
521         Enable custom indent (disables generated style rules).
522
523         * UserInterface/Views/ProfileNodeTreeElement.js:
524         (WebInspector.ProfileNodeTreeElement): Deleted.
525         Removed call to obsolete TreeOutline.prototype.small setter.
526
527         * UserInterface/Views/RenderingFrameTimelineView.css:
528         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .tree-outline.rendering-frame .item:not(.paint-record):not(.layout-record) .subtitle):
529         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .navigation-sidebar-panel-content-tree-outline.rendering-frame .item:not(.paint-record):not(.layout-record) .subtitle): Deleted.
530         Updated selectors with new tree outline class names.
531
532         * UserInterface/Views/ResourceSidebarPanel.js:
533         (WebInspector.ResourceSidebarPanel):
534         Disable tree outline disclosure buttons.
535         (WebInspector.ResourceSidebarPanel.prototype._extraDomainsActivated):
536         Enable tree outline disclosure buttons.
537
538         * UserInterface/Views/ScriptTimelineView.css:
539         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .tree-outline.script .item .subtitle):
540         (.sidebar > .panel.navigation.timeline:not(.timeline-recording-content-view-showing) .tree-outline.script .item .alternate-subtitle):
541         (.tree-outline .item .alternate-subtitle):
542         (.tree-outline:matches(:focus, .force-focus) .item.selected .alternate-subtitle):
543         (.tree-outline .item.small:not(.two-line) .alternate-subtitle::before):
544         (.sidebar > .panel.navigation.timeline.timeline-recording-content-view-showing .navigation-sidebar-panel-content-tree-outline.script .item .subtitle): Deleted.
545         (.sidebar > .panel.navigation.timeline:not(.timeline-recording-content-view-showing) .navigation-sidebar-panel-content-tree-outline.script .item .alternate-subtitle): Deleted.
546         (.navigation-sidebar-panel-content-tree-outline .item .alternate-subtitle): Deleted.
547         (.navigation-sidebar-panel-content-tree-outline:matches(:focus, .force-focus) .item.selected .alternate-subtitle): Deleted.
548         (.navigation-sidebar-panel-content-tree-outline .item.small:not(.two-line) .alternate-subtitle::before): Deleted.
549         Updated selectors with new tree outline class names.
550
551         * UserInterface/Views/SearchResultTreeElement.js:
552         (WebInspector.SearchResultTreeElement): Deleted.
553         * UserInterface/Views/SourceCodeTreeElement.js:
554         (WebInspector.SourceCodeTreeElement): Deleted.
555         * UserInterface/Views/StorageTreeElement.js:
556         (WebInspector.StorageTreeElement): Deleted.
557         Removed call to obsolete TreeOutline.prototype.small setter.
558
559         * UserInterface/Views/TimelineDataGrid.css:
560         (.tree-outline.timeline-data-grid .item:hover):
561         (.tree-outline.timeline-data-grid .item:hover .subtitle):
562         (.timeline-data-grid-tree-outline): Deleted.
563         (.timeline-data-grid-tree-outline .item): Deleted.
564         (.timeline-data-grid-tree-outline .item .status): Deleted.
565         (.timeline-data-grid-tree-outline .item .icon): Deleted.
566         (.timeline-data-grid-tree-outline .item:hover): Deleted.
567         (.timeline-data-grid-tree-outline .item .titles): Deleted.
568         (.timeline-data-grid-tree-outline .item .title::after): Deleted.
569         (.timeline-data-grid-tree-outline .item .subtitle): Deleted.
570         (.timeline-data-grid-tree-outline .item:hover .subtitle): Deleted.
571         (.timeline-data-grid-tree-outline .item .subtitle:empty): Deleted.
572         (.timeline-data-grid-tree-outline .item.small): Deleted.
573         (.timeline-data-grid-tree-outline .item.small .icon): Deleted.
574         (.timeline-data-grid-tree-outline .item.small .status): Deleted.
575         (.timeline-data-grid-tree-outline .item.small .titles): Deleted.
576         (.timeline-data-grid-tree-outline .item.small .subtitle): Deleted.
577         (.timeline-data-grid-tree-outline .item.small:not(.two-line) .title::after): Deleted.
578         (.timeline-data-grid-tree-outline .item.small:not(.two-line) .subtitle::before): Deleted.
579         Updated selectors with new tree outline class names, removed styles which
580         are now provided by TreeOutline.css.
581
582         * UserInterface/Views/TimelineDataGrid.js:
583         (WebInspector.TimelineDataGrid.prototype._createPopoverContent):
584         Use default TreeOutline DOM element, and simplify element class name.
585
586         * UserInterface/Views/TimelineRecordTreeElement.js:
587         (WebInspector.TimelineRecordTreeElement): Deleted.
588         Removed call to obsolete TreeOutline.prototype.small setter.
589
590         * UserInterface/Views/TimelineSidebarPanel.css:
591         (.sidebar > .panel.navigation.timeline > .timelines-content .close-button): Deleted.
592         Removed styles which are now provided by TreeOutline.css.
593
594         * UserInterface/Views/TimelineSidebarPanel.js:
595         (WebInspector.TimelineSidebarPanel):
596         Disable tree outline disclosure buttons, enable large tree style.
597
598         * UserInterface/Views/TimelineView.css:
599         (.panel.navigation.timeline > .content > .tree-outline):
600         (.panel.navigation.timeline.timeline-recording-content-view-showing > .content > .tree-outline):
601         (.panel.navigation.timeline > .content > .navigation-sidebar-panel-content-tree-outline): Deleted.
602         (.panel.navigation.timeline.timeline-recording-content-view-showing > .content > .navigation-sidebar-panel-content-tree-outline): Deleted.
603         Updated selectors with new tree outline class names.
604
605         * UserInterface/Views/TreeOutline.css: Added.
606         (.tree-outline .children):
607         (.tree-outline .children.expanded):
608         (.tree-outline .item):
609         (.tree-outline.compact .item):
610         (.tree-outline.large .item):
611         (.tree-outline.hide-disclosure-buttons > .children):
612         (.tree-outline > .children.hide-disclosure-buttons > .children):
613         (.tree-outline:not(.hide-disclosure-buttons) .item:not(.parent) .icon):
614         (.tree-outline .item .disclosure-button):
615         (.tree-outline.hide-disclosure-buttons .item .disclosure-button):
616         (.tree-outline .item.parent .disclosure-button):
617         (.tree-outline:matches(:focus, .force-focus) .item.selected .disclosure-button):
618         (.tree-outline .item.expanded .disclosure-button):
619         (.tree-outline:matches(:focus, .force-focus) .item.selected.expanded .disclosure-button):
620         (.tree-outline .item .icon):
621         (.tree-outline.compact .item .icon):
622         (.tree-outline.large .item .icon):
623         (.tree-outline .item .status):
624         (.tree-outline.large .item .status):
625         (.tree-outline .item .status:empty):
626         (.tree-outline .item.selected):
627         (.tree-outline:matches(:focus, .force-focus) .item.selected):
628         (body.window-inactive .tree-outline .item.selected):
629         (.tree-outline .item .titles):
630         (.tree-outline.compact .item .titles):
631         (.tree-outline.large .item .titles):
632         (.tree-outline .item .highlighted):
633         (.tree-outline.large .item .titles.no-subtitle):
634         (.tree-outline .item .title::after):
635         (.tree-outline .item .subtitle):
636         (.tree-outline.large .item .subtitle):
637         (.tree-outline:matches(:focus, .force-focus) .item.selected .subtitle):
638         (.tree-outline .item .subtitle:empty):
639         (.tree-outline:not(.large) .item .status .indeterminate-progress-spinner):
640         (.tree-outline .item .subtitle::before):
641         Relocated tree outlines styles from NavigationSidebarPanel.css.
642
643         * UserInterface/Views/TreeOutline.js:
644         (WebInspector.TreeOutline):
645         (WebInspector.TreeOutline.prototype.get compact):
646         (WebInspector.TreeOutline.prototype.set compact):
647         (WebInspector.TreeOutline.prototype.get large):
648         (WebInspector.TreeOutline.prototype.set large):
649         (WebInspector.TreeOutline.prototype.get disclosureButtons):
650         (WebInspector.TreeOutline.prototype.set disclosureButtons):
651         (WebInspector.TreeOutline.prototype.get customIndent):
652         (WebInspector.TreeOutline.prototype.set customIndent):
653         Added properties for tree element appearance and indentation
654         behavior, so clients don't need to manually toggle style classes.
655         (WebInspector.TreeOutline._generateStyleRulesIfNeeded):
656         Relocated from NavigationSidebarPanel.js.
657
658         * UserInterface/Views/TypeTreeElement.js:
659         (WebInspector.TypeTreeElement): Deleted.
660         Removed call to obsolete TreeOutline.prototype.small setter.
661
662         * UserInterface/Views/TypeTreeView.css:
663         (.tree-outline.type):
664         (.tree-outline.type li):
665         (.tree-outline.type ol):
666         (.tree-outline.type ol.expanded):
667         (.tree-outline.type li .empty-message):
668         (.type-tree-outline): Deleted.
669         (.type-tree-outline li): Deleted.
670         (.type-tree-outline ol): Deleted.
671         (.type-tree-outline ol.expanded): Deleted.
672         (.type-tree-outline li .empty-message): Deleted.
673         Updated selectors with new tree outline class names.
674
675         * UserInterface/Views/TypeTreeView.js:
676         (WebInspector.TypeTreeView):
677         Use default TreeOutline DOM element, and simplify element class name.
678
679 2016-01-13  Joseph Pecoraro  <pecoraro@apple.com>
680
681         Web Inspector: Inspector should use the last sourceURL / sourceMappingURL directive
682         https://bugs.webkit.org/show_bug.cgi?id=153072
683         <rdar://problem/24168312>
684
685         Reviewed by Timothy Hatcher.
686
687         * UserInterface/Base/Utilities.js:
688         Prepend instead of append the sourceURL so the provided string
689         can include a sourceURL and override it. Such as manually
690         evaluating a script through the quick console with a sourceURL.
691
692         * UserInterface/Models/SourceMapResource.js:
693         Fix an incorrectly named property.
694
695 2016-01-13  Devin Rousso  <dcrousso+webkit@gmail.com>
696
697         Web Inspector: Add support for the existing GradientEditor in the CSS Rules sidebar
698         https://bugs.webkit.org/show_bug.cgi?id=153004
699
700         Reviewed by Timothy Hatcher.
701
702         Both the Visual sidebar and Resource view have editors for CSS gradient
703         values, but the Rules sidebar instead only adds editors for basic color
704         values. Instead of duplicating the code for gradient swatches, existing
705         code will be used to give this same functionality to the Rules sidebar.
706
707         * Localizations/en.lproj/localizedStrings.js:
708         * UserInterface/Main.html:
709
710         * UserInterface/Models/Gradient.js:
711         (WebInspector.Gradient):
712         (WebInspector.Gradient.fromString):
713         (WebInspector.Gradient.stopsWithComponents):
714         (WebInspector.Gradient.prototype.copy):
715         (WebInspector.Gradient.prototype.toString):
716         Refactored WebInspector.Gradient into its own class.
717
718         (WebInspector.LinearGradient):
719         (WebInspector.LinearGradient.prototype.toString):
720         Now uses WebInspector.Gradient inheritance and methods.
721
722         (WebInspector.RadialGradient):
723         (WebInspector.RadialGradient.prototype.toString):
724         Now uses WebInspector.Gradient inheritance and methods.
725
726         * UserInterface/Views/CSSStyleDeclarationTextEditor.css:
727         Use InlineSwatch.css values instead.
728
729         (.css-style-text-editor > .CodeMirror .CodeMirror-lines .cubic-bezier-marker): Deleted.
730         (@media (-webkit-max-device-pixel-ratio: 1)): Deleted.
731         (.css-style-text-editor > .CodeMirror .CodeMirror-lines .cubic-bezier-marker:hover): Deleted.
732         (.css-style-text-editor > .CodeMirror .CodeMirror-lines .cubic-bezier-marker:active): Deleted.
733
734         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
735         (WebInspector.CSSStyleDeclarationTextEditor.prototype.didDismissPopover): Deleted.
736         Removed unused popover member variable.
737
738         (WebInspector.CSSStyleDeclarationTextEditor.prototype._contentChanged):
739         (WebInspector.CSSStyleDeclarationTextEditor.prototype._updateTextMarkers.update):
740         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createInlineSwatches.createSwatch):
741         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createInlineSwatches.update):
742         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createInlineSwatches):
743         Renamed variables for more consistent naming and reimplemented the logic
744         to use the new WebInspector.InlineSwatch methods.  As a result, it was
745         possible to consolidate the 3 different type of swatch functions into a
746         single function.
747
748         (WebInspector.CSSStyleDeclarationTextEditor.prototype._commentProperty.update):
749         (WebInspector.CSSStyleDeclarationTextEditor.prototype._uncommentRange.update):
750         (WebInspector.CSSStyleDeclarationTextEditor.prototype._inlineSwatchValueChanged.update):
751         (WebInspector.CSSStyleDeclarationTextEditor.prototype._inlineSwatchValueChanged):
752         (WebInspector.CSSStyleDeclarationTextEditor.prototype._resetContent.update):
753         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createColorSwatches.createSwatch): Deleted.
754         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createColorSwatches.update): Deleted.
755         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createColorSwatches): Deleted.
756         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createBezierEditors.update): Deleted.
757         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createBezierEditors): Deleted.
758         (WebInspector.CSSStyleDeclarationTextEditor.prototype._colorSwatchColorChanged.update): Deleted.
759         (WebInspector.CSSStyleDeclarationTextEditor.prototype._colorSwatchColorChanged): Deleted.
760         (WebInspector.CSSStyleDeclarationTextEditor.prototype._cubicBezierMarkerClicked.updateCodeMirror.update): Deleted.
761         (WebInspector.CSSStyleDeclarationTextEditor.prototype._cubicBezierMarkerClicked.updateCodeMirror): Deleted.
762         (WebInspector.CSSStyleDeclarationTextEditor.prototype._cubicBezierMarkerClicked): Deleted.
763
764         * UserInterface/Views/CodeMirrorTextMarkers.js:
765         (createCodeMirrorColorTextMarkers.matchFunction):
766         Added logic so that if the matched color string is found inside a gradient,
767         it will not have a marker created for it.
768
769         * UserInterface/Views/InlineSwatch.css: Renamed from Source/WebInspectorUI/UserInterface/Views/ColorSwatch.css.
770         Consolidated the various swatch CSS classes into one file.
771
772         (.inline-swatch):
773         (.inline-swatch.bezier):
774         (.inline-swatch.bezier:hover):
775         (.inline-swatch.bezier:active):
776         (@media (-webkit-max-device-pixel-ratio: 1)):
777         (.inline-swatch > span):
778         Ensured that the inner swatch element can not be selected so that the "click"
779         listener on its parent always fires.
780
781         (.inline-swatch:hover > span):
782         (.inline-swatch:active > span):
783         (.inline-swatch.bezier > span):
784
785         * UserInterface/Views/InlineSwatch.js: Renamed from Source/WebInspectorUI/UserInterface/Views/ColorSwatch.js.
786         (WebInspector.InlineSwatch):
787         Now accepts a new first argument to indicate what type of color swatch
788         to create and what functionality it will have.  Currently has options
789         for WebInspector.Color, WebInspector.Gradient, and WebInspector.CubicBezier.
790
791         (WebInspector.InlineSwatch.prototype.get element):
792         (WebInspector.InlineSwatch.prototype.get value):
793         (WebInspector.InlineSwatch.prototype.set value):
794         (WebInspector.InlineSwatch.prototype._fallbackValue):
795         (WebInspector.InlineSwatch.prototype._updateSwatch):
796         (WebInspector.InlineSwatch.prototype._swatchElementClicked):
797         (WebInspector.InlineSwatch.prototype._valueEditorValueDidChange):
798         (WebInspector.InlineSwatch.prototype._handleContextMenuEvent):
799         (WebInspector.InlineSwatch.prototype._getNextValidHEXFormat.hexMatchesCurrentColor):
800         (WebInspector.InlineSwatch.prototype._getNextValidHEXFormat):
801
802         * UserInterface/Views/VisualStyleBackgroundPicker.css:
803         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .inline-swatch.gradient):
804         (.visual-style-property-container.background-picker > .visual-style-property-value-container:not(.gradient-value) > .inline-swatch.gradient):
805         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .inline-swatch.gradient:hover):
806         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .inline-swatch.gradient:active):
807         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .inline-swatch.gradient > span):
808         (.visual-style-property-container.background-picker > .visual-style-property-value-container.gradient-value > .inline-swatch.gradient + .value-input):
809         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .color-swatch): Deleted.
810         (.visual-style-property-container.background-picker > .visual-style-property-value-container:not(.gradient-value) > .color-swatch): Deleted.
811         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .color-swatch:hover): Deleted.
812         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .color-swatch:active): Deleted.
813         (.visual-style-property-container.background-picker > .visual-style-property-value-container > .color-swatch > span): Deleted.
814         (.visual-style-property-container.background-picker > .visual-style-property-value-container.gradient-value > .color-swatch + .value-input): Deleted.
815
816         * UserInterface/Views/VisualStyleBackgroundPicker.js:
817         Removed the specific code for the gradient swatch and moved to using a
818         gradient-type InlineSwatch for gradient values instead.
819
820         (WebInspector.VisualStyleBackgroundPicker):
821         (WebInspector.VisualStyleBackgroundPicker.prototype.set value):
822         (WebInspector.VisualStyleBackgroundPicker.prototype._updateGradient):
823         (WebInspector.VisualStyleBackgroundPicker.prototype._gradientSwatchColorChanged):
824         (WebInspector.VisualStyleBackgroundPicker.prototype._valueInputValueChanged):
825         (WebInspector.VisualStyleBackgroundPicker.prototype._handleKeywordChanged):
826         (WebInspector.VisualStyleBackgroundPicker.prototype._updateGradientSwatch): Deleted.
827         (WebInspector.VisualStyleBackgroundPicker.prototype._gradientSwatchClicked.handleColorPickerToggled): Deleted.
828         (WebInspector.VisualStyleBackgroundPicker.prototype._gradientSwatchClicked): Deleted.
829         (WebInspector.VisualStyleBackgroundPicker.prototype._gradientEditorGradientChanged): Deleted.
830
831         * UserInterface/Views/VisualStyleColorPicker.css:
832         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .inline-swatch.color):
833         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .inline-swatch.color:hover):
834         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .inline-swatch.color:active):
835         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .inline-swatch.color > span):
836         Add override CSS to ensure that the color-type InlineSwatch displays nicely
837         next to the flexbox style Visual sidebar.
838
839         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .color-swatch): Deleted.
840         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .color-swatch:hover): Deleted.
841         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .color-swatch:active): Deleted.
842         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .color-swatch > span): Deleted.
843         Refactored to only use overriding properties of the basic .inline-swatch values.
844
845         * UserInterface/Views/VisualStyleColorPicker.js:
846         (WebInspector.VisualStyleColorPicker):
847         (WebInspector.VisualStyleColorPicker.prototype._colorSwatchColorChanged):
848         (WebInspector.VisualStyleColorPicker.prototype._updateColorSwatch):
849
850         * UserInterface/Views/VisualStyleTimingEditor.css:
851         (.visual-style-property-container.timing-editor > .visual-style-property-value-container > .inline-swatch.bezier):
852         (.visual-style-property-container.timing-editor > .visual-style-property-value-container:not(.bezier-value) > .inline-swatch.bezier):
853         (@media (-webkit-min-device-pixel-ratio: 2)):
854         Add override CSS to ensure that the color-type InlineSwatch displays nicely
855         next to the flexbox style Visual sidebar.
856
857         (.visual-style-property-container.timing-editor > .visual-style-property-value-container > .bezier-editor): Deleted.
858         (.visual-style-property-container.timing-editor > .visual-style-property-value-container > .bezier-editor:hover): Deleted.
859         (.visual-style-property-container.timing-editor > .visual-style-property-value-container > .bezier-editor:active): Deleted.
860         Refactored to only use overriding properties of the basic .inline-swatch values.
861
862         * UserInterface/Views/VisualStyleTimingEditor.js:
863         Removed the specific code for the cubic-bezier swatch and moved to using a
864         cubic-bezier-type InlineSwatch for gradient values instead.
865
866         (WebInspector.VisualStyleTimingEditor):
867         (WebInspector.VisualStyleTimingEditor.prototype.get bezierValue):
868         (WebInspector.VisualStyleTimingEditor.prototype.set bezierValue):
869         (WebInspector.VisualStyleTimingEditor.prototype._setValue):
870         (WebInspector.VisualStyleTimingEditor.prototype._handleKeywordChanged):
871         (WebInspector.VisualStyleTimingEditor.prototype._bezierSwatchValueChanged):
872         (WebInspector.VisualStyleTimingEditor.prototype._bezierMarkerClicked): Deleted.
873
874 2016-01-12  Matt Baker  <mattbaker@apple.com>
875
876         Web Inspector: Timeline recording controls should use NavigationBar
877         https://bugs.webkit.org/show_bug.cgi?id=152997
878
879         Reviewed by Brian Burg.
880
881         NavigtaionBar should always be preferred over manually editing the DOM.
882         Reusing existing button types for the record button and status element lets us
883         eliminate a bunch of CSS, and will make future changes to the Timelines UI
884         (such as adding addition recording controls), easier to implement.
885
886         * Localizations/en.lproj/localizedStrings.js:
887         New tooltip strings.
888
889         * UserInterface/Views/TimelineSidebarPanel.css:
890         (.sidebar > .panel.navigation.timeline > .navigation-bar > .item.record-start-stop):
891         (.sidebar > .panel.navigation.timeline > .navigation-bar > .item.record-start-stop:hover):
892         (.sidebar > .panel.navigation.timeline > .navigation-bar > .item.record-start-stop:active):
893         Replaced similar styles used for the record glyph.
894         (.sidebar > .panel.navigation.timeline > .navigation-bar > .item.record-start-stop *):
895         Prevent multiple mouseover/mouseout events while hovering the navigation item.
896         (.sidebar > .panel.navigation.timeline > .navigation-bar > .item.flexible-space):
897         Replaced similar styles used for the record status element.
898         (.sidebar > .panel.navigation.timeline > .status-bar): Deleted.
899         (body.window-inactive .sidebar > .panel.navigation.timeline > .status-bar): Deleted.
900         (.sidebar > .panel.navigation.timeline > .status-bar > .record-glyph): Deleted.
901         (.sidebar > .panel.navigation.timeline > .status-bar > .record-glyph:hover): Deleted.
902         (.sidebar > .panel.navigation.timeline > .status-bar > .record-glyph:active): Deleted.
903         (.sidebar > .panel.navigation.timeline > .status-bar > .record-glyph.recording): Deleted.
904         (.sidebar > .panel.navigation.timeline > .status-bar > .record-status): Deleted.
905         (.panel.timeline .navigation-bar.timelines-view): Deleted.
906         No longer used.
907
908         * UserInterface/Views/TimelineSidebarPanel.js:
909         Removed unused CSS static variables.
910         (WebInspector.TimelineSidebarPanel):
911         Create navigation bar, remove status bar DOM elements. Create keyboard shortcut
912         before the record button, so the shortcut's display name can be used in tooltips.
913         (WebInspector.TimelineSidebarPanel.prototype._capturingStartedOrStopped):
914         Update record button state and flexible space (status) text.
915         (WebInspector.TimelineSidebarPanel.prototype._recordButtonClicked):
916         Toggle recording state, and update record button state and flexible space (status) text.
917         (WebInspector.TimelineSidebarPanel.prototype._recordButtonMousedOver):
918         (WebInspector.TimelineSidebarPanel.prototype._recordButtonMousedOut):
919         Update flexible space (status) text.
920         (WebInspector.TimelineSidebarPanel.prototype._updateRecordButton):
921         (WebInspector.TimelineSidebarPanel.prototype._updateReplayInterfaceVisibility):
922         (WebInspector.TimelineSidebarPanel.prototype._toggleRecording): Deleted.
923         (WebInspector.TimelineSidebarPanel.prototype._capturingStarted): Deleted.
924         (WebInspector.TimelineSidebarPanel.prototype._capturingStopped): Deleted.
925         (WebInspector.TimelineSidebarPanel.prototype._recordGlyphMousedOver): Deleted.
926         (WebInspector.TimelineSidebarPanel.prototype._recordGlyphMousedOut): Deleted.
927         (WebInspector.TimelineSidebarPanel.prototype._recordGlyphClicked): Deleted.
928         No longer used.
929
930 2016-01-12  Matt Baker  <mattbaker@apple.com>
931
932         Web Inspector: Move helper methods for getting icons/text to TimelineTabContentView
933         https://bugs.webkit.org/show_bug.cgi?id=152996
934
935         Reviewed by Brian Burg.
936
937         In preparation for the Timelines UI redesign, helper methods which existed
938         in the sidebar panel and timeline tree elements need to be relocated,
939         since the sidebar won't exist in the new UI.
940
941         * UserInterface/Views/TimelineRecordTreeElement.js:
942         (WebInspector.TimelineRecordTreeElement):
943         Removed icon/title code, replaced with calls to new helper methods.
944         Code to create the alternate subtitle was broken out form the rest
945         of the icon/title code, and kept in the constructor.
946
947         * UserInterface/Views/TimelineRecordingContentView.js:
948         (WebInspector.TimelineRecordingContentView.prototype._instrumentAdded):
949         Updated calls to helper methods.
950
951         * UserInterface/Views/TimelineSidebarPanel.js:
952         (WebInspector.TimelineSidebarPanel.prototype._instrumentAdded):
953         (WebInspector.TimelineSidebarPanel.displayNameForTimeline): Deleted.
954         (WebInspector.TimelineSidebarPanel.iconClassNameForTimeline): Deleted.
955         Moved to TimelineTabContentView.
956
957         * UserInterface/Views/TimelineTabContentView.js:
958         (WebInspector.TimelineTabContentView.displayNameForTimeline):
959         (WebInspector.TimelineTabContentView.iconClassNameForTimeline):
960         Relocated from TimelineSidebarPanel.
961         (WebInspector.TimelineTabContentView.iconClassNameForRecord):
962         (WebInspector.TimelineTabContentView.displayNameForRecord):
963         New helper methods. Previously part of TimelineRecordTreeElement.
964
965 2016-01-12  Brian Burg  <bburg@apple.com>
966
967         Web Inspector: fix some common misspellings in localized strings
968         https://bugs.webkit.org/show_bug.cgi?id=153030
969         <rdar://problem/24153340>
970
971         Reviewed by Joseph Pecoraro.
972
973         Replace 'occured', 'transfered' with 'occurred' and 'transferred'.
974
975         * Localizations/en.lproj/localizedStrings.js:
976         * UserInterface/Views/DatabaseTableContentView.js:
977         (WebInspector.DatabaseTableContentView.prototype._queryError):
978         * UserInterface/Views/NetworkGridContentView.js:
979         (WebInspector.NetworkGridContentView):
980         * UserInterface/Views/NetworkTimelineView.js:
981         (WebInspector.NetworkTimelineView):
982         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
983         (WebInspector.ResourceDetailsSidebarPanel):
984
985 2016-01-12  Matt Baker  <mattbaker@apple.com>
986
987         Web Inspector: Fix DataGrid row disclosure appearance and behavior
988         https://bugs.webkit.org/show_bug.cgi?id=152991
989
990         Reviewed by Brian Burg.
991
992         * UserInterface/Views/DataGrid.css:
993         (.data-grid tr.parent td.disclosure::before):
994         Ensure triangle is vertically aligned for any row height.
995         (.data-grid tr:not(.parent) td.disclosure):
996         Fix indent size.
997
998         * UserInterface/Views/DataGrid.js:
999         (WebInspector.DataGridNode.prototype.createCell):
1000         Added `icon` column property, encapsulate icon element creation.
1001         (WebInspector.DataGridNode.prototype.isEventWithinDisclosureTriangle):
1002         Fix hit test logic by computing left padding.
1003
1004 2016-01-12  Devin Rousso  <dcrousso+webkit@gmail.com>
1005
1006         Web Inspector: REGRESSION (r194879) - Opening views without being previously opened causes an Uncaught Exception
1007         https://bugs.webkit.org/show_bug.cgi?id=153006
1008
1009         Reviewed by Brian Burg.
1010
1011         * UserInterface/Views/MultipleScopeBarItem.js:
1012         (WebInspector.MultipleScopeBarItem.prototype.displaySelectedItem):
1013         If there is no selected item, default to the first item in the list.
1014
1015 2016-01-12  Devin Rousso  <dcrousso+webkit@gmail.com>
1016
1017         Web Inspector: creating a gradient in the Visual sidebar causes a crash
1018         https://bugs.webkit.org/show_bug.cgi?id=153003
1019
1020         Reviewed by Brian Burg.
1021
1022         * UserInterface/Views/VisualStyleBackgroundPicker.js:
1023         (WebInspector.VisualStyleBackgroundPicker.prototype._gradientSwatchClicked):
1024         If a gradient does not already exist when the swatch is clicked, create a basic
1025         gradient using the current type and two "transparent" color stops (a minimum of
1026         two color stops are needed for a valid gradient).
1027
1028 2016-01-11  Devin Rousso  <dcrousso+webkit@gmail.com>
1029
1030         Web Inspector: Storage tab navigation bar should fit on a single line
1031         https://bugs.webkit.org/show_bug.cgi?id=152473
1032
1033         Reviewed by Timothy Hatcher.
1034
1035         The wrapping of the navigation bar on the Storage tab was caused by the
1036         fact that Sidebar.js used a minimum width of 200px, regardless of the
1037         content within the sidebar (unless it had a NavigationBar). Logic has
1038         been added that causes the sidebar to use the selected panel's own
1039         minimum width calculation if it is greater than 200px.
1040
1041         * UserInterface/Views/DebuggerSidebarPanel.js:
1042         (WebInspector.DebuggerSidebarPanel.prototype.get minimumWidth):
1043
1044         * UserInterface/Views/MultipleScopeBarItem.js:
1045         (WebInspector.MultipleScopeBarItem.prototype.set selectedScopeBarItem):
1046         (WebInspector.MultipleScopeBarItem.prototype.displaySelectedItem):
1047         Sets the displayed text to the currently selected item.
1048
1049         (WebInspector.MultipleScopeBarItem.prototype.displayWidestItem):
1050         Sets the displayed text to the widest (pixel wise) item in the select element.
1051
1052         * UserInterface/Views/NavigationBar.js:
1053         (WebInspector.NavigationBar.prototype._calculateMinimumWidth):
1054         Now uses NavigationItem.prototype.get minimumWidth.
1055
1056         * UserInterface/Views/NavitationItem.js:
1057         (WebInspector.NavitationItem.prototype.get minimumWidth):
1058         Returns the element's realOffsetWidth.
1059
1060         * UserInterface/Views/NetworkSidebarPanel.js:
1061         (WebInspector.NetworkSidebarPanel.prototype.get minimumWidth):
1062
1063         * UserInterface/Views/ResourceSidebarPanel.js:
1064         (WebInspector.ResourceSidebarPanel.prototype.get minimumWidth):
1065
1066         * UserInterface/Views/ScopeBar.js:
1067         (WebInspector.ScopeBar):
1068         (WebInspector.ScopeBar.prototype.get minimumWidth):
1069
1070         * UserInterface/Views/Sidebar.js:
1071         (WebInspector.Sidebar.prototype.set selectedSidebarPanel):
1072         (WebInspector.Sidebar.prototype.get minimumWidth):
1073         (WebInspector.Sidebar.prototype.set width):
1074         (WebInspector.Sidebar.prototype.set collapsed):
1075         (WebInspector.Sidebar.prototype._recalculateWidth):
1076         Whenever the sidebar changes (e.g. tab change, sidebar becomes
1077         visible/hidden, etc.), a width recalculation is necessary to ensure
1078         that the navigation bar never wraps.
1079
1080         * UserInterface/Views/SidebarPanel.js:
1081         (WebInspector.SidebarPanel.prototype.get minimumWidth):
1082
1083         * UserInterface/Views/StorageSidebarPanel.js:
1084         (WebInspector.StorageSidebarPanel.prototype.get minimumWidth):
1085
1086         * UserInterface/Views/TimelineSidebarPanel.js:
1087         (WebInspector.TimelineSidebarPanel.prototype.get minimumWidth):
1088
1089 2016-01-11  Devin Rousso  <dcrousso+webkit@gmail.com>
1090
1091         Web Inspector: Make Timelines view also remember sort order
1092         https://bugs.webkit.org/show_bug.cgi?id=152811
1093
1094         Reviewed by Timothy Hatcher.
1095
1096         Changeset r194574 introduced the ability for WebInspector.Setting objects to
1097         be passed to DataGrid instances to save the sort column for that grid. These
1098         changes also add the ability for the sort order to be save as well.
1099
1100         * UserInterface/Views/ApplicationCacheFrameContentView.js:
1101         (WebInspector.ApplicationCacheFrameContentView.prototype._createDataGrid):
1102
1103         * UserInterface/Views/CookieStorageContentView.js:
1104         (WebInspector.CookieStorageContentView.prototype._rebuildTable):
1105
1106         * UserInterface/Views/DOMStorageContentView.js:
1107         (WebInspector.DOMStorageContentView):
1108
1109         * UserInterface/Views/DataGrid.js:
1110         (WebInspector.DataGrid):
1111         (WebInspector.DataGrid.prototype.set sortOrder):
1112         If a WebInspector.Setting object has been given, save the new sort order.
1113
1114         (WebInspector.DataGrid.prototype.set sortOrderSetting):
1115         Saves the given WebInspector.Setting object for modification whenever the user
1116         changes the sort order.
1117
1118         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
1119         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._buildDataGridSection):
1120
1121         * UserInterface/Views/LayoutTimelineView.js:
1122         (WebInspector.LayoutTimelineView):
1123
1124         * UserInterface/Views/NetworkGridContentView.js:
1125         (WebInspector.NetworkGridContentView):
1126
1127         * UserInterface/Views/NetworkTimelineView.js:
1128         (WebInspector.NetworkTimelineView):
1129
1130         * UserInterface/Views/RenderingFrameTimelineView.js:
1131         (WebInspector.RenderingFrameTimelineView):
1132
1133         * UserInterface/Views/ScriptTimelineView.js:
1134         (WebInspector.ScriptTimelineView):
1135
1136 2016-01-11  Johan K. Jensen  <jj@johanjensen.dk>
1137
1138         Web Inspector: Copying JS object output from console shouldn't include trailing '= $n'
1139         https://bugs.webkit.org/show_bug.cgi?id=119347
1140
1141         Reviewed by Joseph Pecoraro.
1142
1143         * UserInterface/Views/ConsoleMessageView.js:
1144         (WebInspector.ConsoleMessageView.prototype.toClipboardString):
1145
1146 2016-01-11  Devin Rousso  <dcrousso+webkit@gmail.com>
1147
1148         Web Inspector: Add basic Content section to Visual Sidebar
1149         https://bugs.webkit.org/show_bug.cgi?id=152972
1150
1151         Reviewed by Timothy Hatcher.
1152
1153         Since the "content" property has so many different types of values, a
1154         simple text input editor should be added to provide some support for
1155         the CSS property until a better, more specialized editor is created.
1156
1157         * Localizations/en.lproj/localizedStrings.js:
1158
1159         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.css:
1160         (.visual-style-property-container.comma-separated-keyword-editor):
1161         Moved margin-left to new rule in VisualStylePropertyEditor.css.
1162
1163         * UserInterface/Views/VisualStyleDetailsPanel.js:
1164         (WebInspector.VisualStyleDetailsPanel):
1165         (WebInspector.VisualStyleDetailsPanel.prototype._populateContentSection):
1166         Adds the basic editor under the Text section in a new subsection
1167         called Content.
1168
1169         * UserInterface/Views/VisualStylePropertyEditor.css:
1170         (.visual-style-property-container > *:first-child:matches(.visual-style-property-value-container)):
1171         Adds a left margin to property editors without a title.
1172
1173 2016-01-11  Devin Rousso  <dcrousso+webkit@gmail.com>
1174
1175         Web Inspector: Visual sidebar minor bug fixes
1176         https://bugs.webkit.org/show_bug.cgi?id=152967
1177
1178         Reviewed by Timothy Hatcher.
1179
1180         * UserInterface/Views/VisualStyleDetailsPanel.js:
1181         (WebInspector.VisualStyleDetailsPanel.prototype.refresh):
1182         Only update sections when it is not a significant change, as they are
1183         updated when the selector changes.
1184
1185         (WebInspector.VisualStyleDetailsPanel.prototype._updateProperties):
1186         Only reset links if the refresh is a significant change (node or selected
1187         style changes).
1188
1189         * UserInterface/Views/VisualStyleNumberInputBox.js:
1190         (WebInspector.VisualStyleNumberInputBox):
1191         (WebInspector.VisualStyleNumberInputBox.prototype.get value):
1192         Removed unreachable return.
1193
1194         (WebInspector.VisualStyleNumberInputBox.prototype.set value):
1195         (WebInspector.VisualStyleNumberInputBox.prototype._valueNumberInputKeyDown.adjustValue):
1196         _updatedValues.propertyMissing was changed to _propertyMissing in a
1197         prior patch.
1198
1199 2016-01-11  Joseph Pecoraro  <pecoraro@apple.com>
1200
1201         Web Inspector: Migrate Page Timeline recording to ScriptProfiler
1202         https://bugs.webkit.org/show_bug.cgi?id=152727
1203
1204         Reviewed by Brian Burg.
1205
1206         * UserInterface/Images/TimelineRecordAPI.svg: Added.
1207         * UserInterface/Images/gtk/TimelineRecordAPI.svg: Added.
1208         New [S] image for API initiated script evaluations.
1209         Display matches the existing [S] Script Evaluated.
1210         Colors match the gray [N] Native image colors.
1211
1212         * UserInterface/Models/ScriptInstrument.js:
1213         (WebInspector.ScriptInstrument.prototype.startInstrumentation):
1214         (WebInspector.ScriptInstrument.prototype.stopInstrumentation):
1215         (WebInspector.ScriptInstrument):
1216         Use ScriptProfiler, if available, in Web debuggables.
1217
1218         * UserInterface/Controllers/TimelineManager.js:
1219         (WebInspector.TimelineManager):
1220         (WebInspector.TimelineManager.prototype.capturingStarted):
1221         (WebInspector.TimelineManager.prototype._processRecord):
1222         (WebInspector.TimelineManager.prototype._scriptProfilerTypeToScriptTimelineRecordType):
1223         (WebInspector.TimelineManager.prototype.scriptProfilerTrackingUpdated):
1224         (WebInspector.TimelineManager.prototype.scriptProfilerTrackingCompleted):
1225         (WebInspector.TimelineManager.prototype._mergeScriptProfileRecords.let.nextRecord):
1226         (WebInspector.TimelineManager.prototype._mergeScriptProfileRecords.let.recordContainsRecord):
1227         (WebInspector.TimelineManager.prototype._mergeScriptProfileRecords):
1228         When running a timeline on a web debuggable the frontend receives both
1229         Timeline event records and ScriptProfiler events. Timeline (Web) records
1230         are high level web events like "Script Evaluated", "Event Dispatched",
1231         "Timer Fired". The timestamps for these records should always be wrapping
1232         a ScriptProfiler event and its associated profile data. So, at the end
1233         of a recording we merge ScriptProfiler profile data into the original
1234         Timeline (Web) record.
1235
1236         * UserInterface/Models/ScriptTimelineRecord.js:
1237         (WebInspector.ScriptTimelineRecord.prototype.get profilePayload):
1238         (WebInspector.ScriptTimelineRecord.prototype.set profilePayload):
1239         (WebInspector.ScriptTimelineRecord.prototype.setProfilePayload): Deleted.
1240         Replace method with getter/setter.
1241
1242         (WebInspector.ScriptTimelineRecord.EventType.displayName):
1243         Add a new event type for API records, but share display name with Script Evaluated.
1244
1245         * UserInterface/Views/NavigationSidebarPanel.js:
1246         Fix typo.
1247
1248         * UserInterface/Views/ScriptTimelineView.css:
1249         (.timeline-view.script > .data-grid .eventType-column): Deleted.
1250         There is no "eventType" column in the ScriptTimelineView datagrid, so remove styles.
1251
1252         * UserInterface/Views/TimelineIcons.css:
1253         (.api-record .icon):
1254         * UserInterface/Views/TimelineRecordTreeElement.js:
1255         (WebInspector.TimelineRecordTreeElement):
1256         For API Script Evaluation records use the new icon.
1257
1258 2016-01-10  Joseph Pecoraro  <pecoraro@apple.com>
1259
1260         Web Inspector: Uncaught Exception selecting IndexedDB host folder in Storage tab
1261         https://bugs.webkit.org/show_bug.cgi?id=152943
1262
1263         Reviewed by Brian Burg.
1264
1265         * UserInterface/Views/NavigationSidebarPanel.js:
1266         (WebInspector.NavigationSidebarPanel.prototype._isTreeElementWithoutRepresentedObject):
1267         Another type of specialized folder tree element.
1268
1269 2016-01-10  Joseph Pecoraro  <pecoraro@apple.com>
1270
1271         Uncaught Exception: TypeError: undefined is not an object (evaluating 'this._scopeChain[i].object.deprecatedGetAllProperties')
1272         https://bugs.webkit.org/show_bug.cgi?id=152944
1273         <rdar://problem/24119827>
1274
1275         Reviewed by Brian Burg.
1276
1277         * UserInterface/Models/CallFrame.js:
1278         (WebInspector.CallFrame.prototype.collectScopeChainVariableNames):
1279         Missed one place where `object` needed to change to `objects`.
1280         Here the list will always contain a single object, only UI
1281         generated scopes for the sidebar may have multiple objects.
1282
1283 2016-01-10  Johan K. Jensen  <jj@johanjensen.dk>
1284
1285         Web Inspector: Dashboard log message count doesn't include console.time messages
1286         https://bugs.webkit.org/show_bug.cgi?id=151280
1287
1288         Reviewed by Brian Burg.
1289
1290         * UserInterface/Models/DefaultDashboard.js:
1291         (WebInspector.DefaultDashboard.prototype._incrementConsoleMessageType):
1292         Make Info and Debug levels increment the log count.
1293
1294 2016-01-09  Dan Bernstein  <mitz@apple.com>
1295
1296         [Cocoa] Allow overriding the frameworks directory independently of using a staging install path
1297         https://bugs.webkit.org/show_bug.cgi?id=152926
1298
1299         Reviewed by Tim Horton.
1300
1301         Introduce a new build setting, WK_OVERRIDE_FRAMEWORKS_DIR. When not empty, it determines
1302         where the frameworks are installed. Setting USE_STAGING_INSTALL_PATH to YES sets
1303         WK_OVERRIDE_FRAMEWORKS_DIR to $(SYSTEM_LIBRARY_DIR)/StagedFrameworks/Safari.
1304
1305         Account for the possibility of WK_OVERRIDE_FRAMEWORKS_DIR containing spaces.
1306
1307         * Configurations/Base.xcconfig:
1308         - Replace STAGED_FRAMEWORKS_SEARCH_PATH in FRAMEWORK_SEARCH_PATHS with
1309           WK_OVERRIDE_FRAMEWORKS_DIR and add quotes to account for spaces.
1310         * Configurations/WebInspectorUIFramework.xcconfig:
1311         - Define INSTALL_PATH and PRODUCTION_FRAMEWORKS_DIR based on WK_OVERRIDE_FRAMEWORKS_DIR.
1312
1313 2016-01-08  Joseph Pecoraro  <pecoraro@apple.com>
1314
1315         Web Inspector: Test Resources should not be included in Production builds unless FORCE_TOOL_INSTALL
1316         https://bugs.webkit.org/show_bug.cgi?id=152941
1317         <rdar://problem/24119013>
1318
1319         Reviewed by Dan Bernstein.
1320
1321         * Configurations/Base.xcconfig:
1322         Combine inspector resources in production, but not test resources.
1323
1324         * Configurations/DebugRelease.xcconfig:
1325         Do not combine inspector resources in Release/Debug. Combine test resources.
1326
1327         * Configurations/WebInspectorUIFramework.xcconfig:
1328         Simplify by moving to other config files.
1329
1330         * Scripts/copy-user-interface-resources.pl:
1331         Have FORCE_TOOL_INSTALL combine test resources as well.
1332
1333         * WebInspectorUI.vcxproj/build-webinspectorui.pl:
1334         Only combine test resources in non-Production.
1335
1336 2016-01-08  Joseph Pecoraro  <pecoraro@apple.com>
1337
1338         Web Inspector: Initiated section of Resource Details Sidebar should not display as empty and should update as the list changes
1339         https://bugs.webkit.org/show_bug.cgi?id=152907
1340         <rdar://problem/24109927>
1341
1342         Reviewed by Timothy Hatcher.
1343
1344         * UserInterface/Models/Resource.js:
1345         (WebInspector.Resource.prototype.addInitiatedResource):
1346         Dispatch an event when the list of initiated resources changes.
1347
1348         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
1349         (WebInspector.ResourceDetailsSidebarPanel.prototype.set resource):
1350         Add/remove event listeners for initiated resources changes to refresh
1351         the related resources section.
1352
1353         (WebInspector.ResourceDetailsSidebarPanel.prototype.refresh):
1354         (WebInspector.ResourceDetailsSidebarPanel.prototype._refreshURL):
1355         (WebInspector.ResourceDetailsSidebarPanel.prototype._refreshRelatedResourcesSection):
1356         Show/hide the related resources section depending on if we have something or not.
1357
1358 2016-01-08  Joseph Pecoraro  <pecoraro@apple.com>
1359
1360         Web Inspector: Uncaught exception: TypeError: this._initiatorSourceCodeLocation.sourceCode.addInitiatedResource is not a function
1361         https://bugs.webkit.org/show_bug.cgi?id=152905
1362         <rdar://problem/24109809>
1363
1364         Reviewed by Brian Burg.
1365
1366         * UserInterface/Models/Resource.js:
1367         (WebInspector.Resource):
1368         (WebInspector.Resource.prototype.addInitiatedResource):
1369         Only Resource has addInitiatedResource, so only call it if the
1370         SourceCode in the SourceCodeLocation is a Resource.
1371
1372 2016-01-07  Devin Rousso  <dcrousso+webkit@gmail.com>
1373
1374         Web Inspector: Add warnings to section that require specific values of other properties
1375         https://bugs.webkit.org/show_bug.cgi?id=148254
1376
1377         Reviewed by Timothy Hatcher.
1378
1379         Added a function to VisualStylePropertyEditor to allow dependencies to be set which,
1380         whenever the editor is updated or changed, will be checked against the computed styles
1381         of the element to see if all the necessary property values are set.
1382
1383         * Localizations/en.lproj/localizedStrings.js:
1384         * UserInterface/Views/VisualStyleDetailsPanel.js:
1385         (WebInspector.VisualStyleDetailsPanel):
1386         (WebInspector.VisualStyleDetailsPanel.prototype.refresh):
1387         (WebInspector.VisualStyleDetailsPanel.prototype._populatePositionSection):
1388         (WebInspector.VisualStyleDetailsPanel.prototype._populateFlexboxSection):
1389         (WebInspector.VisualStyleDetailsPanel.prototype._populateAlignmentSection):
1390         (WebInspector.VisualStyleDetailsPanel.prototype._populateBorderSection):
1391         (WebInspector.VisualStyleDetailsPanel.prototype._populateOutlineSection):
1392         Added dependencies to relevant property editors.
1393
1394         (WebInspector.VisualStyleDetailsPanel.prototype._prepareForChange): Deleted.
1395         No longer needed as the sidebar panel will refresh whenever triggered.
1396
1397         * UserInterface/Views/VisualStylePropertyEditor.css:
1398         (.visual-style-property-container.layout-reversed > .visual-style-property-title):
1399         (.visual-style-property-container > .visual-style-property-title > .property-reference-info):
1400         (.visual-style-property-container > .visual-style-property-editor-warning):
1401         (.visual-style-property-container.layout-reversed > .visual-style-property-editor-warning):
1402         (.visual-style-property-container > .visual-style-property-editor-warning.missing-dependency):
1403         (.visual-style-property-container > .visual-style-property-value-container):
1404         (.visual-style-property-container.layout-reversed > .visual-style-property-value-container):
1405
1406         * UserInterface/Views/VisualStylePropertyEditor.js:
1407         (WebInspector.VisualStylePropertyEditor):
1408         (WebInspector.VisualStylePropertyEditor.prototype.updateEditorValues):
1409         (WebInspector.VisualStylePropertyEditor.prototype.addDependency):
1410         (WebInspector.VisualStylePropertyEditor.prototype._valueDidChange):
1411         (WebInspector.VisualStylePropertyEditor.prototype._checkDependencies):
1412         Looks at the computed style for the node to see if any dependent properties do not
1413         have one of the required values.
1414
1415         * UserInterface/Views/VisualStyleSelectorSection.js:
1416         (WebInspector.VisualStyleSelectorSection.prototype.update.createSelectorItem):
1417         (WebInspector.VisualStyleSelectorSection.prototype._styleTextReset): Deleted.
1418
1419         * UserInterface/Views/VisualStyleSelectorTreeItem.js:
1420         (WebInspector.VisualStyleSelectorTreeItem.prototype._handleContextMenuEvent):
1421
1422 2016-01-07  Devin Rousso  <dcrousso+webkit@gmail.com>
1423
1424         Web Inspector: Allow error items on Exception page to be selected
1425         https://bugs.webkit.org/show_bug.cgi?id=152861
1426
1427         Reviewed by Brian Burg.
1428
1429         * UserInterface/Debug/UncaughtExceptionReporter.css:
1430         (.uncaught-exception-sheet li):
1431         Allowed user-select on text.
1432
1433 2016-01-07  Devin Rousso  <dcrousso+webkit@gmail.com>
1434
1435         Web Inspector: Add border-image properties to Visual sidebar
1436         https://bugs.webkit.org/show_bug.cgi?id=152755
1437
1438         Reviewed by Timothy Hatcher.
1439
1440         * Localizations/en.lproj/localizedStrings.js:
1441         * UserInterface/Main.html:
1442         Switched the order of VisualStyleURLInput and VisualStyleUnitSlider
1443         to be ordered alphabetically.
1444
1445         * UserInterface/Views/VisualStyleBackgroundPicker.js:
1446         (WebInspector.VisualStyleBackgroundPicker.prototype._keywordSelectMouseDown):
1447
1448         * UserInterface/Views/VisualStyleDetailsPanel.css:
1449         (.sidebar > .panel.details.css-style .visual > .details-section .details-section > .content > .group + .group > .row:first-child):
1450         (.sidebar > .panel.details.css-style .visual > .details-section.background .details-section.border .visual-style-property-container.keyword-checkbox.border-image-slice):
1451         Since the checkbox is so small, give it less room.
1452
1453         * UserInterface/Views/VisualStyleDetailsPanel.js:
1454         (WebInspector.VisualStyleDetailsPanel.prototype._populateBorderSection.generateBorderImagePropertyEditors):
1455         The three properties "border-image-width", "border-image-outset", and
1456         "border-image-slice" all have the same syntax, so one function to generate
1457         the layout for all three is much simpler.
1458
1459         (WebInspector.VisualStyleDetailsPanel.prototype._populateBorderSection):
1460         Added the border image properties to a seperate group under Background > Border.
1461
1462         * UserInterface/Views/VisualStyleKeywordPicker.js:
1463         (WebInspector.VisualStyleKeywordPicker.prototype._keywordSelectMouseDown):
1464
1465         * UserInterface/Views/VisualStyleNumberInputBox.js:
1466         (WebInspector.VisualStyleNumberInputBox):
1467         (WebInspector.VisualStyleNumberInputBox.prototype.set units):
1468         Reordered logic to allow a value of ""/null to set the units to the "Number"
1469         value if it is allowed for that editor.
1470
1471         (WebInspector.VisualStyleNumberInputBox.prototype.get synthesizedValue):
1472         Instead of relying upon whether the editor has any units, just check to see if
1473         the selected units are "Number" and, if not, add them to the value.
1474
1475         (WebInspector.VisualStyleNumberInputBox.prototype._unitsElementTextContent):
1476
1477         * UserInterface/Views/VisualStylePropertyCombiner.js:
1478         (WebInspector.VisualStylePropertyCombiner):
1479         Now has another argument that, when true, assumes the combiner has at least 4
1480         numerical values and is of the form (can have units):
1481             property-name: value1 [value2 [value3 [value4 [...]]]];
1482
1483         (WebInspector.VisualStylePropertyCombiner.prototype.get synthesizedValue):
1484         (WebInspector.VisualStylePropertyCombiner.prototype.updateValuesFromText.updateEditor):
1485         (WebInspector.VisualStylePropertyCombiner.prototype.updateValuesFromText.updateCompatibleEditor):
1486         (WebInspector.VisualStylePropertyCombiner.prototype.updateValuesFromText):
1487         If the new argument is true, assigns the existing values in the following way:
1488          - If there is 1 value, assign it to all of the editors.
1489          - If there are 2 values, assign the 1st one to editors 1 and 3 and the 2nd one
1490             to editors 2 and 4.
1491          - If there are 3 values, assign the 1st one to editor 1, the 2nd one to editors
1492             2 and 4, and the 3rd one to editor 3.
1493          - If there are 4 or more values, assign them normally.
1494
1495         * UserInterface/Views/VisualStylePropertyEditor.js:
1496         (WebInspector.VisualStylePropertyEditor.prototype.valueIsSupportedKeyword):
1497         (WebInspector.VisualStylePropertyEditor.prototype._valueIsSupportedAdvancedKeyword):
1498         Removed call to this.value to prevent recursion from VisualStyleNumberInputBox.
1499
1500         (WebInspector.VisualStylePropertyEditor.prototype.valueIsSupportedUnit):
1501         (WebInspector.VisualStylePropertyEditor.prototype._valueIsSupportedAdvancedUnit):
1502         Removed call to this.units to prevent recursion from VisualStyleNumberInputBox.
1503
1504 2016-01-07  Devin Rousso  <dcrousso+webkit@gmail.com>
1505
1506         Web Inspector: Add indicator that element has pseudo-class in DOM tree
1507         https://bugs.webkit.org/show_bug.cgi?id=152680
1508
1509         Reviewed by Timothy Hatcher.
1510
1511         * UserInterface/Views/DOMTreeElement.js:
1512         (WebInspector.DOMTreeElement):
1513         (WebInspector.DOMTreeElement.prototype._nodePseudoClassesDidChange):
1514         Added an event listener to the node for when pseudo-classes change.
1515
1516         * UserInterface/Views/DOMTreeOutline.css:
1517         (.dom-tree-outline li.pseudo-class-enabled > .selection::before):
1518         (.dom-tree-outline:focus li.selected.pseudo-class-enabled > .selection::before):
1519         Used the hover/selected background style element to ensure that the indicator
1520         is always positioned evenly with the first line of the opening tag.
1521
1522         (.dom-tree-outline li.hovered:not(.selected) .selection):
1523         (.dom-tree-outline li .selection):
1524         (.dom-tree-outline li.selected .selection):
1525         (.dom-tree-outline li.elements-drag-over .selection):
1526         Removed "display: none;" (as well as the "block" declarations) to allow
1527         the ::before pseudo-element to display.
1528
1529 2016-01-07  Devin Rousso  <dcrousso+webkit@gmail.com>
1530
1531         Web Inspector: Make creating new rules in the Styles sidebar simpler
1532         https://bugs.webkit.org/show_bug.cgi?id=152726
1533
1534         Reviewed by Timothy Hatcher.
1535
1536         When creating a new rules of any kind, first look to see if it already exists in
1537         another rule that has no properties. If found, focus/select it instead of creating
1538         a new rule. Otherwise, create the new rule like normal.
1539
1540         Also changed the way in which previously-focused sections/tree-items are saved
1541         to rely upon the selector of the new rule and whether the section for that rule
1542         is empty and an inspector rule.
1543
1544         * Localizations/en.lproj/localizedStrings.js:
1545
1546         * UserInterface/Models/CSSStyleDeclaration.js:
1547         (WebInspector.CSSStyleDeclaration.prototype.isInspectorRule):
1548         Returns true if the style is an inspector rule.
1549
1550         (WebInspector.CSSStyleDeclaration.prototype.hasProperties):
1551         Returns true if the style has CSS properties.
1552
1553         * UserInterface/Models/DOMNodeStyles.js:
1554         (WebInspector.DOMNodeStyles.prototype.rulesForSelector.ruleHasSelector):
1555         (WebInspector.DOMNodeStyles.prototype.rulesForSelector):
1556         Returns a list of CSSRule that match the given selector and are not
1557         in media queries.
1558
1559         * UserInterface/Views/BoxModelDetailsSectionRow.js:
1560         (WebInspector.BoxModelDetailsSectionRow.prototype._updateMetrics):
1561
1562         * UserInterface/Views/CSSStyleDeclarationSection.js:
1563         (WebInspector.CSSStyleDeclarationSection.prototype._handleContextMenuEvent):
1564
1565         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
1566         (WebInspector.CSSStyleDeclarationTextEditor.prototype.commentAllProperties):
1567
1568         * UserInterface/Views/RulesStyleDetailsPanel.js:
1569         (WebInspector.RulesStyleDetailsPanel.prototype.refresh.appendStyleSection):
1570         (WebInspector.RulesStyleDetailsPanel.prototype.refresh.cssStyleDeclarationSectionEditorFocused):
1571         Now saves the newly focused section as the previously-focused section.
1572
1573         (WebInspector.RulesStyleDetailsPanel.prototype.cssStyleDeclarationSectionFocusNewInspectorRuleWithSelector):
1574         Renamed from cssStyleDeclarationSectionFocusNextNewInspectorRule. Now needs
1575         a selector argument.
1576
1577         (WebInspector.RulesStyleDetailsPanel.prototype.newRuleButtonClicked):
1578         (WebInspector.RulesStyleDetailsPanel.prototype.sectionForStyle):
1579         Returns the first section that has a style with matching selector.
1580
1581         (WebInspector.RulesStyleDetailsPanel.prototype.focusEmptySectionWithStyle):
1582         Finds the section corresponding to the given style and, if empty, focuses it.
1583
1584         (WebInspector.RulesStyleDetailsPanel.prototype.nodeStylesRefreshed):
1585         No longer clears the previously-focused section.
1586
1587         * UserInterface/Views/VisualStyleSelectorSection.js:
1588         (WebInspector.VisualStyleSelectorSection):
1589         (WebInspector.VisualStyleSelectorSection.prototype.update.createSelectorItem):
1590         (WebInspector.VisualStyleSelectorSection.prototype.update):
1591         (WebInspector.VisualStyleSelectorSection.prototype.treeItemForStyle):
1592         Returns the first tree item that has a style with matching selector.
1593
1594         (WebInspector.VisualStyleSelectorSection.prototype.selectEmptyStyleTreeItem):
1595         Finds the tree item corresponding to the given style and, if empty, selects it.
1596
1597         (WebInspector.VisualStyleSelectorSection.prototype._addNewRule):
1598
1599         * UserInterface/Views/VisualStyleSelectorTreeItem.js:
1600         (WebInspector.VisualStyleSelectorTreeItem):
1601         Now requires a delegate object.
1602
1603         (WebInspector.VisualStyleSelectorTreeItem.prototype._handleContextMenuEvent):
1604
1605 2016-01-06  Joseph Pecoraro  <pecoraro@apple.com>
1606
1607         Web Inspector: CRASH Attempting to pause on CSP violation not inside of script
1608         https://bugs.webkit.org/show_bug.cgi?id=152825
1609         <rdar://problem/24021276>
1610
1611         Reviewed by Timothy Hatcher.
1612
1613         * UserInterface/Test/TestHarness.js:
1614         (TestHarness.prototype.expectThat):
1615         (TestHarness.prototype.pass):
1616         (TestHarness.prototype.fail):
1617         Add a simple way to output a standard pass/fail message. These are
1618         often nicer than expectThat(true, ...) or assert(false, ...).
1619
1620 2016-01-07  Joseph Pecoraro  <pecoraro@apple.com>
1621
1622         Web Inspector: DOMContentLoaded label in the Timeline tab should be "DOM Content Loaded"
1623         https://bugs.webkit.org/show_bug.cgi?id=152746
1624
1625         Reviewed by Timothy Hatcher.
1626
1627         * Localizations/en.lproj/localizedStrings.js:
1628         * UserInterface/Views/TimelineRuler.js:
1629         (WebInspector.TimelineRuler.prototype.addMarker):
1630
1631 2016-01-06  Joseph Pecoraro  <pecoraro@apple.com>
1632
1633         Web Inspector: Scope chain shows too many scopes for functions (`let` and `var` in the same function are two scopes)
1634         https://bugs.webkit.org/show_bug.cgi?id=152349
1635
1636         Reviewed by Timothy Hatcher.
1637
1638         * Localizations/en.lproj/localizedStrings.js:
1639         New "Closure Variables (%s)" string for including the function name alongside
1640         the closure scope section.
1641
1642         * UserInterface/Models/ScopeChainNode.js:
1643         (WebInspector.ScopeChainNode):
1644         (WebInspector.ScopeChainNode.prototype.get objects):
1645         (WebInspector.ScopeChainNode.prototype.get object): Deleted.
1646         Allow a ScopeChainNode to hold onto multiple RemoteObjects (for multiple JSScopes).
1647
1648         * UserInterface/Controllers/DebuggerManager.js:
1649         (WebInspector.DebuggerManager.prototype._scopeChainNodeFromPayload):
1650         Simplify the legacy case and convert "Local" to "Closure". The UI will now
1651         determine and display "Local" where appropriate in a backwards compatible way.
1652
1653         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
1654         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
1655         Associate ScopeChain nodes with CallFrame frames so that we can better combine
1656         variable sections and better label closure sections.
1657
1658         * UserInterface/Views/ScopeChainDetailsSidebarPanel.css:
1659         (.scope-chain .details-section > .content > .group > .row.properties:not(.empty)):
1660         (.scope-chain .details-section > .content > .group > .row.properties:not(.empty):last-child):
1661         Styles for two object trees property sections next to eachother.
1662
1663 2016-01-06  Devin Rousso  <dcrousso+webkit@gmail.com>
1664
1665         Web Inspector: Add basic Animation section to Visual Sidebar
1666         https://bugs.webkit.org/show_bug.cgi?id=152692
1667
1668         Reviewed by Timothy Hatcher.
1669
1670         Adds a non-autocompleting section to the "Effects" section (renamed from
1671         "Animations") of the Visual sidebar for setting CSS Animation values.
1672
1673         * Scripts/copy-user-interface-resources.pl:
1674         * Localizations/en.lproj/localizedStrings.js:
1675         * UserInterface/Images/AnimationPlayStatePaused.svg: Added.
1676         * UserInterface/Images/AnimationPlayStateRunning.svg: Added.
1677         * UserInterface/Main.html:
1678
1679         * UserInterface/Views/VisualStyleBasicInput.js: Added.
1680         (WebInspector.VisualStyleBasicInput):
1681         (WebInspector.VisualStyleBasicInput.prototype.get value):
1682         (WebInspector.VisualStyleBasicInput.prototype.set value):
1683         (WebInspector.VisualStyleBasicInput.prototype.get synthesizedValue):
1684         (WebInspector.VisualStyleBasicInput.prototype._handleInputElementInput):
1685         Very basic editor that is just an input box with a given placeholder.
1686
1687         * UserInterface/Views/VisualStyleDetailsPanel.js:
1688         (WebInspector.VisualStyleDetailsPanel):
1689         (WebInspector.VisualStyleDetailsPanel.prototype._populateAnimationSection):
1690         Creates the necessary property editors and adds them to their respective rows.
1691
1692 2016-01-06  Devin Rousso  <dcrousso+webkit@gmail.com>
1693
1694         Web Inspector: Add remaining background style properties to Visual sidebar
1695         https://bugs.webkit.org/show_bug.cgi?id=152757
1696
1697         Reviewed by Timothy Hatcher.
1698
1699         * Localizations/en.lproj/localizedStrings.js:
1700
1701         * UserInterface/Views/VisualStyleDetailsPanel.js:
1702         (WebInspector.VisualStyleDetailsPanel.prototype._populateBackgroundStyleSection):
1703         Added background-blend-mode and background-origin property editors.
1704
1705         * UserInterface/Views/VisualStyleSelectorSection.js:
1706         (WebInspector.VisualStyleSelectorSection.prototype._handleMouseOver):
1707         Unrelated error that occurred when the user was hovering over a selector item
1708         before the tree outline was able to create the selected item.
1709
1710 2016-01-05  Joseph Pecoraro  <pecoraro@apple.com>
1711
1712         REGRESSION(r187929): Web Inspector: Forced Layout and Style Recalculation records do not show up in Layout & Rendering timeline DataGrid
1713         https://bugs.webkit.org/show_bug.cgi?id=152747
1714
1715         Reviewed by Timothy Hatcher.
1716
1717         * UserInterface/Views/LayoutTimelineView.js:
1718         (WebInspector.LayoutTimelineView.prototype._layoutTimelineRecordAdded):
1719         We want top-level Layout records. Not necessarily Layout records that are
1720         at the top of all records. Layout events such as style recalculation
1721         and forced layout may be triggered by script and therefore not be at
1722         the top of all records.
1723
1724 2016-01-04  Devin Rousso  <dcrousso+webkit@gmail.com>
1725
1726         Web Inspector: Timelines view doesn't remember how I like to sort things
1727         https://bugs.webkit.org/show_bug.cgi?id=152626
1728
1729         Reviewed by Joseph Pecoraro.
1730
1731         Currently, all instances of DataGrid have their sort column reset with each
1732         open/close of Web Inspector. This doesn't really make sense seeing as we save
1733         the user's settings in many other cases, so the sort method (which column)
1734         should be saved between inspector sessions.
1735
1736         * UserInterface/Views/ApplicationCacheFrameContentView.js:
1737         (WebInspector.ApplicationCacheFrameContentView.prototype._createDataGrid):
1738         * UserInterface/Views/CookieStorageContentView.js:
1739         (WebInspector.CookieStorageContentView.prototype._rebuildTable):
1740         * UserInterface/Views/DOMStorageContentView.js:
1741         (WebInspector.DOMStorageContentView):
1742         * UserInterface/Views/DataGrid.js:
1743         (WebInspector.DataGrid):
1744         (WebInspector.DataGrid.prototype.set sortColumnIdentifier):
1745         Moved the logic for classLists and events to _updateSortedColumn.
1746
1747         (WebInspector.DataGrid.prototype.set sortColumnIdentifierSetting):
1748         Instead of just setting the original sort method when instantiating the DataGrid,
1749         a WebInspector.Setting object is now able to be passed in via this setter
1750         to give the DataGrid access to the stored sort method value.
1751
1752         (WebInspector.DataGrid.prototype._updateSortedColumn):
1753         Updates the classLists and fires events. If a sort column setting object
1754         exists, update its value.
1755
1756         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
1757         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._buildDataGridSection):
1758         * UserInterface/Views/LayoutTimelineView.js:
1759         (WebInspector.LayoutTimelineView):
1760         * UserInterface/Views/NetworkGridContentView.js:
1761         (WebInspector.NetworkGridContentView):
1762         * UserInterface/Views/NetworkTimelineView.js:
1763         (WebInspector.NetworkTimelineView):
1764         * UserInterface/Views/RenderingFrameTimelineView.js:
1765         (WebInspector.RenderingFrameTimelineView):
1766         * UserInterface/Views/ScriptTimelineView.js:
1767         (WebInspector.ScriptTimelineView):
1768
1769 2016-01-04  Devin Rousso  <dcrousso+webkit@gmail.com>
1770
1771         Web Inspector: Add debounce to URL inputs in the Visual sidebar
1772         https://bugs.webkit.org/show_bug.cgi?id=152655
1773
1774         Reviewed by Joseph Pecoraro.
1775
1776         Adding a debounce to url() based Visual sidebar editors will prevent needless
1777         errors from being thrown as the user types, since incomplete URL's will not
1778         be able to be located.
1779
1780         * UserInterface/Base/Utilities.js:
1781         (Function.prototype.debounce):
1782         Prevents the given function from executing more than once in the specified amount of time.
1783
1784         * UserInterface/Views/VisualStyleBackgroundPicker.js:
1785         (WebInspector.VisualStyleBackgroundPicker):
1786
1787         * UserInterface/Views/VisualStyleURLInput.js:
1788         (WebInspector.VisualStyleURLInput):
1789
1790 2016-01-04  Joseph Pecoraro  <pecoraro@apple.com>
1791
1792         Web Inspector: Fix debug context menu string and reload without cache tooltip string
1793         https://bugs.webkit.org/show_bug.cgi?id=152725
1794
1795         Reviewed by Brian Burg.
1796
1797         * UserInterface/Base/Main.js:
1798         (WebInspector.contentLoaded):
1799
1800 2016-01-04  Devin Rousso  <dcrousso+webkit@gmail.com>
1801
1802         Web Inspector: add context menu items to switch CSS color property value syntax between RGB, HSL, etc
1803         https://bugs.webkit.org/show_bug.cgi?id=151918
1804
1805         Reviewed by Timothy Hatcher.
1806
1807         Created a ColorSwatch class to hold all functionality for color swatches,
1808         allowing all context menu and popover events to be centralized.
1809
1810         * Localizations/en.lproj/localizedStrings.js:
1811         * UserInterface/Main.html:
1812
1813         * UserInterface/Models/Color.js:
1814         Changed all 'var' to 'let' and 'nickname' to 'keyword' as per the spec.
1815         Mostly mechanical changes.
1816
1817         (WebInspector.Color.prototype.isKeyword):
1818         Looks at the RGB values of each keyword to see if the current color
1819         matches any of them.
1820
1821         (WebInspector.Color.prototype.canBeSerializedAsShortHEX):
1822         Fixed to account for alpha values, since HEXAlpha is now supported.
1823
1824         * UserInterface/Views/CSSStyleDeclarationTextEditor.css:
1825         (.css-style-text-editor > .CodeMirror .CodeMirror-lines .color-swatch): Deleted.
1826         (@media (-webkit-max-device-pixel-ratio: 1)): Deleted.
1827         (.css-style-text-editor > .CodeMirror .CodeMirror-lines .color-swatch > span): Deleted.
1828         (.css-style-text-editor > .CodeMirror .CodeMirror-lines .color-swatch:hover > span): Deleted.
1829         (.css-style-text-editor > .CodeMirror .CodeMirror-lines .color-swatch:active > span): Deleted.
1830
1831         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
1832         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createColorSwatches.update):
1833         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createColorSwatches):
1834         (WebInspector.CSSStyleDeclarationTextEditor.prototype._colorSwatchColorChanged.update):
1835         (WebInspector.CSSStyleDeclarationTextEditor.prototype._colorSwatchColorChanged):
1836         (WebInspector.CSSStyleDeclarationTextEditor.prototype._colorSwatchClicked.updateCodeMirror.update): Deleted.
1837         (WebInspector.CSSStyleDeclarationTextEditor.prototype._colorSwatchClicked.updateCodeMirror): Deleted.
1838         (WebInspector.CSSStyleDeclarationTextEditor.prototype._colorSwatchClicked): Deleted.
1839
1840         * UserInterface/Views/ColorSwatch.css: Copied from Source/WebInspectorUI/UserInterface/Views/VisualStyleColorPicker.css.
1841         (.color-swatch):
1842         (@media (-webkit-max-device-pixel-ratio: 1)):
1843         (.color-swatch > span):
1844         (.color-swatch:hover > span):
1845         (.color-swatch:active > span):
1846
1847         * UserInterface/Views/ColorSwatch.js: Added.
1848         (WebInspector.ColorSwatch):
1849         (WebInspector.ColorSwatch.prototype.get element):
1850         (WebInspector.ColorSwatch.prototype.set color):
1851         (WebInspector.ColorSwatch.prototype.get color):
1852         (WebInspector.ColorSwatch.prototype._colorSwatchClicked):
1853         (WebInspector.ColorSwatch.prototype._colorPickerColorDidChange):
1854         (WebInspector.ColorSwatch.prototype._handleContextMenuEvent):
1855         (WebInspector.ColorSwatch.prototype._getNextValidHEXFormat.hexMatchesCurrentColor):
1856         (WebInspector.ColorSwatch.prototype._getNextValidHEXFormat):
1857         Loops through the list of HEX formats to find the first format that is valid
1858         for the current color in the list after the current format.
1859
1860         (WebInspector.ColorSwatch.prototype._updateSwatch):
1861
1862         * UserInterface/Views/VisualStyleColorPicker.css:
1863         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .color-swatch):
1864         (.visual-style-property-container.input-color-picker > .visual-style-property-value-container > .color-swatch > span):
1865
1866         * UserInterface/Views/VisualStyleColorPicker.js:
1867         (WebInspector.VisualStyleColorPicker):
1868         (WebInspector.VisualStyleColorPicker.prototype._colorSwatchColorChanged):
1869         (WebInspector.VisualStyleColorPicker.prototype._updateColorSwatch):
1870         (WebInspector.VisualStyleColorPicker.prototype._colorSwatchClicked): Deleted.
1871         (WebInspector.VisualStyleColorPicker.prototype._colorPickerColorDidChange): Deleted.
1872
1873 2016-01-04  Joseph Pecoraro  <pecoraro@apple.com>
1874
1875         Web Inspector: Mark last parameter of webkitGetUserMedia as non-optional to match updated IDL
1876         https://bugs.webkit.org/show_bug.cgi?id=152702
1877
1878         Reviewed by Brian Burg.
1879
1880         * UserInterface/Models/NativeFunctionParameters.js:
1881         New IDL, and tests, show that the error callback is non-optional.
1882
1883 2016-01-04  Devin Rousso  <dcrousso+webkit@gmail.com>
1884
1885         Web Inspector: Add context menu items to CSS selectors to auto-generate pseudo selectors
1886         https://bugs.webkit.org/show_bug.cgi?id=152657
1887
1888         Reviewed by Timothy Hatcher.
1889
1890         Instead of having to copy a selector, create a new one, paste it, and then add
1891         a pseudo class or element, a context menu item has been added to automate this
1892         process for the user for each CSS pseudo-selector.
1893
1894         * Localizations/en.lproj/localizedStrings.js:
1895
1896         * UserInterface/Controllers/CSSStyleManager.js:
1897         Added a static object containing the list of CSS pseudo-element names.
1898
1899         * UserInterface/Models/DOMNodeStyles.js:
1900         (WebInspector.DOMNodeStyles.prototype.addRule.completed):
1901         (WebInspector.DOMNodeStyles.prototype.addRule.styleChanged):
1902         (WebInspector.DOMNodeStyles.prototype.addRule.addedRule):
1903         (WebInspector.DOMNodeStyles.prototype.addRule):
1904         Now accepts a second argument for setting the starting text value of the new rule.
1905
1906         * UserInterface/Views/CSSStyleDeclarationSection.js:
1907         (WebInspector.CSSStyleDeclarationSection.prototype._handleSelectorPaste):
1908
1909         * UserInterface/Views/VisualStyleSelectorTreeItem.js:
1910         (WebInspector.VisualStyleSelectorTreeItem.prototype._handleContextMenuEvent):
1911
1912 2016-01-04  Brian Burg  <bburg@apple.com>
1913
1914         Web Inspector: add a DebugUI context menu item for saving inspector protocol traffic to file
1915         https://bugs.webkit.org/show_bug.cgi?id=152671
1916
1917         Reviewed by Timothy Hatcher.
1918
1919         Add a new tracer that captures all messages, and debug context menu
1920         items to control whether to capture protocol traffic and export it.
1921         In later patches, a reciprocal "Import..." context menu item will
1922         allow opening saved protocol traces and viewing them in a debug UI
1923         content view for debugging/visualizing protocol traffic.
1924
1925         * UserInterface/Base/Main.js:
1926         * UserInterface/Debug/CapturingProtocolTracer.js: Copied from Source/WebInspectorUI/UserInterface/Protocol/ProtocolTracer.js.
1927
1928             This tracer saves everything into a flat array. JSON protocol
1929             messages are saved as escaped strings, in case they are not
1930             valid JSON. We want to be able to debug such scenarios.
1931
1932         (WebInspector.CapturingProtocolTracer):
1933         (WebInspector.CapturingProtocolTracer.prototype.get trace):
1934         (WebInspector.CapturingProtocolTracer.prototype.logFrontendException):
1935         (WebInspector.CapturingProtocolTracer.prototype.logProtocolError):
1936         (WebInspector.CapturingProtocolTracer.prototype.logFrontendRequest):
1937         (WebInspector.CapturingProtocolTracer.prototype.logDidHandleResponse):
1938         (WebInspector.CapturingProtocolTracer.prototype.logDidHandleEvent):
1939         (WebInspector.CapturingProtocolTracer.prototype._stringifyMessage):
1940         (WebInspector.CapturingProtocolTracer.prototype._processEntry):
1941
1942         * UserInterface/Debug/ProtocolTrace.js: Added.
1943
1944             This is a dumb container that holds protocol trace data. It will
1945             be responsible for deserializing saved trace files in later work.
1946
1947         (WebInspector.ProtocolTrace):
1948         (WebInspector.ProtocolTrace.prototype.addEntry):
1949         (WebInspector.ProtocolTrace.prototype.get saveData):
1950         * UserInterface/Main.html:
1951         * UserInterface/Protocol/InspectorBackend.js:
1952         (InspectorBackendClass):
1953
1954             Simplify the implementation. Now there are one or two tracers
1955             at any given time. The default tracer handles legacy logging
1956             behavior and always exists. The custom tracer is installed when
1957             the "Capture Protocol Traffic" context menu item is toggled.
1958
1959             Dispatch to the array of active tracers at each trace point.
1960             Tracers now get the actual JSON message instead of a stringified
1961             version passed as an argument.
1962
1963         (InspectorBackendClass.prototype.set dumpInspectorProtocolMessages):
1964         (InspectorBackendClass.prototype.get dumpInspectorProtocolMessages):
1965         (InspectorBackendClass.prototype.set dumpInspectorTimeStats):
1966         (InspectorBackendClass.prototype.set customTracer):
1967         (InspectorBackendClass.prototype.get activeTracers):
1968         (InspectorBackendClass.prototype._startOrStopAutomaticTracing):
1969         (InspectorBackendClass.prototype._sendMessageToBackend):
1970         (InspectorBackendClass.prototype._dispatchResponse):
1971         (InspectorBackendClass.prototype._dispatchEvent):
1972         (InspectorBackendClass.prototype.set activeTracer): Deleted.
1973         (InspectorBackendClass.prototype.get activeTracer): Deleted.
1974         * UserInterface/Protocol/LoggingProtocolTracer.js:
1975         (WebInspector.LoggingProtocolTracer.prototype._processEntry):
1976         (WebInspector.LoggingProtocolTracer):
1977         (WebInspector.LoggingProtocolTracer.prototype.logFrontendRequest):
1978         (WebInspector.LoggingProtocolTracer.prototype.logWillHandleResponse):
1979         (WebInspector.LoggingProtocolTracer.prototype.logDidHandleResponse):
1980         (WebInspector.LoggingProtocolTracer.prototype.logWillHandleEvent):
1981         (WebInspector.LoggingProtocolTracer.prototype.logDidHandleEvent):
1982         * UserInterface/Protocol/ProtocolTracer.js:
1983         (WebInspector.ProtocolTracer.prototype.logFrontendException):
1984         (WebInspector.ProtocolTracer.prototype.logProtocolError):
1985         (WebInspector.ProtocolTracer.prototype.logFrontendRequest):
1986         (WebInspector.ProtocolTracer.prototype.logWillHandleResponse):
1987         (WebInspector.ProtocolTracer.prototype.logDidHandleResponse):
1988         (WebInspector.ProtocolTracer.prototype.logWillHandleEvent):
1989         (WebInspector.ProtocolTracer.prototype.logDidHandleEvent):
1990
1991 2016-01-04  Devin Rousso  <dcrousso+webkit@gmail.com>
1992
1993         Web Inspector: Comma separated values in the Visual sidebar are appended with )
1994         https://bugs.webkit.org/show_bug.cgi?id=152653
1995
1996         Reviewed by Timothy Hatcher.
1997
1998         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.js:
1999         (WebInspector.VisualStyleCommaSeparatedKeywordEditor.prototype.set value):
2000         Modified the RexExp used to split the comma separated value to account for strings
2001         with commas inside parenthesis (such as rgba() or hsla()) as well as ones without
2002         commas (such as "arial" and "red").
2003
2004 2016-01-03  Devin Rousso  <dcrousso+webkit@gmail.com>
2005
2006         Web Inspector: Visual sidebar selector section displays inherited section for non-editable rules
2007         https://bugs.webkit.org/show_bug.cgi?id=152659
2008
2009         Reviewed by Brian Burg.
2010
2011         * UserInterface/Views/VisualStyleSelectorSection.js:
2012         (WebInspector.VisualStyleSelectorSection.prototype.update):
2013         Only add a new inherited section header if it will contain at least one inherited rule.
2014
2015 2016-01-02  Devin Rousso  <dcrousso+webkit@gmail.com>
2016
2017         Web Inspector: List all resources that are initiated by the selected resource in the Network tab
2018         https://bugs.webkit.org/show_bug.cgi?id=152647
2019
2020         Reviewed by Timothy Hatcher.
2021
2022         Selecting resources in the Network tab will now display a list of all resources
2023         that the selected resource loaded, allowing for easier understanding of the
2024         relationship between all the resources loaded on a page.
2025
2026         * Localizations/en.lproj/localizedStrings.js:
2027         * UserInterface/Base/Main.js:
2028         Added functions to generate link(s) to Resource instead of SourceCodeLocation.
2029
2030         * UserInterface/Models/Resource.js:
2031         (WebInspector.Resource):
2032         (WebInspector.Resource.prototype.get initiatedResources):
2033         (WebInspector.Resource.prototype.addInitiatedResource):
2034         Each time a resource is added, if it has an initiator, it adds itself to the
2035         initiator's list of initiated resources.
2036
2037         * UserInterface/Views/Main.css:
2038         (.resource-list > .resource-link):
2039         (.resource-list > .resource-link::before):
2040         (.resource-list > .resource-link + .resource-link):
2041         (.resource-link):
2042
2043         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
2044         (WebInspector.ResourceDetailsSidebarPanel):
2045         (WebInspector.ResourceDetailsSidebarPanel.prototype._refreshURL):
2046
2047 2016-01-02  Devin Rousso  <dcrousso+webkit@gmail.com>
2048
2049         Web Inspector: Add list-style properties to Visual Sidebar
2050         https://bugs.webkit.org/show_bug.cgi?id=152631
2051
2052         Reviewed by Timothy Hatcher.
2053
2054         Seeing as lists are very common in web pages across the internet, adding
2055         a section to let users edit the properties unique to lists seems prudent.
2056
2057         * Localizations/en.lproj/localizedStrings.js:
2058         * UserInterface/Images/ListStylePositionInside.svg: Added.
2059         * UserInterface/Images/ListStylePositionOutside.svg: Added.
2060         * UserInterface/Main.html:
2061         Re-added UserInterface/Views/VisualStyleURLInput.js
2062
2063         * UserInterface/Views/VisualStyleDetailsPanel.js:
2064         (WebInspector.VisualStyleDetailsPanel):
2065         (WebInspector.VisualStyleDetailsPanel.prototype._populateListStyleSection):
2066
2067         * UserInterface/Views/VisualStyleKeywordIconList.css:
2068         (.visual-style-property-container.keyword-icon-list > .visual-style-property-value-container > .keyword-icon-list-container > .keyword-icon):
2069         Added specified color property to ensure that :active doesn't break the color of the svg.
2070
2071         (.visual-style-property-container.keyword-icon-list > .visual-style-property-value-container > .keyword-icon-list-container > .keyword-icon:matches(.computed, .selected)):
2072         (.visual-style-property-container.keyword-icon-list > .visual-style-property-value-container > .keyword-icon-list-container > .keyword-icon.selected):
2073         Changed the background-color and border-color values to match the rest of Web Inspector.
2074
2075         * UserInterface/Views/VisualStyleKeywordIconList.js:
2076         (WebInspector.VisualStyleKeywordIconList):
2077         (WebInspector.VisualStyleKeywordIconList.dashToCapital): Deleted.
2078         (WebInspector.VisualStyleKeywordIconList.createListItem):
2079         The "initial" keyword will also use UserInterface/Images/VisualStyleNone.svg
2080
2081         * UserInterface/Views/VisualStyleURLInput.js: Added.
2082         Previously removed in r192705.
2083
2084 2016-01-02  Alberto Garcia  <berto@igalia.com>
2085
2086         [GTK] webkit 2.3.5 build failure with python 3.3.4
2087         https://bugs.webkit.org/show_bug.cgi?id=128971
2088
2089         Reviewed by Michael Catanzaro.
2090
2091         Make sure that the stdin encoding is 'UTF-8' if using Python 3,
2092         otherwise the build will break.
2093
2094         * Scripts/cssmin.py:
2095
2096 2016-01-01  Devin Rousso  <dcrousso+webkit@gmail.com>
2097
2098         Web Inspector: shadow visual sidebar section can be confused with the box shadow section
2099         https://bugs.webkit.org/show_bug.cgi?id=148107
2100
2101         Reviewed by Brian Burg.
2102
2103         * Localizations/en.lproj/localizedStrings.js:
2104         * UserInterface/Views/VisualStyleDetailsPanel.js:
2105         (WebInspector.VisualStyleDetailsPanel):
2106         Changed title of "Shadow" sub-section in "Background" to "Box Shadow".
2107
2108 2016-01-01  Devin Rousso  <dcrousso+webkit@gmail.com>
2109
2110         Web Inspector: The Computed Styles Properties section shows warning icons and doesn't update if collapsed
2111         https://bugs.webkit.org/show_bug.cgi?id=152609
2112
2113         Reviewed by Brian Burg.
2114
2115         * UserInterface/Views/CSSStyleDeclarationTextEditor.js:
2116         (WebInspector.CSSStyleDeclarationTextEditor.prototype._createTextMarkerForPropertyIfNeeded):
2117         If the CodeMirror instance is read-only, don't add any warning icons.
2118
2119         * UserInterface/Views/ComputedStyleDetailsPanel.js:
2120         (WebInspector.ComputedStyleDetailsPanel):
2121         (WebInspector.ComputedStyleDetailsPanel.prototype._handleCollapsedStateChanged):
2122         The properties text editor will now refresh whenever the details section
2123         becomes un-collapsed.
2124
2125         * UserInterface/Views/DetailsSection.js:
2126         (WebInspector.DetailsSection.prototype.set collapsed):
2127         Now fires an event with the current collapsed state as data.
2128
2129 2015-12-31  Matt Baker  <mattbaker@apple.com>
2130
2131         Web Inspector: "No Filter Results" message overlaps Debugger sidebar sections
2132         https://bugs.webkit.org/show_bug.cgi?id=150608
2133
2134         Reviewed by Brian Burg.
2135
2136         * UserInterface/Views/DebuggerSidebarPanel.js:
2137         (WebInspector.DebuggerSidebarPanel.showResourcesWithIssuesOnlyFilterFunction):
2138         Style cleanup.
2139         (WebInspector.DebuggerSidebarPanel):
2140         Add breakpoints tree to the details section before adding Global Breakpoint
2141         elements, since adding them will trigger filtering.
2142         (WebInspector.DebuggerSidebarPanel.prototype._treeSelectionDidChange):
2143         Simplified selection management between the various tree outlines.
2144         (WebInspector.DebuggerSidebarPanel.prototype._updatePauseReasonSection):
2145         Style cleanup.
2146         (WebInspector.DebuggerSidebarPanel.prototype.get hasSelectedElement): Deleted.
2147         Defer to the base class implementation.
2148         (WebInspector.DebuggerSidebarPanel.prototype._treeSelectionDidChange.deselectCallStackContentTreeElements): Deleted.
2149         (WebInspector.DebuggerSidebarPanel.prototype._treeSelectionDidChange.deselectBreakpointContentTreeElements): Deleted.
2150         (WebInspector.DebuggerSidebarPanel.prototype._treeSelectionDidChange.deselectPauseReasonContentTreeElements): Deleted.
2151         These are no longer needed, since the list of visible tree elements list can be used
2152         to manage tree element selection is a more general way.
2153
2154         * UserInterface/Views/NavigationSidebarPanel.css:
2155         Empty content placeholders are now inserted into the DOM as a sibling of the
2156         tree that was filtered. As such, they can be a child of a details section, or
2157         the sidebar's content element.
2158         (.sidebar > .panel.navigation > .content .empty-content-placeholder):
2159         Styles for all empty content placeholders.
2160         (.sidebar > .panel.navigation > .content > .empty-content-placeholder):
2161         Styles for empty content placeholders that fill the sidebar's content element.
2162         (.sidebar > .panel.navigation > .content .message):
2163         Styles for all empty content placeholders.
2164         (.sidebar > .panel.navigation > .empty-content-placeholder): Deleted.
2165         (.sidebar > .panel.navigation > .empty-content-placeholder > .message): Deleted.
2166
2167         * UserInterface/Views/NavigationSidebarPanel.js:
2168         (WebInspector.NavigationSidebarPanel):
2169         Track the tree outline which currently has a selection.
2170         Manage a map of content placeholders
2171         (WebInspector.NavigationSidebarPanel.prototype.set contentTreeOutline):
2172         (WebInspector.NavigationSidebarPanel.prototype.get hasSelectedElement):
2173         Check all visible content trees for a selected element.
2174         (WebInspector.NavigationSidebarPanel.prototype.createContentTreeOutline):
2175         (WebInspector.NavigationSidebarPanel.prototype.treeElementForRepresentedObject):
2176         Check all visible content trees for the represented object.
2177         (WebInspector.NavigationSidebarPanel.prototype.showEmptyContentPlaceholder):
2178         (WebInspector.NavigationSidebarPanel.prototype.hideEmptyContentPlaceholder):
2179         (WebInspector.NavigationSidebarPanel.prototype.updateEmptyContentPlaceholder):
2180         No sidebars currently have more than one filterable content tree outline, but in
2181         the future we will want to support this. Empty content placeholder visibility
2182         is now done per tree outline.
2183         (WebInspector.NavigationSidebarPanel.prototype.show):
2184         Focus the tree outline that most recently had the selection, or the
2185         first tree outline in the visible tree list, if it exists.
2186         (WebInspector.NavigationSidebarPanel.prototype._checkForEmptyFilterResults.checkTreeOutlineForEmptyFilterResults):
2187         Tree is considered filtered if no visible filterable tree elements are found.
2188         (WebInspector.NavigationSidebarPanel.prototype._checkForEmptyFilterResults):
2189         Check all visible trees that support filtering.
2190         (WebInspector.NavigationSidebarPanel.prototype._updateFilter):
2191         Support for filtering multiple content trees.
2192         (WebInspector.NavigationSidebarPanel.prototype._treeElementAddedOrChanged):
2193         Check if the element's tree outline supports filtering, before applying filters.
2194         (WebInspector.NavigationSidebarPanel.prototype._treeSelectionDidChange):
2195         Update the selected tree outline.
2196         (WebInspector.NavigationSidebarPanel.prototype._createEmptyContentPlaceholderIfNeeded):
2197         Create a new empty content placeholder element for the tree.
2198         (WebInspector.NavigationSidebarPanel.prototype.get contentTreeOutlineElement): Deleted.
2199         No longer used.
2200
2201         * UserInterface/Views/TimelineSidebarPanel.js:
2202         (WebInspector.TimelineSidebarPanel.prototype.get hasSelectedElement): Deleted.
2203         Defer to the base class implementation.
2204
2205 2015-12-29  Devin Rousso  <dcrousso+webkit@gmail.com>
2206
2207         Web Inspector: Styling of invalid selector persists when changing the selected node
2208         https://bugs.webkit.org/show_bug.cgi?id=152456
2209
2210         Reviewed by Brian Burg.
2211
2212         If the user changes the selector of a CSS rule to be invalid (e.g. having
2213         a { or ; character), it is expected that the invalid indicator will be removed
2214         once the user changes nodes or reverts the selector to its previous value.
2215
2216         * Localizations/en.lproj/localizedStrings.js:
2217         * UserInterface/Views/CSSStyleDeclarationSection.css:
2218         (.style-declaration-section > .header > .icon.toggle-able:hover):
2219         (.style-declaration-section > .header > .icon.toggle-able:active):
2220         (.style-declaration-section:not(.invalid-selector) > .header > .icon.toggle-able:hover): Deleted.
2221         Added better :hover and :active styles.
2222
2223         * UserInterface/Views/CSSStyleDeclarationSection.js:
2224         (WebInspector.CSSStyleDeclarationSection):
2225         (WebInspector.CSSStyleDeclarationSection.prototype.refresh):
2226         (WebInspector.CSSStyleDeclarationSection.prototype._handleIconElementClicked):
2227         If the selector is invalid, simply refresh the section to regenerate the
2228         original selector with correct content, specificity, and highlighting.
2229
2230         (WebInspector.CSSStyleDeclarationSection.prototype.get _hasInvalidSelector): Deleted.
2231         Moved the state of the invalid selector to a member
2232         variable instead of a DOM class.
2233
2234         (WebInspector.CSSStyleDeclarationSection.prototype._updateSelectorIcon):
2235         Renamed from _markSelector for clarity.
2236
2237         * UserInterface/Views/VisualStyleSelectorTreeItem.css:
2238         (.item.visual-style-selector-item.selector-invalid > .icon:hover):
2239         (.item.visual-style-selector-item.selector-invalid > .icon:active):
2240         (.item.visual-style-selector-item.selector-invalid > .icon):
2241         Added :hover and :active styles.
2242
2243         * UserInterface/Views/VisualStyleSelectorTreeItem.js:
2244         (WebInspector.VisualStyleSelectorTreeItem):
2245         (WebInspector.VisualStyleSelectorTreeItem.prototype.onattach):
2246         (WebInspector.VisualStyleSelectorTreeItem.prototype._commitSelector):
2247         (WebInspector.VisualStyleSelectorTreeItem.prototype._updateSelectorIcon):
2248         (WebInspector.VisualStyleSelectorTreeItem.prototype._handleIconElementClicked):
2249         (WebInspector.VisualStyleSelectorTreeItem.prototype._selectorChanged): Deleted.
2250         Changed the names of a few functions to provide better
2251         consistency across the classes in the Style sidebar.
2252
2253 2015-12-27  Brian Burg  <bburg@apple.com>
2254
2255         Web Inspector: improve pre-filled bugzilla link on Uncaught Exception reporter sheet
2256         https://bugs.webkit.org/show_bug.cgi?id=152402
2257
2258         Reviewed by Joseph Pecoraro.
2259
2260         Include the UA string, inspected page URL, and a template that includes
2261         steps to reproduce and notes. Other common headings (regression, expected,
2262         results, summary) are omitted because they are unlikely to be known when
2263         an uncaught exception occurs, or are obvious ("shouldn't throw exception").
2264
2265         * UserInterface/Debug/UncaughtExceptionReporter.js:
2266
2267 2015-12-21  Nikita Vasilyev  <nvasilyev@apple.com>
2268
2269         WebInspector: Can't open a new tab: Uncaught Exception: TypeError: this.isNewTabWithTypeAllowed is not a function
2270         https://bugs.webkit.org/show_bug.cgi?id=152471
2271
2272         Reviewed by Timothy Hatcher.
2273
2274         * UserInterface/Base/Main.js:
2275         (WebInspector._updateNewTabButtonState):
2276         Don't use arrow functions because of https://webkit.org/b/152497 "Arrow functions: 'this' isn't lexically bound"
2277
2278 2015-12-21  Nikita Vasilyev  <nvasilyev@apple.com>
2279
2280         Web Inspector: Remove unused WebInspector.Object.removeAllListeners
2281         https://bugs.webkit.org/show_bug.cgi?id=152474
2282
2283         Reviewed by Timothy Hatcher.
2284
2285         * UserInterface/Base/Object.js:
2286         (WebInspector.Object.removeAllListeners): Deleted.
2287         (WebInspector.Object.prototype.removeAllListeners): Deleted.
2288
2289 2015-12-20  Dan Bernstein  <mitz@apple.com>
2290
2291         Remove unused setToolbarHeight
2292         https://bugs.webkit.org/show_bug.cgi?id=152466
2293
2294         Reviewed by Darin Adler.
2295
2296         * UserInterface/Base/Main.js:
2297         (WebInspector.contentLoaded):
2298         * UserInterface/Protocol/InspectorFrontendHostStub.js:
2299         (window.InspectorFrontendHost.WebInspector.InspectorFrontendHostStub.prototype.setToolbarHeight): Deleted.
2300
2301 2015-12-19  Dan Bernstein  <mitz@apple.com>
2302
2303         [Mac] WebKit contains dead source code for OS X Mavericks and earlier
2304         https://bugs.webkit.org/show_bug.cgi?id=152462
2305
2306         Reviewed by Alexey Proskuryakov.
2307
2308         - Removed build setting definitions for OS X 10.9 and earlier, and simplified defintions
2309           that became uniform across all OS X versions as a result:
2310
2311         * Configurations/Base.xcconfig:
2312         * Configurations/DebugRelease.xcconfig:
2313         * Configurations/Version.xcconfig:
2314
2315         * Scripts/copy-user-interface-resources.pl: Removed code to delete Images/Legacy.
2316
2317         * UserInterface/Images/Legacy: Removed this empty directory.
2318
2319 2015-12-18  Matt Baker  <mattbaker@apple.com>
2320
2321         Web Inspector: Make it possible to debug injected scripts when the Debug UI is enabled
2322         https://bugs.webkit.org/show_bug.cgi?id=152445
2323
2324         Reviewed by Joseph Pecoraro.
2325
2326         * UserInterface/Base/Main.js:
2327         Added function to check for debug UI.
2328
2329         * UserInterface/Base/Object.js:
2330         Added notification for debug UI enabled state change.
2331
2332         * UserInterface/Base/Utilities.js:
2333         (isWebInspectorInternalScript):
2334         (isWebInspectorDebugScript):
2335         Added functions to check for internal and debug inspector scripts.
2336
2337         * UserInterface/Controllers/DebuggerManager.js:
2338         (WebInspector.DebuggerManager):
2339         Maintain a list of inspector debug scripts, so that the manager can
2340         add and remove them when the debug UI is enabled/disabled.
2341         (WebInspector.DebuggerManager.prototype.get knownNonResourceScripts):
2342         (WebInspector.DebuggerManager.prototype.reset):
2343         Clear the list of inspector debug scripts.
2344         (WebInspector.DebuggerManager.prototype.debuggerDidPause):
2345         (WebInspector.DebuggerManager.prototype.scriptDidParse):
2346         Skip internal inspector scripts. Debug inspector scripts are tracked,
2347         and an added event is dispatched if the debug UI is enabled.
2348         (WebInspector.DebuggerManager.prototype._debugUIEnabledDidChange):
2349         Dispatch added/removed events for inspector debug scripts.
2350
2351         * UserInterface/Debug/Bootstrap.js:
2352         (WebInspector.runBootstrapOperations):
2353         Expose changes to the debug UI setting to the reset of the UI, by dispatching
2354         a WebInspector.Notification.DebugUIEnabledDidChange event.
2355
2356         * UserInterface/Protocol/RemoteObject.js:
2357         (WebInspector.RemoteObject.prototype.findFunctionSourceCodeLocation):
2358         Only resolve inspector debug source locations when the debug UI is enabled.
2359
2360         * UserInterface/Test/Test.js:
2361         Reimplemented debug UI check for tests. Always returns false.
2362
2363         * UserInterface/Views/DebuggerSidebarPanel.js:
2364         (WebInspector.DebuggerSidebarPanel.prototype._addScript):
2365         Removed check for inspector debug scripts. DebuggerManager filters scripts as needed.
2366         (WebInspector.DebuggerSidebarPanel.prototype._scriptRemoved):
2367         Handle DebuggerManager ScriptRemoved events. Only applies to debug scripts.
2368
2369         * UserInterface/Views/ResourceSidebarPanel.js:
2370         (WebInspector.ResourceSidebarPanel):
2371         (WebInspector.ResourceSidebarPanel.prototype._scriptWasRemoved):
2372         Handle DebuggerManager ScriptRemoved events. Only applies to debug scripts.
2373         (WebInspector.ResourceSidebarPanel.prototype._scriptWasAdded):
2374         Removed check for inspector debug scripts. DebuggerManager filters scripts as needed.
2375
2376 2015-12-17  Joseph Pecoraro  <pecoraro@apple.com>
2377
2378         Web Inspector: Remove "local" scope type from the protocol
2379         https://bugs.webkit.org/show_bug.cgi?id=152409
2380
2381         Reviewed by Timothy Hatcher.
2382
2383         * UserInterface/Controllers/DebuggerManager.js:
2384         (WebInspector.DebuggerManager.prototype._scopeChainNodeFromPayload):
2385
2386 2015-12-17  Joseph Pecoraro  <pecoraro@apple.com>
2387
2388         Web Inspector: CSS warning's fake CallFrame is not creating a valid payload
2389         https://bugs.webkit.org/show_bug.cgi?id=152413
2390
2391         Reviewed by Timothy Hatcher.
2392
2393         * UserInterface/Views/ConsoleMessageView.js:
2394         (WebInspector.ConsoleMessageView.prototype._appendLocationLink):
2395         This attempts to create a CallFrame from a Console.CallFrame payload,
2396         but this was missing the required functionName string parameter.
2397
2398 2015-12-17  Joseph Pecoraro  <pecoraro@apple.com>
2399
2400         Provide a way to distinguish a nested lexical block from a function's lexical block
2401         https://bugs.webkit.org/show_bug.cgi?id=152361
2402
2403         Reviewed by Saam Barati.
2404
2405         * Localizations/en.lproj/localizedStrings.js:
2406         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
2407         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
2408         New "Block Variables" string.
2409
2410         * UserInterface/Models/ScopeChainNode.js:
2411         New "Block" scope type, and update existing types.
2412
2413         * UserInterface/Controllers/DebuggerManager.js:
2414         (WebInspector.DebuggerManager.prototype._scopeChainNodeFromPayload):
2415         Parse the protocol type to frontend types. Use the protocol generated enum.
2416
2417 2015-12-17  Joseph Pecoraro  <pecoraro@apple.com>
2418
2419         Web Inspector: Improve names in Debugger Call Stack section when paused
2420         https://bugs.webkit.org/show_bug.cgi?id=152398
2421
2422         Reviewed by Brian Burg.
2423
2424         * UserInterface/Controllers/DebuggerManager.js:
2425         (WebInspector.DebuggerManager.prototype.debuggerDidPause):
2426         Use a new fromPayload helper to construct the CallFrame and share code.
2427
2428         * UserInterface/Models/CallFrame.js:
2429         (WebInspector.CallFrame.functionNameFromPayload):
2430         (WebInspector.CallFrame.programCodeFromPayload):
2431         (WebInspector.CallFrame.fromDebuggerPayload):
2432         (WebInspector.CallFrame.fromPayload):
2433         Add a new way to construct a call frame. There are two kinds of
2434         CallFrame payloads in the protocol:
2435         - Debugger.CallFrame, this new path
2436         - Console.CallFrame, the pre-existing path
2437
2438 2015-12-17  Brian Burg  <bburg@apple.com>
2439
2440         Web Inspector: control whether to collect and dump protocol messages using a WebInspector.Setting
2441         https://bugs.webkit.org/show_bug.cgi?id=151635
2442
2443         Reviewed by Joseph Pecoraro.
2444
2445         Follow-up fix to stop double-logging everything.
2446
2447         * UserInterface/Protocol/LoggingProtocolTracer.js:
2448         (WebInspector.LoggingProtocolTracer.prototype._processEntry):
2449
2450 2015-12-17  Joseph Pecoraro  <pecoraro@apple.com>
2451
2452         Web Inspector: Improve console.trace, make it more like console.assert and inline the message
2453         https://bugs.webkit.org/show_bug.cgi?id=152352
2454
2455         Reviewed by Timothy Hatcher.
2456
2457         * Localizations/en.lproj/localizedStrings.js:
2458         New "Trace" related strings.
2459
2460         * UserInterface/Views/ConsoleMessageView.js:
2461         (WebInspector.ConsoleMessageView.prototype.expand):
2462         Since we auto-expand Trace messages for their Call Stack, don't also
2463         auto-expand a single inner object, which may be big and push the
2464         actual stack trace off the screen.
2465         
2466         (WebInspector.ConsoleMessageView.prototype._appendMessageTextAndArguments):
2467         Behave like Assert messages and absorb a message string, and include
2468         extra arguments gracefully.
2469
2470         (WebInspector.ConsoleMessageView.prototype._appendFormattedArguments):
2471         For expandable messages with simple extra arguments (console.trace with
2472         primitives and backtrace, or console.assert with primitives and backtrace)
2473         we were hiding the inline lossless previews and not showing them as a
2474         bulleted list below. We can just keep the lossless previews inline in the
2475         title, since they were only put there because they are small and lossless.
2476
2477         (WebInspector.ConsoleMessageView.prototype.toClipboardString):
2478         No need to hard code "console.trace()" in the clipboard.
2479
2480         * UserInterface/Views/ConsoleMessageView.css:
2481         (.console-message.expandable.expanded :matches(.console-message-preview, .console-message-preview-divider):not(.inline-lossless)):
2482         (.console-message.expandable.expanded :matches(.console-message-preview, .console-message-preview-divider)): Deleted.
2483         Don't hide the inline lossless preview in the console message title when it is inline-lossless.
2484
2485         * UserInterface/Views/ObjectTreeView.js:
2486         (WebInspector.ObjectTreeView.prototype.expand):
2487         Do not allow expanding a loss-less preview.
2488
2489 2015-12-16  Joseph Pecoraro  <pecoraro@apple.com>
2490
2491         Web Inspector: Add JSContext Script Profiling
2492         https://bugs.webkit.org/show_bug.cgi?id=151899
2493
2494         Reviewed by Brian Burg.
2495
2496         Enable the Timeline tab for JSContext inspection. Currently only
2497         JSContext inspection will use the ScriptProfiler domain, it will
2498         be enabled for Page inspection in a follow-up.
2499
2500         First pass at the UI creates basic ScriptTimelineRecords for
2501         ScriptProfiler events. At the end of recording, when profiles
2502         are downloaded, it attaches profiles to the timeline records
2503         and refreshes the Scripts timeline.
2504
2505         * UserInterface/Base/Main.js:
2506         (WebInspector.loaded):
2507         * UserInterface/Controllers/TimelineManager.js:
2508         (WebInspector.TimelineManager):
2509         (WebInspector.TimelineManager.defaultInstruments):
2510         (WebInspector.TimelineManager.prototype.computeElapsedTime):
2511         (WebInspector.TimelineManager.prototype.scriptProfilerIsTracking):
2512         (WebInspector.TimelineManager.prototype._loadNewRecording):
2513         (WebInspector.TimelineManager.prototype._mainResourceDidChange):
2514         (WebInspector.TimelineManager.prototype._resourceWasAdded):
2515         (WebInspector.TimelineManager.prototype._garbageCollected):
2516         (WebInspector.TimelineManager.prototype._addRecord): Deleted.
2517         * UserInterface/Main.html:
2518         * UserInterface/Models/Instrument.js:
2519         (WebInspector.Instrument.startLegacyTimelineAgent):
2520         * UserInterface/Models/ScriptInstrument.js:
2521         (WebInspector.ScriptInstrument.prototype.startInstrumentation):
2522         (WebInspector.ScriptInstrument.prototype.stopInstrumentation):
2523         (WebInspector.ScriptInstrument):
2524         * UserInterface/Models/ScriptTimelineRecord.js:
2525         (WebInspector.ScriptTimelineRecord.prototype.get profilePayload):
2526         (WebInspector.ScriptTimelineRecord.prototype._initializeProfileFromPayload):
2527         (WebInspector.ScriptTimelineRecord):
2528         (WebInspector.ScriptTimelineRecord.EventType.displayName):
2529         * UserInterface/Models/Timeline.js:
2530         (WebInspector.Timeline.prototype.refresh):
2531         * UserInterface/Models/TimelineRecording.js:
2532         (WebInspector.TimelineRecording.sourceCodeTimelinesSupported):
2533         (WebInspector.TimelineRecording.prototype.timelineForRecordType):
2534         (WebInspector.TimelineRecording.prototype.addRecord):
2535         * UserInterface/Protocol/ScriptProfilerObserver.js: Copied from Source/WebInspectorUI/UserInterface/Models/ScriptInstrument.js.
2536         (WebInspector.ScriptProfilerObserver.prototype.trackingStart):
2537         (WebInspector.ScriptProfilerObserver.prototype.trackingUpdate):
2538         (WebInspector.ScriptProfilerObserver.prototype.trackingComplete):
2539         (WebInspector.ScriptProfilerObserver):
2540         * UserInterface/Views/ScriptTimelineView.js:
2541         (WebInspector.ScriptTimelineView):
2542         (WebInspector.ScriptTimelineView.prototype._processPendingRecords):
2543         (WebInspector.ScriptTimelineView.prototype._scriptTimelineRecordRefreshed):
2544         * UserInterface/Views/TimelineRecordTreeElement.js:
2545         (WebInspector.TimelineRecordTreeElement):
2546         * UserInterface/Views/TimelineTabContentView.js:
2547         (WebInspector.TimelineTabContentView.isTabAllowed):
2548
2549 2015-12-17  Matt Baker  <mattbaker@apple.com>
2550
2551         Web Inspector: REGRESSION (r193913): Popover covers completion suggestions
2552         https://bugs.webkit.org/show_bug.cgi?id=152369
2553
2554         Reviewed by Timothy Hatcher.
2555
2556         * UserInterface/Views/Variables.css:
2557         (:root):
2558         Swap popover and tooltip z-index ordering.
2559
2560 2015-12-16  Joseph Pecoraro  <pecoraro@apple.com>
2561
2562         REGRESSION: Web Inspector: console.dir(...) should force allowing object expansion
2563         https://bugs.webkit.org/show_bug.cgi?id=152328
2564
2565         Reviewed by Timothy Hatcher.
2566
2567         * UserInterface/Views/ConsoleMessageView.js:
2568         (WebInspector.ConsoleMessageView.prototype._formatParameter):
2569         Propogate the force parameter down.
2570
2571 2015-12-16  Joseph Pecoraro  <pecoraro@apple.com>
2572
2573         Web Inspector: Improve copy of console messages with multiple arguments - console.log(obj1, obj2)
2574         https://bugs.webkit.org/show_bug.cgi?id=152330
2575
2576         Reviewed by Timothy Hatcher.
2577
2578         * UserInterface/Views/ConsoleMessageView.js:
2579         (WebInspector.ConsoleMessageView.prototype.toClipboardString):
2580         Copy the inner text of the extra arguments list as well, for
2581         console messages with multiple objects. Rearrange the sections
2582         that, if there is a stack trace it comes at the end after
2583         multiple arguments. If there is no stack trace, include the
2584         location info next to the top line, before multiple arguments.
2585
2586 2015-12-16  Joseph Pecoraro  <pecoraro@apple.com>
2587
2588         Web Inspector: Improve copy of console message containing Array and Map output
2589         https://bugs.webkit.org/show_bug.cgi?id=152329
2590
2591         Reviewed by Timothy Hatcher.
2592
2593         Introduce a real space in the content instead of style specific
2594         margins so the existing copy/paste mechanism (innerText)
2595         will have spaces between index/key and value.
2596
2597         * UserInterface/Views/ObjectTreeArrayIndexTreeElement.css:
2598         (.object-tree-array-index .index-name): Deleted.
2599         * UserInterface/Views/ObjectTreeArrayIndexTreeElement.js:
2600         (WebInspector.ObjectTreeArrayIndexTreeElement.prototype._titleFragment):
2601         (WebInspector.ObjectTreeArrayIndexTreeElement):
2602         * UserInterface/Views/ObjectTreeMapEntryTreeElement.css:
2603         (.object-tree-array-index.object-tree-map-entry > .titles > .title > .index-name): Deleted.
2604         * UserInterface/Views/ObjectTreeMapEntryTreeElement.js:
2605         (WebInspector.ObjectTreeMapEntryTreeElement.prototype.titleFragment):
2606         (WebInspector.ObjectTreeMapEntryTreeElement):
2607         * UserInterface/Views/ObjectTreeSetIndexTreeElement.js:
2608         (WebInspector.ObjectTreeSetIndexTreeElement.prototype._titleFragment):
2609         (WebInspector.ObjectTreeSetIndexTreeElement):
2610
2611 2015-12-16  Joseph Pecoraro  <pecoraro@apple.com>
2612
2613         Web Inspector: Typing object literal in the console causes a parse error
2614         https://bugs.webkit.org/show_bug.cgi?id=141737
2615
2616         Reviewed by Timothy Hatcher.
2617
2618         Provide a convenience in console evaluations for JSON object like input.
2619         If the console input starts with '{' and ends with '}' wrap the input
2620         in parenthesis to force evaluation as an expression.
2621
2622         For example, input "{a:1}" would be convenience wrapped to "({a:1})"
2623         and produce the expected object. This helps avoid the unusual treatment
2624         of "{a:1}" as program containing a labeled statement, which is often
2625         not what the user expects. And in more realistic cases, like "{a:1, b:2}",
2626         produce a SyntaxError.
2627
2628         * UserInterface/Controllers/RuntimeManager.js:
2629         (WebInspector.RuntimeManager.prototype.evaluateInInspectedWindow):
2630         Detect and convenience wrap the given expression.
2631
2632 2015-12-16  Joseph Pecoraro  <pecoraro@apple.com>
2633
2634         Uncaught Exception View has undefined exception URL
2635         https://bugs.webkit.org/show_bug.cgi?id=152327
2636
2637         Reviewed by Darin Adler.
2638
2639         * UserInterface/Debug/UncaughtExceptionReporter.js:
2640         (handleUncaughtException):
2641         Use ErrorEvent's filename property, not url which is undefined.
2642
2643 2015-12-16  Joseph Pecoraro  <pecoraro@apple.com>
2644
2645         Uncaught Exception: ReferenceError: Can't find variable: resolvedValue
2646         https://bugs.webkit.org/show_bug.cgi?id=152326
2647
2648         Reviewed by Darin Adler.
2649
2650         * UserInterface/Views/ObjectTreeBaseTreeElement.js:
2651         (WebInspector.ObjectTreeBaseTreeElement.prototype._contextMenuHandler):
2652         This identifier is used later on, so assign it here.
2653
2654 2015-12-15  Joseph Pecoraro  <pecoraro@apple.com>
2655
2656         Web Inspector: Localize "global code" and "eval code" strings
2657         https://bugs.webkit.org/show_bug.cgi?id=152313
2658
2659         Reviewed by Timothy Hatcher.
2660
2661         * Localizations/en.lproj/localizedStrings.js:
2662         * UserInterface/Models/CallFrame.js:
2663         (WebInspector.CallFrame.fromPayload):
2664         Localize the strings given to use from the backend.
2665
2666 2015-12-15  Matt Baker  <mattbaker@apple.com>
2667
2668         Web Inspector: Convert Sidebar classes to use View
2669         https://bugs.webkit.org/show_bug.cgi?id=152274
2670
2671         Reviewed by Brian Burg.
2672
2673         Updated Sidebar and SidebarPanel to inherit from View. Mostly mechanical changes.
2674         Once the DetailsSection class family inherits from View (https://webkit.org/b/152269),
2675         directly modifying a sidebar's 'contentView' element will rarely be necessary.
2676
2677         * UserInterface/Views/ApplicationCacheDetailsSidebarPanel.js:
2678         (WebInspector.ApplicationCacheDetailsSidebarPanel):
2679
2680         * UserInterface/Views/CSSStyleDetailsSidebarPanel.js:
2681         (WebInspector.CSSStyleDetailsSidebarPanel):
2682         (WebInspector.CSSStyleDetailsSidebarPanel.prototype.refresh):
2683         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._switchPanels):
2684         Add/remove panels as subviews of the sidebar.
2685         (WebInspector.CSSStyleDetailsSidebarPanel.prototype._filterDidChange):
2686
2687         * UserInterface/Views/DOMNodeDetailsSidebarPanel.js:
2688         (WebInspector.DOMNodeDetailsSidebarPanel):
2689
2690         * UserInterface/Views/DebuggerSidebarPanel.js:
2691         (WebInspector.DebuggerSidebarPanel):
2692         (WebInspector.DebuggerSidebarPanel.prototype._debuggerDidPause):
2693
2694         * UserInterface/Views/LayerTreeDetailsSidebarPanel.js:
2695         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._buildLayerInfoSection):
2696         (WebInspector.LayerTreeDetailsSidebarPanel.prototype._buildDataGridSection):
2697
2698         * UserInterface/Views/NavigationSidebarPanel.js:
2699         (WebInspector.NavigationSidebarPanel):
2700         (WebInspector.NavigationSidebarPanel.prototype.createContentTreeOutline):
2701         (WebInspector.NavigationSidebarPanel.prototype._updateContentOverflowShadowVisibility):
2702
2703         * UserInterface/Views/ProbeDetailsSidebarPanel.js:
2704         (WebInspector.ProbeDetailsSidebarPanel.prototype.set inspectedProbeSets):
2705
2706         * UserInterface/Views/ResourceDetailsSidebarPanel.js:
2707         (WebInspector.ResourceDetailsSidebarPanel):
2708         (WebInspector.ResourceDetailsSidebarPanel.prototype._refreshURL):
2709         (WebInspector.ResourceDetailsSidebarPanel.prototype._refreshImageSizeSection):
2710         (WebInspector.ResourceDetailsSidebarPanel.prototype._refreshRequestDataSection):
2711
2712         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
2713         (WebInspector.ScopeChainDetailsSidebarPanel):
2714         (WebInspector.ScopeChainDetailsSidebarPanel.prototype.refresh.):
2715         (WebInspector.ScopeChainDetailsSidebarPanel.prototype.refresh):
2716
2717         * UserInterface/Views/SidebarPanel.js:
2718         Inherit from View.
2719         (WebInspector.SidebarPanel):
2720         Replace the content element (the portion of the view excluding navigation
2721         bars, filter bars, etc.) with a View object. A sidebar's content can be a mixture
2722         of unwrapped DOM elements and View objects. For now, the content view's element
2723         will be mutated directly, but once the DetailsSection class family inherits from
2724         the View class the handling of details sections will be simplified.
2725         (WebInspector.SidebarPanel.prototype.get contentView):
2726         (WebInspector.SidebarPanel.prototype.shown):
2727         (WebInspector.SidebarPanel.prototype.hidden):
2728         (WebInspector.SidebarPanel.prototype.get contentElement): Deleted.
2729         Replaced by WebInspector.SidebarPanel.prototype.get contentView.
2730
2731         * UserInterface/Views/StyleDetailsPanel.js:
2732         Inherit from View.
2733         (WebInspector.StyleDetailsPanel):
2734         (WebInspector.StyleDetailsPanel.prototype.get element): Deleted.
2735         Defer to View.element getter.
2736
2737         * UserInterface/Views/TimelineSidebarPanel.js:
2738         (WebInspector.TimelineSidebarPanel.prototype._updateTimelineOverviewHeight):
2739
2740         * UserInterface/Views/VisualStyleDetailsPanel.js:
2741         (WebInspector.VisualStyleDetailsPanel):
2742         (WebInspector.VisualStyleDetailsPanel.prototype._updateSections):
2743
2744 2015-12-14  Joseph Pecoraro  <pecoraro@apple.com>
2745
2746         Web Inspector: Stack traces in console incorrectly show "(anonymous function)" for global code
2747         https://bugs.webkit.org/show_bug.cgi?id=152280
2748
2749         Reviewed by Brian Burg.
2750
2751         * UserInterface/Images/Program.svg: Added.
2752         * UserInterface/Images/gtk/Program.svg: Added.
2753         Copied from TimelineRecordScriptEvaluated.svg.
2754
2755         * UserInterface/Models/CallFrame.js:
2756         (WebInspector.CallFrame):
2757         (WebInspector.CallFrame.prototype.get programCode):
2758         Add a new property to check if this call frame is in program code.
2759
2760         (WebInspector.CallFrame.fromPayload):
2761         Detect different sources of program code (global, eval, module).
2762
2763         * UserInterface/Views/CallFrameIcons.css:
2764         (.program-icon .icon):
2765         * UserInterface/Views/CallFrameView.js:
2766         (WebInspector.CallFrameView.iconClassNameForCallFrame):
2767         Give program code the [S] global script icon like in profiles.
2768
2769 2015-12-14  Joseph Pecoraro  <pecoraro@apple.com>
2770
2771         Web Inspector: Copy message from console with a stack trace does not include source code locations
2772         https://bugs.webkit.org/show_bug.cgi?id=152270
2773
2774         Reviewed by Timothy Hatcher.
2775
2776         * UserInterface/Views/ConsoleMessageView.js:
2777         (WebInspector.ConsoleMessageView.prototype.toClipboardString):
2778         When the the StackTrace was upgraded to a real collection of CallFrame
2779         object's the CallFrame's got real SourceCodeLocation properties.
2780
2781 2015-12-13  Matt Baker  <mattbaker@apple.com>
2782
2783         Web Inspector: Make TimelineOverview's graph container a subview
2784         https://bugs.webkit.org/show_bug.cgi?id=152235
2785
2786         Reviewed by Brian Burg.
2787
2788         * UserInterface/Views/TimelineOverview.js:
2789         (WebInspector.TimelineOverview):
2790         Create graph container subview.
2791         (WebInspector.TimelineOverview.prototype._instrumentAdded):
2792         Add overview to the graph container view.
2793         (WebInspector.TimelineOverview.prototype._instrumentRemoved):
2794         Remove overview from the graph container view.
2795         (WebInspector.TimelineOverview.prototype.layout):
2796         No longer necessary to manually lay out overview graphs.
2797         (WebInspector.TimelineOverview.prototype._needsLayout): Deleted.
2798         Removed dead code.
2799
2800 2015-12-12  Matt Baker  <mattbaker@apple.com>
2801
2802         Web Inspector: CodeMirrorTokenTrackingController handles symbols in class definitions incorrectly
2803         https://bugs.webkit.org/show_bug.cgi?id=152218
2804
2805         Reviewed by Timothy Hatcher.
2806
2807         * UserInterface/Controllers/CodeMirrorTokenTrackingController.js:
2808         (WebInspector.CodeMirrorTokenTrackingController.prototype._processJavaScriptExpression):
2809         Stop checking for object literal shorthand property if an open parenthesis is found.
2810         This check became necessary with the introduction of ES6 class syntax.
2811
2812         * UserInterface/Views/CodeMirrorAdditions.js:
2813         Use localState when available, to prevent passing a state that doesn't define a tokenize property.
2814
2815 2015-12-12  Joseph Pecoraro  <pecoraro@apple.com>
2816
2817         REGRESSION (r191613): Web Inspector: Can't type spaces when editing DOM nodes
2818         https://bugs.webkit.org/show_bug.cgi?id=152173
2819
2820         Reviewed by Timothy Hatcher.
2821
2822         * UserInterface/Views/TimelineSidebarPanel.js:
2823         (WebInspector.TimelineSidebarPanel):
2824         Disable the keyboard shortcuts when they are created. They will be
2825         enabled when the panel is shown / hidden. It doesn't really make sense
2826         that these are on the sidebar panel instead of the tab, but things
2827         will be changing in Timelines soon anyways so just fix this now.
2828
2829 2015-12-12  Nikita Vasilyev  <nvasilyev@apple.com>
2830
2831         Web Inspector: "Selected Element" should use sans-serif font, not monospace
2832         https://bugs.webkit.org/show_bug.cgi?id=152212
2833
2834         Reviewed by Timothy Hatcher.
2835
2836         * UserInterface/Views/ConsoleMessageView.css:
2837         (.console-user-command.special-user-log > .console-message-text):
2838
2839 2015-12-11  Nikita Vasilyev  <nvasilyev@apple.com>
2840
2841         Web Inspector: When logging strings, detect stack traces and show them as StackTraceView
2842         https://bugs.webkit.org/show_bug.cgi?id=149790
2843
2844         Reviewed by Timothy Hatcher.
2845
2846         * UserInterface/Models/StackTrace.js:
2847         (WebInspector.StackTrace.isLikelyStackTrace): Added.
2848
2849         * UserInterface/Views/ConsoleMessageView.css:
2850         (.console-message-extra-parameter .stack-trace):
2851         Display stack trace view on the same line as a list bullet point from
2852         console message extra parameter.
2853
2854         * UserInterface/Views/ConsoleMessageView.js:
2855         (WebInspector.ConsoleMessageView.prototype._appendFormattedArguments):
2856         Don't format with string substitutions for stack traces. E.g. there is
2857         no need to replace %s with the next argument.
2858
2859         (WebInspector.ConsoleMessageView.prototype._isStackTrace): Added.
2860         (WebInspector.ConsoleMessageView.prototype._formatParameterAsString):
2861         Detect stack traces and format them appropriately.
2862
2863 2015-12-10  Nikita Vasilyev  <nvasilyev@apple.com>
2864
2865         Web Inspector: debugger dashboard's switching arrows are positioned too close to the dashboard border
2866         https://bugs.webkit.org/show_bug.cgi?id=151867
2867
2868         Reviewed by Timothy Hatcher.
2869
2870         * UserInterface/Views/DashboardContainerView.css:
2871         (.dashboard-container .advance-arrow):
2872
2873 2015-12-10  Matt Baker  <mattbaker@apple.com>
2874
2875         Web Inspector: debugger popover should have source location link when showing function source
2876         https://bugs.webkit.org/show_bug.cgi?id=151866
2877
2878         Reviewed by Brian Burg.
2879
2880         Added source code location link to function popover header.
2881
2882         * UserInterface/Views/SourceCodeTextEditor.js:
2883         (WebInspector.SourceCodeTextEditor.prototype._showPopoverForFunction.didGetDetails):
2884         Create source code location link from response payload.
2885         (WebInspector.SourceCodeTextEditor.prototype._showPopoverForFunction):
2886
2887 2015-12-10  Nikita Vasilyev  <nvasilyev@apple.com>
2888
2889         Web Inspector: [Meta] Unify z-index values in Inspector's CSS
2890         https://bugs.webkit.org/show_bug.cgi?id=151978
2891
2892         Introduce CSS variables for z-index due to recurring issues with incorrectly overlapping elements.
2893
2894         From now on, all z-index values >= 64 must be defined as variables.
2895         Values below 64 must not.
2896
2897         Reviewed by Timothy Hatcher.
2898
2899         * UserInterface/Views/Variables.css:
2900         (:root):
2901         Introduce z-index variables.
2902
2903         * UserInterface/Debug/UncaughtExceptionReporter.css:
2904         (.sheet-container):
2905         * UserInterface/Views/BoxModelDetailsSectionRow.css:
2906         (.details-section .row.box-model .editing):
2907         * UserInterface/Views/CompletionSuggestionsView.css:
2908         (.completion-suggestions):
2909         * UserInterface/Views/DashboardContainerView.css:
2910         (.dashboard-container .advance-arrow):
2911         * UserInterface/Views/DataGrid.css:
2912         (.data-grid .resizer):
2913         * UserInterface/Views/DetailsSection.css:
2914         (.details-section > .header):
2915         (.details-section .details-section > .header):
2916         * UserInterface/Views/FindBanner.css:
2917         (.find-banner):
2918         (.find-banner > button.segmented:active):
2919         * UserInterface/Views/Main.css:
2920         (#docked-resizer):
2921         (.message-text-view):
2922         (.bouncy-highlight):
2923         * UserInterface/Views/Popover.css:
2924         (.popover):
2925         * UserInterface/Views/Resizer.css:
2926         (.resizer):
2927         (.glass-pane-for-drag):
2928         * UserInterface/Views/TimelineOverview.css:
2929         (.timeline-overview > .scroll-container):
2930         * UserInterface/Views/VisualStyleSelectorSection.css:
2931         (.details-section.visual-style-selector-section > .content > .selectors > .selector-list > .section-divider):
2932
2933 2015-12-09  Matt Baker  <mattbaker@apple.com>
2934
2935         Web Inspector: when a marked-dirty subview is attached to a parent View, dirtyDescendantsCount gets out of sync
2936         https://bugs.webkit.org/show_bug.cgi?id=151876
2937
2938         Reviewed by Brian Burg.
2939
2940         * UserInterface/Base/Main.js:
2941         Use root view singleton instead of creating it explicitly.
2942
2943         * UserInterface/Views/View.js:
2944         (WebInspector.View):
2945         (WebInspector.View.rootView):
2946         Singleton root view access. Lazily create and return a view backed
2947         by the document's body element.
2948         (WebInspector.View.prototype.isDescendantOf):
2949         (WebInspector.View.prototype.insertSubviewBefore):
2950         (WebInspector.View.prototype.removeSubview):
2951         (WebInspector.View.prototype.didMoveToWindow):
2952         Notify the view when it becomes, or is no longer, descended from the root view.
2953         (WebInspector.View.prototype.didMoveToParent):
2954         Notify the view when it's added to, or removed from, a parent view.
2955         (WebInspector.View._scheduleLayoutForView):
2956         (WebInspector.View._cancelScheduledLayoutForView):
2957         (WebInspector.View.prototype.makeRootView): Deleted.
2958         No longer needed.
2959         (WebInspector.View.prototype.didAttach): Deleted.
2960         (WebInspector.View.prototype.didDetach): Deleted.
2961         Replaced by didMoveToParent.
2962
2963 2015-12-09  Brian Burg  <bburg@apple.com>
2964
2965         Web Inspector: control whether to collect and dump protocol messages using a WebInspector.Setting
2966         https://bugs.webkit.org/show_bug.cgi?id=151635
2967
2968         Reviewed by Timothy Hatcher.
2969
2970         When closing and reopening the inspector, the setting for whether
2971         to dump protocol messages should be persisted. Otherwise, enabling
2972         dumping from the debug-only UI will miss the initial flood of
2973         messages that are processed when the Inspector loads initial data.
2974
2975         To support a persistent setting, and build some infrastructure for
2976         more advanced uses of collected protocol messages, this patch adds
2977         a new object to trace protocol events. It gets callbacks for each
2978         and implements the console-dumping functionality previously baked in
2979         to InspectorBackend.
2980
2981         In follow-up patches, other protocol tracers will be added to save
2982         protocol data to disk, marshall it to a higher inspection level,
2983         or provide more fine-grained control over what is logged.
2984
2985         This change moves Setting.js into the Base/ directory,
2986         since it is used by Views, Models, and now Protocol classes.
2987
2988         * UserInterface/Base/Setting.js: Renamed from Source/WebInspectorUI/UserInterface/Models/Setting.js.
2989         (WebInspector.Setting):
2990         (WebInspector.Setting.prototype.get name):
2991         (WebInspector.Setting.prototype.get value):
2992         (WebInspector.Setting.prototype.set value):
2993         * UserInterface/Main.html:
2994         * UserInterface/Protocol/InspectorBackend.js:
2995         (InspectorBackendClass):
2996         (InspectorBackendClass.prototype.set dumpInspectorProtocolMessages):
2997         (InspectorBackendClass.prototype.get dumpInspectorProtocolMessages):
2998
2999             We still want to support the legacy way to enable dumping:
3000             `InspectorBackend.dumpInspectorProtocolMessages = true`. This
3001             is because some tests always use it, and it's easier to set this
3002             flag in a custom Bootstrap.js file than to configure the Setting.
3003
3004         (InspectorBackendClass.prototype.set dumpInspectorTimeStats):
3005         (InspectorBackendClass.prototype.get dumpInspectorTimeStats):
3006
3007             We still want to support the legacy way to enable dumping:
3008             `InspectorBackend.dumpInspectorTimeStats = true`. This is
3009             because MessageDispatcher checks this flag for its logging.
3010
3011         (InspectorBackendClass.prototype.set activeTracer):
3012         (InspectorBackendClass.prototype.get activeTracer):
3013
3014             Set the active tracer, finalizing and removing any active tracer
3015             if one exists. If removing a custom tracer (setting to null), then
3016             re-sync activeTracer with the automatic tracing Setting.
3017
3018         (InspectorBackendClass.prototype.dispatch):
3019         (InspectorBackendClass.prototype._startOrStopAutomaticTracing):
3020
3021             Sync the Setting with activeTracer. If an custom tracer is active,
3022             don't replace it with the automatic logging tracer.
3023
3024         (InspectorBackendClass.prototype._sendCommandToBackendWithCallback):
3025         (InspectorBackendClass.prototype._sendCommandToBackendExpectingPromise):
3026         (InspectorBackendClass.prototype._sendMessageToBackend):
3027         (InspectorBackendClass.prototype._dispatchResponse):
3028         (InspectorBackendClass.prototype._dispatchEvent):
3029         (InspectorBackendClass.prototype._flushPendingScripts):
3030         * UserInterface/Protocol/LoggingProtocolTracer.js: Added.
3031         (WebInspector.LoggingProtocolTracer):
3032         (WebInspector.LoggingProtocolTracer.prototype.set dumpMessagesToConsole):
3033         (WebInspector.LoggingProtocolTracer.prototype.get dumpMessagesToConsole):
3034         (WebInspector.LoggingProtocolTracer.prototype.set dumpTimingDataToConsole):
3035         (WebInspector.LoggingProtocolTracer.prototype.get dumpTimingDataToConsole):
3036         (WebInspector.LoggingProtocolTracer.prototype.logFrontendException):
3037         (WebInspector.LoggingProtocolTracer.prototype.logProtocolError):
3038         (WebInspector.LoggingProtocolTracer.prototype.logFrontendRequest):
3039         (WebInspector.LoggingProtocolTracer.prototype.logWillHandleResponse):
3040         (WebInspector.LoggingProtocolTracer.prototype.logDidHandleResponse):
3041         (WebInspector.LoggingProtocolTracer.prototype.logWillHandleEvent):
3042         (WebInspector.LoggingProtocolTracer.prototype.logDidHandleEvent):
3043         (WebInspector.LoggingProtocolTracer.prototype._processEntry):
3044         * UserInterface/Protocol/ProtocolTracer.js: Added.
3045         (WebInspector.ProtocolTracer.prototype.logStarted):
3046         (WebInspector.ProtocolTracer.prototype.logFrontendException):
3047         (WebInspector.ProtocolTracer.prototype.logProtocolError):
3048         (WebInspector.ProtocolTracer.prototype.logFrontendRequest):
3049         (WebInspector.ProtocolTracer.prototype.logWillHandleResponse):
3050         (WebInspector.ProtocolTracer.prototype.logDidHandleResponse):
3051         (WebInspector.ProtocolTracer.prototype.logWillHandleEvent):
3052         (WebInspector.ProtocolTracer.prototype.logDidHandleEvent):        (WebInspector.ProtocolTracer.prototype.logFinished):
3053         (WebInspector.ProtocolTracer):
3054         * UserInterface/Test.html:
3055
3056 2015-12-09  Brian Burg  <bburg@apple.com>
3057
3058         Web Inspector: zoom with Ctrl +/- doesn't work correctly when inspector is docked
3059         https://bugs.webkit.org/show_bug.cgi?id=152076
3060
3061         Reviewed by Timothy Hatcher.
3062
3063         When computing the new width or height of the inspector, take the zoom level into
3064         account. window.inner{Width,Height} are in document pixels, but we need to specify
3065         device pixels to InspectorFrontendHost.
3066
3067         * UserInterface/Base/Main.js:
3068
3069 2015-12-08  Joseph Pecoraro  <pecoraro@apple.com>
3070
3071         Web Inspector: Workaround arrow function issue in TimelineOverviewGraph.js
3072         https://bugs.webkit.org/show_bug.cgi?id=152031
3073
3074         Reviewed by Timothy Hatcher.
3075
3076         * UserInterface/Views/TimelineOverviewGraph.js:
3077         (WebInspector.TimelineOverviewGraph.prototype._needsSelectedRecordLayout):
3078         Workaround an existing arrow function issue by moving off of arrow functions here.
3079
3080 2015-12-08  Matt Baker  <mattbaker@apple.com>
3081
3082         Web Inspector: Add a hidden property to TreeOutline
3083         https://bugs.webkit.org/show_bug.cgi?id=152014
3084
3085         Reviewed by Timothy Hatcher.
3086
3087         * UserInterface/Views/NavigationSidebarPanel.js:
3088         Removed static property for "hidden" CSS class. No longer used.
3089         (WebInspector.NavigationSidebarPanel.prototype.set contentTreeOutline):
3090         Fixed bug in order of visibleTreeOutlines add/remove.
3091         (WebInspector.NavigationSidebarPanel.prototype.createContentTreeOutline):
3092
3093         * UserInterface/Views/TimelineSidebarPanel.js:
3094         (WebInspector.TimelineSidebarPanel):
3095         (WebInspector.TimelineSidebarPanel.prototype._changeViewMode):
3096
3097         * UserInterface/Views/TreeOutline.js:
3098         (WebInspector.TreeOutline):
3099         (WebInspector.TreeOutline.prototype.get hidden):
3100         (WebInspector.TreeOutline.prototype.set hidden):
3101         Added hidden property, set DOM element hidden attribute.
3102         (WebInspector.TreeElement.prototype.set hidden):
3103         Remove CSS class, set DOM element hidden attribute.
3104         (WebInspector.TreeElement.prototype._attach):
3105         (WebInspector.TreeElement.prototype.expand):
3106
3107 2015-12-08  Matt Baker  <mattbaker@apple.com>
3108
3109         Web Inspector: Global Breakpoints should always be visible
3110         https://bugs.webkit.org/show_bug.cgi?id=151066
3111
3112         Reviewed by Timothy Hatcher.
3113
3114         * UserInterface/Views/DebuggerSidebarPanel.js:
3115         (WebInspector.DebuggerSidebarPanel):
3116         Turn off filtering for Global Breakpoints elements.
3117
3118         * UserInterface/Views/NavigationSidebarPanel.js:
3119         (WebInspector.NavigationSidebarPanel.prototype.suppressFilteringOnTreeElements):
3120         Allow filtering to be turned off for specific tree elements.
3121         (WebInspector.NavigationSidebarPanel.prototype.applyFiltersToTreeElement):
3122         Make element visible if filtering suppressed.
3123         (WebInspector.NavigationSidebarPanel.prototype._checkForEmptyFilterResults):
3124         Visible elements with filtering disabled aren't considered when
3125         showing/hiding the empty content placeholder.
3126
3127 2015-12-07  Brian Burg  <bburg@apple.com>
3128
3129         Web Inspector: Uncaught Exception page should have better styles and handle more error cases
3130         https://bugs.webkit.org/show_bug.cgi?id=151923
3131
3132         Reviewed by Timothy Hatcher.
3133
3134         Restructure the Uncaught Exception reporting page to act more like
3135         a modal sheet. Distinguish between uncaught exceptions before and
3136         after the frontend is initially loaded. If the frontend is loaded,
3137         add a clickable link that dismisses the sheet and ignores the error.
3138         If the inspector finished loading, then only show at most one
3139         exception at a time, since subsequent interactions can cause spurious
3140         errors when the sheet is active.
3141
3142         Split existing code into multiple functions so it's easier to follow.
3143         Add miscellaneous guards against internal corruption and weird cases.
3144
3145         * UserInterface/Base/Main.js:
3146         (WebInspector.contentLoaded): Store the flag on the global object
3147         in case WebInspector becomes shadowed or otherwise unusable.
3148
3149         * UserInterface/Debug/UncaughtExceptionReporter.css: Renamed from Source/WebInspectorUI/UserInterface/Debug/CatchEarlyErrors.css.
3150         (div.sheet-container):
3151         (div.uncaught-exception-sheet):
3152         (div.uncaught-exception-sheet a):
3153         (div.uncaught-exception-sheet a:active):
3154         (div.uncaught-exception-sheet h2):
3155         (div.uncaught-exception-sheet h1 > img):
3156         (div.uncaught-exception-sheet h2 > img):
3157         (div.uncaught-exception-sheet dl):
3158         (div.uncaught-exception-sheet dt):
3159         (div.uncaught-exception-sheet dd):
3160         (div.uncaught-exception-sheet ul):
3161         (div.uncaught-exception-sheet li):
3162         * UserInterface/Debug/UncaughtExceptionReporter.js: Renamed from CatchEarlyErrors.js.
3163         (stopEventPropagation): Allow clicking whitelisted links on the sheet.
3164         (blockEventHandlers):
3165         (unblockEventHandlers):
3166         (handleUncaughtException):
3167         (dismissErrorSheet):
3168         (createErrorSheet.insertWordBreakCharacters):
3169         (createErrorSheet):
3170         (handleLinkClick):
3171         * UserInterface/Main.html:
3172         * UserInterface/Protocol/MessageDispatcher.js:
3173         (WebInspector.dispatchMessageFromBackend): Don't try to dispatch
3174         messages from the backend when showing the error sheet. They will
3175         probably fail, so suspend dispatching until the sheet is dismissed.
3176
3177 2015-12-06  Devin Rousso  <dcrousso+webkit@gmail.com>
3178
3179         Web Inspector: Regression (r192936) - changing selectors in the visual styles sidebar is broken
3180         https://bugs.webkit.org/show_bug.cgi?id=151924
3181
3182         Reviewed by Brian Burg.
3183
3184         * UserInterface/Views/VisualStyleSelectorSection.js:
3185         (WebInspector.VisualStyleSelectorSection):
3186         (WebInspector.VisualStyleSelectorSection.prototype._selectorChanged):
3187         Now uses an event listener instead of an "onselect" function.
3188
3189 2015-12-06  Matt Baker  <mattbaker@apple.com>
3190
3191         Web Inspector: Comparisons in setters should use the massaged value (" = x || 0/false/null/etc")
3192         https://bugs.webkit.org/show_bug.cgi?id=151910
3193
3194         Reviewed by Timothy Hatcher.
3195
3196         Updated setters that use default values to convert falsy inputs to the default value
3197         before compariing against the current value.
3198
3199         * UserInterface/Models/TimelineMarker.js:
3200         (WebInspector.TimelineMarker.prototype.set time):
3201         Assert new value is a number.
3202
3203         * UserInterface/Views/DataGrid.js:
3204         (WebInspector.DataGridNode.prototype.set hidden):
3205         (WebInspector.DataGridNode.prototype.set data):
3206         Assert new value is of type object. Use shallowEqual compare before setting value.
3207
3208         * UserInterface/Views/GeneralTreeElement.js:
3209         (WebInspector.GeneralTreeElement.prototype.set classNames):
3210         Use shallowEqual compare before setting value.
3211         (WebInspector.GeneralTreeElement.prototype.set mainTitle):
3212         (WebInspector.GeneralTreeElement.prototype.set subtitle):
3213         (WebInspector.GeneralTreeElement.prototype.set status):
3214         (WebInspector.GeneralTreeElement.prototype.set tooltipHandledSeparately):
3215
3216         * UserInterface/Views/TimelineOverview.js:
3217         (WebInspector.TimelineOverview.prototype.set startTime):
3218         (WebInspector.TimelineOverview.prototype.set currentTime):
3219         (WebInspector.TimelineOverview.prototype.set endTime):
3220         (WebInspector.TimelineOverview.prototype.set scrollStartTime):
3221         (WebInspector.TimelineOverview.prototype.set selectionStartTime):
3222         Check current ruler selectionStartTime before setting value.
3223
3224         * UserInterface/Views/TimelineOverviewGraph.js:
3225         (WebInspector.TimelineOverviewGraph.prototype.set zeroTime):
3226         (WebInspector.TimelineOverviewGraph.prototype.set startTime):
3227         (WebInspector.TimelineOverviewGraph.prototype.set endTime):
3228         (WebInspector.TimelineOverviewGraph.prototype.set currentTime):
3229
3230         * UserInterface/Views/TimelineRuler.js:
3231         (WebInspector.TimelineRuler):
3232         (WebInspector.TimelineRuler.prototype.set allowsClippedLabels):
3233         (WebInspector.TimelineRuler.prototype.set formatLabelCallback):
3234         (WebInspector.TimelineRuler.prototype.set allowsTimeRangeSelection):
3235         (WebInspector.TimelineRuler.prototype.set zeroTime):
3236         (WebInspector.TimelineRuler.prototype.set startTime):
3237         (WebInspector.TimelineRuler.prototype.set endTime):
3238         (WebInspector.TimelineRuler.prototype.set secondsPerPixel):
3239         (WebInspector.TimelineRuler.prototype.set selectionStartTime):
3240         (WebInspector.TimelineRuler.prototype.set selectionEndTime):
3241         (WebInspector.TimelineRuler.prototype.set duration): Deleted.
3242         The ruler duration and "pinned" state are controlled by setting an end
3243         time. Removed since it wasn't being used, and there shouldn't be two
3244         ways to the exact same thing.
3245
3246         * UserInterface/Views/TimelineView.js:
3247         (WebInspector.TimelineView.prototype.set zeroTime):
3248         (WebInspector.TimelineView.prototype.set startTime):
3249         (WebInspector.TimelineView.prototype.set endTime):
3250
3251 2015-12-04  Commit Queue  <commit-queue@webkit.org>
3252
3253         Unreviewed, rolling out r193486.
3254         https://bugs.webkit.org/show_bug.cgi?id=151904
3255
3256         Causes Infinite Recursion in Timeline Recording (Requested by
3257         JoePeck on #webkit).
3258
3259         Reverted changeset:
3260
3261         "Web Inspector: when a marked-dirty subview is attached to a
3262         parent View, dirtyDescendantsCount gets out of sync"
3263         https://bugs.webkit.org/show_bug.cgi?id=151876
3264         http://trac.webkit.org/changeset/193486
3265
3266 2015-12-04  Joseph Pecoraro  <pecoraro@apple.com>
3267
3268         Web Inspector: Uncaught Exception with Reload shortcut in JSContext Inspector
3269         https://bugs.webkit.org/show_bug.cgi?id=151896
3270
3271         Reviewed by Timothy Hatcher.
3272
3273         * UserInterface/Base/Main.js:
3274         (WebInspector.contentLoaded):
3275         Do not implicitly prevent default on these keyboard shortcuts
3276         so we can system beep if we do not do anything.
3277
3278         (WebInspector._reloadPage):
3279         (WebInspector._reloadPageIgnoringCache):
3280         Bail if there is no PageAgent without preventing default for
3281         a beep system beep. Prevent default if we did something.
3282
3283 2015-12-04  Matt Baker  <mattbaker@apple.com>
3284
3285         Web Inspector: when a marked-dirty subview is attached to a parent View, dirtyDescendantsCount gets out of sync
3286         https://bugs.webkit.org/show_bug.cgi?id=151876
3287
3288         Reviewed by Brian Burg.
3289
3290         * UserInterface/Views/NewTabContentView.js:
3291         (WebInspector.NewTabContentView.prototype._updateShownTabs):
3292         Removed workaround added in https://bugs.webkit.org/show_bug.cgi?id=151594.
3293
3294         * UserInterface/Views/View.js:
3295         (WebInspector.View._scheduleLayoutForView):
3296         Always perform a synchronous layout when a view that isn't descended from the
3297         root view schedules a layout.
3298
3299 2015-12-04  Brian Burg  <bburg@apple.com>
3300
3301         Web Inspector: support runtime registration of tab type associations
3302         https://bugs.webkit.org/show_bug.cgi?id=151594
3303
3304         Reviewed by Joseph Pecoraro.
3305
3306         We want to add special tabs that only exist in engineering builds
3307         for debugging purposes. Though the relevant models and views can be
3308         put in the Debug/ directory to exclude them from production builds,
3309         there's no way to register tabs conditionally at runtime; tabs are
3310         hardcoded.
3311
3312         This patch makes it possible to register new tab types at runtime.
3313         First, WebInspector keeps a map of known, registered tab classes.
3314         Details that were hardcoded before---whether to show in New Tab,
3315         whether a tab can be instantiated given the active domains, UI text,
3316         etc.---are now static methods on the base TabContentView or overidden
3317         in its subclasses. Lastly, a public method allows code in Bootstrap.js
3318         to register tabs at runtime. Doing so sends a notification so the
3319         NewTabContentView can show the newly available tab item.
3320
3321         * UserInterface/Base/Main.js:
3322         (WebInspector.contentLoaded):
3323         (WebInspector.isTabTypeAllowed):
3324         (WebInspector.knownTabClasses): Added, used by NewTabContentView.
3325         (WebInspector._createTabContentViewForType): Renamed from _tabContentViewForType.
3326         (WebInspector._rememberOpenTabs):
3327         (WebInspector._updateNewTabButtonState):
3328         (WebInspector._tryToRestorePendingTabs): Added.
3329
3330         Whenever a new tab is registered, try to restore pending tabs, since
3331         an extra tab won't be added initially when production tabs are added.
3332         But, it could have been saved in the Setting for opened tabs.
3333
3334         (WebInspector.showNewTabTab):
3335         (WebInspector.isNewTabWithTypeAllowed):
3336         (WebInspector.createNewTabWithType):
3337         (WebInspector._tabContentViewForType): Deleted.
3338         * UserInterface/Base/Object.js:
3339         * UserInterface/Views/ConsoleTabContentView.js:
3340         (WebInspector.ConsoleTabContentView):
3341         (WebInspector.ConsoleTabContentView.tabInfo): Added.
3342         * UserInterface/Views/DebuggerTabContentView.js:
3343         (WebInspector.DebuggerTabContentView):
3344         (WebInspector.DebuggerTabContentView.tabInfo): Added.
3345         * UserInterface/Views/ElementsTabContentView.js:
3346         (WebInspector.ElementsTabContentView):
3347         (WebInspector.ElementsTabContentView.tabInfo): Added.
3348         (WebInspector.ElementsTabContentView.isTabAllowed): Added.
3349         * UserInterface/Views/NetworkTabContentView.js:
3350         (WebInspector.NetworkTabContentView):
3351         (WebInspector.NetworkTabContentView.tabInfo): Added.
3352         (WebInspector.NetworkTabContentView.isTabAllowed): Added.
3353         * UserInterface/Views/NewTabContentView.js:
3354
3355         Keep a list of shown tab items, so we don't have to query the DOM
3356         to update enabled/disabled state. Put tree construction inside a
3357         layout() override and dirty the view whenever known tab types change.
3358
3359         (WebInspector.NewTabContentView):
3360         (WebInspector.NewTabContentView.tabInfo): Added.
3361         (WebInspector.NewTabContentView.isEphemeral): Added.
3362         (WebInspector.NewTabContentView.shouldSaveTab): Added.
3363         (WebInspector.NewTabContentView.prototype.layout): Added.
3364         (WebInspector.NewTabContentView.prototype._updateShownTabs): Added.
3365         (WebInspector.NewTabContentView.prototype._allowableTabTypes):
3366         (WebInspector.NewTabContentView.prototype._updateTabItems):
3367         (WebInspector.NewTabContentView.prototype.get tabItemElements): Deleted.
3368         * UserInterface/Views/ResourcesTabContentView.js:
3369         (WebInspector.ResourcesTabContentView):
3370         (WebInspector.ResourcesTabContentView.tabInfo): Added.
3371         * UserInterface/Views/SearchTabContentView.js:
3372         (WebInspector.SearchTabContentView):
3373         (WebInspector.SearchTabContentView.tabInfo): Added.
3374         (WebInspector.SearchTabContentView.isEphemeral): Added.
3375         * UserInterface/Views/SettingsTabContentView.js:
3376         (WebInspector.SettingsTabContentView.isTabAllowed): Added.
3377         (WebInspector.SettingsTabContentView.shouldSaveTab): Added.
3378         * UserInterface/Views/StorageTabContentView.js:
3379         (WebInspector.StorageTabContentView):
3380         (WebInspector.StorageTabContentView.tabInfo): Added.
3381         (WebInspector.StorageTabContentView.isTabAllowed): Added.
3382         * UserInterface/Views/TabBrowser.js:
3383         (WebInspector.TabBrowser.showTabForContentView):
3384
3385         Add a workaround for <https://webkit.org/b/151876>. This bug is
3386         revealed by the changes to NewTabContentView in this patch.
3387
3388         * UserInterface/Views/TabContentView.js:
3389         (WebInspector.TabContentView.isTabAllowed): Added.
3390         (WebInspector.TabContentView.isEphemeral): Added.
3391         (WebInspector.TabContentView.shouldSaveTab): Added.
3392         * UserInterface/Views/TimelineTabContentView.js:
3393         (WebInspector.TimelineTabContentView):
3394         (WebInspector.TimelineTabContentView.tabInfo): Added.
3395         (WebInspector.TimelineTabContentView.isTabAllowed): Added.
3396
3397 2015-12-04  Joseph Pecoraro  <pecoraro@apple.com>
3398
3399         Web Inspector: Remove untested and unused Worker inspection
3400         https://bugs.webkit.org/show_bug.cgi?id=151848
3401
3402         Reviewed by Brian Burg.
3403
3404         * UserInterface/Protocol/Legacy/7.0/InspectorBackendCommands.js:
3405         * UserInterface/Protocol/Legacy/8.0/InspectorBackendCommands.js:
3406         * UserInterface/Protocol/Legacy/9.0/InspectorBackendCommands.js:
3407         * Versions/Inspector-iOS-7.0.json:
3408         * Versions/Inspector-iOS-8.0.json:
3409         * Versions/Inspector-iOS-9.0.json:
3410         Since this was untested in older releases as well, remove
3411         the protocol interfaces for legacy versions.
3412
3413 2015-12-04  Joseph Pecoraro  <pecoraro@apple.com>
3414
3415         Web Inspector: Specifically Identify the Global Lexical Environment Scope
3416         https://bugs.webkit.org/show_bug.cgi?id=151828
3417
3418         Reviewed by Brian Burg.
3419
3420         * Localizations/en.lproj/localizedStrings.js:
3421         * UserInterface/Controllers/DebuggerManager.js:
3422         (WebInspector.DebuggerManager.prototype._scopeChainNodeFromPayload):
3423         * UserInterface/Models/ScopeChainNode.js:
3424         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
3425         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
3426         Include a new scope type and give it a localized string.
3427
3428 2015-12-03  Anders Carlsson  <andersca@apple.com>
3429
3430         Remove Objective-C GC support
3431         https://bugs.webkit.org/show_bug.cgi?id=151819
3432         rdar://problem/23746991
3433
3434         Reviewed by Dan Bernstein.
3435
3436         * Configurations/Base.xcconfig:
3437
3438 2015-12-03  Matt Baker  <mattbaker@apple.com>
3439
3440         Uncaught Exception in Web Inspector: TypeError: null is not an object (evaluating 'dataGridNode.element.classList')
3441         https://bugs.webkit.org/show_bug.cgi?id=151790
3442
3443         Reviewed by Timothy Hatcher.
3444
3445         * UserInterface/Views/DataGrid.js:
3446         (WebInspector.DataGridNode):
3447         (WebInspector.DataGridNode.prototype.get hidden):
3448         (WebInspector.DataGridNode.prototype.set hidden):
3449         Make hidden a property, so it can be set before the grid node's DOM element exists.
3450         (WebInspector.DataGridNode.prototype.get selectable):
3451         (WebInspector.DataGridNode.prototype.get element):
3452         Add hidden style, if needed, when element is created.
3453
3454         * UserInterface/Views/TreeOutlineDataGridSynchronizer.js:
3455         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementVisibilityDidChange):
3456         (WebInspector.TreeOutlineDataGridSynchronizer):
3457         Don't access the grid node's element directly, since it may not exist yet.
3458
3459 2015-12-02  Joseph Pecoraro  <pecoraro@apple.com>
3460
3461         Web Inspector: Handle YieldExpressions in the ScriptSyntaxTree
3462         https://bugs.webkit.org/show_bug.cgi?id=151730
3463
3464         Reviewed by Brian Burg.
3465
3466         * UserInterface/Models/NativeFunctionParameters.js:
3467         Add the Generator API.
3468
3469         * UserInterface/Models/ScriptSyntaxTree.js:
3470         (WebInspector.ScriptSyntaxTree.prototype._recurse):
3471         (WebInspector.ScriptSyntaxTree.prototype._createInternalSyntaxTree):
3472         Handle YieldExpressions.
3473
3474 2015-12-01  Matt Baker  <mattbaker@apple.com>
3475
3476         Web Inspector: TreeOutline should just dispatch events via WebInspector.Object
3477         https://bugs.webkit.org/show_bug.cgi?id=148067
3478
3479         Reviewed by Timothy Hatcher.
3480
3481         TreeOutline now dispatches most events via WebInspector.Object. The onselect and
3482         ondeselect callbacks are replaced by a SelectionDidChange event, which includes
3483         both the selected and deselected elements in its event data. The onexpand and oncollapse
3484         callbacks are replaced by an ElementDisclosureDidChange event. This is consistent with the
3485         behavior of onhidden, which had no corresponding onvisible callback.
3486
3487         Alas, TimelineView and TreeOutlineDataGridSynchronizer depended on the order in which
3488         TreeOutline.onselect callbacks were chained together. The synchronizer added its
3489         callback after the timeline view, which ensured that the tree and grid were in sync
3490         before the view handled onselect and dispatched a SelectionPathComponentsDidChange.
3491         The change notification causes the view's path components to be read, and timeline
3492         views need the grid selection to be in a valid state to build path components.
3493
3494         This is addressed by having timeline views dispatch SelectionPathComponentsDidChange
3495         events when the grid selection changes, instead of the tree selection. The change
3496         required that the synchronizer no longer suppress notifications when selecting grid nodes.
3497
3498         * UserInterface/Views/DebuggerSidebarPanel.js:
3499         (WebInspector.DebuggerSidebarPanel):
3500         (WebInspector.DebuggerSidebarPanel.prototype._treeSelectionDidChange):
3501         (WebInspector.DebuggerSidebarPanel.prototype._updatePauseReasonSection):
3502
3503         * UserInterface/Views/NavigationSidebarPanel.js:
3504         (WebInspector.NavigationSidebarPanel.prototype.createContentTreeOutline):
3505         (WebInspector.NavigationSidebarPanel.prototype._treeElementAddedOrChanged):
3506
3507         * UserInterface/Views/NetworkGridContentView.js:
3508         (WebInspector.NetworkGridContentView):
3509         (WebInspector.NetworkGridContentView.prototype._treeSelectionDidChange):
3510
3511         * UserInterface/Views/ResourceSidebarPanel.js:
3512         (WebInspector.ResourceSidebarPanel):
3513         (WebInspector.ResourceSidebarPanel.prototype._treeSelectionDidChange):
3514         (WebInspector.ResourceSidebarPanel.prototype._treeElementSelected): Deleted.
3515
3516         * UserInterface/Views/ScopeChainDetailsSidebarPanel.js:
3517         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateCallFramesSection):
3518         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._generateWatchExpressionsSection):
3519         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._treeElementAdded):
3520         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._treeElementDisclosureDidChange):
3521         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._objectTreeExpandHandler): Deleted.
3522         (WebInspector.ScopeChainDetailsSidebarPanel.prototype._objectTreeCollapseHandler): Deleted.
3523
3524         * UserInterface/Views/SearchSidebarPanel.js:
3525         (WebInspector.SearchSidebarPanel):
3526         (WebInspector.SearchSidebarPanel.prototype._treeSelectionDidChange):
3527         (WebInspector.SearchSidebarPanel.prototype._treeElementSelected): Deleted.
3528
3529         * UserInterface/Views/StorageSidebarPanel.js:
3530         (WebInspector.StorageSidebarPanel):
3531         (WebInspector.StorageSidebarPanel._treeSelectionDidChange):
3532
3533         * UserInterface/Views/TimelineDataGrid.js:
3534         (WebInspector.TimelineDataGrid.prototype._createPopoverContent):
3535         (WebInspector.TimelineDataGrid.prototype._popoverCallStackTreeSelectionDidChange):
3536         (WebInspector.TimelineDataGrid):
3537
3538         * UserInterface/Views/TimelineSidebarPanel.js:
3539         (WebInspector.TimelineSidebarPanel):
3540         (WebInspector.TimelineSidebarPanel.prototype._recordingsTreeSelectionDidChange):
3541         (WebInspector.TimelineSidebarPanel.prototype._timelinesTreeSelectionDidChange):
3542         (WebInspector.TimelineSidebarPanel.prototype._timelinesTreeElementSelected): Deleted.
3543
3544         * UserInterface/Views/TimelineView.js:
3545         (WebInspector.TimelineView):
3546         (WebInspector.TimelineView.prototype._treeSelectionDidChange):
3547         (WebInspector.TimelineView.prototype.treeElementSelected):
3548         Don't dispatch SelectionPathComponentsDidChange. Timeline views already do this
3549         in response to grid selection events.
3550
3551         * UserInterface/Views/TreeOutline.js:
3552         (WebInspector.TreeOutline.prototype.appendChild):
3553         (WebInspector.TreeOutline.prototype.insertChild):
3554         (WebInspector.TreeOutline.prototype.removeChildAtIndex):
3555         (WebInspector.TreeOutline.prototype.removeChildren):
3556         (WebInspector.TreeOutline.prototype.removeChildrenRecursive):
3557         (WebInspector.TreeOutline.prototype._treeElementDidChange):
3558         (WebInspector.TreeElement.prototype.set hidden):
3559         (WebInspector.TreeElement.prototype.collapse):
3560         (WebInspector.TreeElement.prototype.expand):
3561         (WebInspector.TreeElement.prototype.select):
3562         (WebInspector.TreeElement.prototype.deselect):
3563         (WebInspector.TreeElement.prototype.get childrenListElement): Deleted.
3564         Removed dead code.
3565
3566         * UserInterface/Views/TreeOutlineDataGridSynchronizer.js:
3567         (WebInspector.TreeOutlineDataGridSynchronizer):
3568         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeSelectionDidChange):
3569         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementAdded):
3570         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementRemoved):
3571         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementDisclosureDidChange):
3572         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementVisibilityDidChange):
3573         (WebInspector.TreeOutlineDataGridSynchronizer.treeOutline.onadd): Deleted.
3574         (WebInspector.TreeOutlineDataGridSynchronizer.treeOutline.onremove): Deleted.
3575         (WebInspector.TreeOutlineDataGridSynchronizer.treeOutline.onexpand): Deleted.
3576         (WebInspector.TreeOutlineDataGridSynchronizer.treeOutline.oncollapse): Deleted.
3577         (WebInspector.TreeOutlineDataGridSynchronizer.treeOutline.onhidden): Deleted.
3578         (WebInspector.TreeOutlineDataGridSynchronizer.treeOutline.onselect): Deleted.
3579         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementSelected): Deleted.
3580         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementExpanded): Deleted.
3581         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementCollapsed): Deleted.
3582         (WebInspector.TreeOutlineDataGridSynchronizer.prototype._treeElementHiddenChanged): Deleted.
3583
3584         * UserInterface/Views/VisualStyleCommaSeparatedKeywordEditor.js:
3585         (WebInspector.VisualStyleCommaSeparatedKeywordEditor):
3586         (WebInspector.VisualStyleCommaSeparatedKeywordEditor.prototype._treeSelectionDidChange):
3587         (WebInspector.VisualStyleCommaSeparatedKeywordEditor.prototype._treeElementSelected): Deleted.
3588
3589 2015-12-01  Joseph Pecoraro  <pecoraro@apple.com>
3590
3591         Web Inspector: Timestamp in Tooltip of Event Markers is incorrect
3592         https://bugs.webkit.org/show_bug.cgi?id=151722
3593
3594         Reviewed by Timothy Hatcher.
3595
3596         * UserInterface/Views/TimelineRuler.js:
3597         (WebInspector.TimelineRuler.prototype.addMarker):
3598         Convert the marker's time, to be relative to the start of the recording.
3599
3600 2015-12-01  Joseph Pecoraro  <pecoraro@apple.com>
3601
3602         Unreviewed common typo fix "occurance" => "occurrence".
3603
3604         * Scripts/combine-resources.pl:
3605         (concatenateFiles):
3606
3607 2015-12-01  Joseph Pecoraro  <pecoraro@apple.com>
3608
3609         Web Inspector: Spacebar to toggle Timeline recording doesn't work in Timeline tab after reloading the page
3610         https://bugs.webkit.org/show_bug.cgi?id=151530
3611
3612         Reviewed by Timothy Hatcher.
3613
3614         If reloading the page caused the console to clear, that was triggering
3615         the console prompt to be focused. When the console prompt is focused,
3616         keyboard input like Spacebar, was just inputing characters instead of
3617         triggering the keyboard shortcut that was expected.
3618
3619         This also means that console.clear() in the inspected page would cause
3620         the inspector to focus the console. That is unexpected as well.
3621
3622         Focusing the console prompt whenever the console log is cleared
3623         is not ideal. If we do want to focus the prompt the caller should
3624         make that determination, not clear.
3625
3626         * UserInterface/Controllers/JavaScriptLogViewController.js:
3627         (WebInspector.JavaScriptLogViewController.prototype.clear):
3628
3629 2015-12-01  Joseph Pecoraro  <pecoraro@apple.com>
3630
3631         Web Inspector: Update Timeline UI based on the Instruments in the Active Recording
3632         https://bugs.webkit.org/show_bug.cgi?id=151374
3633
3634         Reviewed by Brian Burg.
3635
3636         * UserInterface/Views/TimelineRecordingContentView.js:
3637         (WebInspector.TimelineRecordingContentView.prototype._updateTimelineOverviewHeight):
3638         Modernize as I was in this code while looking into this patch.
3639
3640         * UserInterface/Views/TimelineSidebarPanel.css:
3641         (.sidebar > .panel.navigation.timeline > .title-bar.timeline-events): Deleted.
3642         (.sidebar > .panel.navigation.timeline > .timelines-content): Deleted.
3643         These defaults are no longer necessary, the UI overrides them anyways.
3644
3645         * UserInterface/Views/TimelineSidebarPanel.js:
3646         (WebInspector.TimelineSidebarPanel):
3647         Include both the basic and rendering frames toolbars. They will be
3648         mutually exclusive based on if the FPSIntrument is available.
3649
3650         (WebInspector.TimelineSidebarPanel.prototype._recordingSelected):
3651         (WebInspector.TimelineSidebarPanel.prototype._clearInstruments):
3652         When loading a new Recording clear the UI.
3653
3654         (WebInspector.TimelineSidebarPanel.prototype._instrumentAdded):
3655         (WebInspector.TimelineSidebarPanel.prototype._instrumentRemoved):
3656         (WebInspector.TimelineSidebarPanel.prototype._addedFPSInstrument):
3657         (WebInspector.TimelineSidebarPanel.prototype._removedFPSInstrument):
3658         Handle toggling the toolbars when the FPS instrument is added/removed.
3659
3660         (WebInspector.TimelineSidebarPanel.prototype._timelineCountChanged):
3661         (WebInspector.TimelineSidebarPanel.prototype._updateTimelineOverviewHeight):
3662         (WebInspector.TimelineSidebarPanel.prototype._changeViewMode):
3663         Properly update the sidebar's understanding of the TimelineOverview size.
3664
3665 2015-12-01  Joseph Pecoraro  <pecoraro@apple.com>
3666
3667         Web Inspector: Initial support for variable timelines
3668         https://bugs.webkit.org/show_bug.cgi?id=151372
3669
3670         Reviewed by Brian Burg.
3671
3672         * UserInterface/Controllers/TimelineManager.js:
3673         (WebInspector.TimelineManager.defaultInstruments):
3674         (WebInspector.TimelineManager.prototype._loadNewRecording):
3675         Keep the status quo which is the same set of instruments for each recording.
3676
3677         (WebInspector.TimelineManager.prototype.startCapturing):
3678         (WebInspector.TimelineManager.prototype.stopCapturing):
3679         Push responsibility of capturing to the Recording, which has a specific set
3680         of instruments that know what they need to turn on an off from the backend.
3681         
3682         * UserInterface/Main.html:
3683         * UserInterface/Models/Instrument.js: Added.
3684         (WebInspector.Instrument):
3685         (WebInspector.Instrument.startLegacyTimelineAgent):
3686         (WebInspector.Instrument.stopLegacyTimelineAgent):
3687         (WebInspector.Instrument.prototype.get timelineRecordType):
3688         (WebInspector.Instrument.prototype.startInstrumentation):
3689         (WebInspector.Instrument.prototype.stopInstrumentation):
3690         New class representing something that can be turned on and off
3691         from the backend and produces a set of Timeline record types.
3692         Currently instruments are 1-to-1 to a Timeline type.
3693
3694         * UserInterface/Models/LayoutInstrument.js: Added.
3695         (WebInspector.LayoutInstrument.prototype.get timelineRecordType):
3696         (WebInspector.LayoutInstrument):
3697         * UserInterface/Models/NetworkInstrument.js: Added.
3698         (WebInspector.NetworkInstrument.prototype.get timelineRecordType):
3699         (WebInspector.NetworkInstrument.prototype.startInstrumentation):
3700         (WebInspector.NetworkInstrument.prototype.stopInstrumentation):
3701         (WebInspector.NetworkInstrument):
3702         * UserInterface/Models/ScriptInstrument.js: Added.
3703         (WebInspector.ScriptInstrument.prototype.get timelineRecordType):
3704         (WebInspector.ScriptInstrument):
3705         The default set of instruments. Currently they all enable the TimelineAgent,
3706         so they share code to enable/disable in the base class to avoid duplication.
3707
3708         * UserInterface/Models/FPSInstrument.js: Added.
3709         (WebInspector.FPSInstrument):
3710         (WebInspector.FPSInstrument.supported):
3711         (WebInspector.FPSInstrument.prototype.get timelineRecordType):
3712         Provide a "supported" static method and simplify other code that
3713         checks whether or not RenderingFrames is available or not.
3714
3715
3716         * UserInterface/Models/Timeline.js:
3717         (WebInspector.Timeline.prototype.get displayName): Deleted.
3718         (WebInspector.Timeline.prototype.get iconClassName): Deleted.
3719         Move these to a View class, as this is primarily View logic.
3720
3721         * UserInterface/Models/TimelineRecording.js:
3722         (WebInspector.TimelineRecording):
3723         (WebInspector.TimelineRecording.prototype.get instruments):
3724         (WebInspector.TimelineRecording.prototype.start):
3725         (WebInspector.TimelineRecording.prototype.stop):
3726         (WebInspector.TimelineRecording.prototype.timelineForInstrument):
3727         (WebInspector.TimelineRecording.prototype.addInstrument):
3728         (WebInspector.TimelineRecording.prototype.removeInstrument):
3729         (WebInspector.TimelineRecording.prototype.addEventMarker):
3730         (WebInspector.TimelineRecording.prototype.addTimeline): Deleted.
3731         (WebInspector.TimelineRecording.prototype.removeTimeline): Deleted.
3732         A recording now has a set of Instruments and its own start/stop
3733         which starts/stops its set of Instruments! Treat Instruments as
3734         the variable property of a Recording instead of Timelines.
3735     
3736         * UserInterface/Views/TimelineOverview.js:
3737         (WebInspector.TimelineOverview):
3738         (WebInspector.TimelineOverview.prototype._instrumentAdded):
3739         (WebInspector.TimelineOverview.prototype._instrumentRemoved):
3740         (WebInspector.TimelineOverview.prototype._timelineAdded): Deleted.
3741         (WebInspector.TimelineOverview.prototype._timelineRemoved): Deleted.
3742         * UserInterface/Views/TimelineRecordingContentView.js:
3743         (WebInspector.TimelineRecordingContentView):
3744         (WebInspector.TimelineRecordingContentView.prototype._instrumentAdded):
3745         (WebInspector.TimelineRecordingContentView.prototype._instrumentRemoved):
3746         (WebInspector.TimelineRecordingContentView.prototype._timelineAdded): Deleted.
3747         (WebInspector.TimelineRecordingContentView.prototype._timelineRemoved): Deleted.
3748         * UserInterface/Views/TimelineSidebarPanel.js:
3749         (WebInspector.TimelineSidebarPanel):
3750         (WebInspector.TimelineSidebarPanel.displayNameForTimeline):
3751         (WebInspector.TimelineSidebarPanel.iconClassNameForTimeline):
3752         (WebInspector.TimelineSidebarPanel.prototype.updateFrameSelection):
3753         (WebInspector.TimelineSidebarPanel.prototype.restoreStateFromCookie):
3754         (WebInspector.TimelineSidebarPanel.prototype._recordingSelected):
3755         (WebInspector.TimelineSidebarPanel.prototype._instrumentAdded):
3756         (WebInspector.TimelineSidebarPanel.prototype._instrumentRemoved):
3757         (WebInspector.TimelineSidebarPanel.prototype._changeViewMode):
3758         (WebInspector.TimelineSidebarPanel.prototype._timelineAdded): Deleted.
3759         (WebInspector.TimelineSidebarPanel.prototype._timelineRemoved): Deleted.
3760         Update all TimelineAdded/TimelineRemoved clients to instead check
3761         InstrumentAdded/InstrumentRemoved. Immediately convert from an Instrument
3762         to a Timeline to keep the patch simple.
3763
3764 2015-12-01  Joseph Pecoraro  <pecoraro@apple.com>
3765
3766         Web Inspector: Broken Inspector when resources are minified
3767         https://bugs.webkit.org/show_bug.cgi?id=151711
3768
3769         Reviewed by Timothy Hatcher.
3770
3771         * Scripts/combine-resources.pl:
3772         (concatenateFiles):
3773         Provide a way to just strip resources matches a pattern.
3774
3775         * Scripts/copy-user-interface-resources.pl:
3776         Strip "Debug/" resources before combining / minifying others.
3777
3778         * UserInterface/Views/View.js:
3779         (WebInspector.View.prototype.makeRootView):
3780         (WebInspector.View.prototype.didDetach):
3781         Address warnings from the console.assert stripping phase
3782         for console.assert statements lacking a trailing semicolon.
3783
3784 2015-11-30  Brian Burg  <bburg@apple.com>
3785
3786         Web Inspector: show something useful when the inspector frontend fails to load
3787         https://bugs.webkit.org/show_bug.cgi?id=151643
3788
3789         Reviewed by Timothy Hatcher.
3790
3791         When a parse error or other early error happens before the inspector
3792         is fully loaded, we can't use the second-level inspector to tell what's
3793         going on. It would be better to catch any early errors and list them.
3794
3795         This patch adds an error page that shows the early errors that happened
3796         during loading. It provides a list of errors, a link to reload the
3797         inspector, and a link to submit a pre-filled bug report about the error.
3798
3799         For now, this page only shows up in engineering builds because it's
3800         located in the Debug/ directory. We can move it later when it works
3801         better in all cases. Follow-up patches can address smaller issues,
3802         such as the transparent title bar and broken text selection.
3803
3804          * UserInterface/Debug/CatchEarlyErrors.css: Added.
3805          * UserInterface/Debug/CatchEarlyErrors.js: Added.
3806          * UserInterface/Main.html:
3807          * UserInterface/Main.js: Abort setting up the UI if something happened.
3808
3809 2015-11-30  Brian Burg  <bburg@apple.com>
3810
3811         Web Inspector: delete-by-word and similar shortcuts should add text to the WebCore