OLD | NEW |
---|---|
1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 /** | 5 /** |
6 * @constructor | 6 * @constructor |
7 * @extends {WebInspector.StylesSidebarPane.BaseToolbarPaneWidget} | 7 * @extends {WebInspector.StylesSidebarPane.BaseToolbarPaneWidget} |
8 */ | 8 */ |
9 WebInspector.AnimationControlPane = function(toolbarItem) | 9 WebInspector.AnimationControlPane = function(toolbarItem) |
10 { | 10 { |
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
128 }, | 128 }, |
129 | 129 |
130 _clicked: function() | 130 _clicked: function() |
131 { | 131 { |
132 if (Runtime.experiments.isEnabled("animationInspection")) | 132 if (Runtime.experiments.isEnabled("animationInspection")) |
133 this._animationTimelineModeClick(); | 133 this._animationTimelineModeClick(); |
134 else | 134 else |
135 this._animationControlPaneModeClick(); | 135 this._animationControlPaneModeClick(); |
136 }, | 136 }, |
137 | 137 |
138 _nodeChanged: function() | 138 /** |
139 * @param {!Event=} event | |
140 */ | |
141 _nodeChanged: function(event) | |
139 { | 142 { |
140 this._button.setEnabled(!!WebInspector.context.flavor(WebInspector.DOMNo de)); | 143 this._button.setEnabled(!!WebInspector.context.flavor(WebInspector.DOMNo de)); |
144 if (event && this._animationTimeline) | |
pfeldman
2015/06/05 14:34:34
When is event undefined?
samli
2015/06/09 03:53:08
Called in WebInspector.AnimationControlPane.Button
| |
145 this._animationTimeline.setNode(/** @type {!WebInspector.DOMNode} */ (event.data)); | |
141 }, | 146 }, |
142 | 147 |
143 /** | 148 /** |
144 * @override | 149 * @override |
145 * @return {!WebInspector.ToolbarItem} | 150 * @return {!WebInspector.ToolbarItem} |
146 */ | 151 */ |
147 item: function() | 152 item: function() |
148 { | 153 { |
149 return this._button; | 154 return this._button; |
150 } | 155 } |
151 } | 156 } |
OLD | NEW |