| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
| 6 * are met: | 6 * are met: |
| 7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
| 8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
| 9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
| 10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
| (...skipping 474 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 485 for (var i = 0; i < types.length; i++) | 485 for (var i = 0; i < types.length; i++) |
| 486 this._registerProfileType(types[i]); | 486 this._registerProfileType(types[i]); |
| 487 this._launcherView.restoreSelectedProfileType(); | 487 this._launcherView.restoreSelectedProfileType(); |
| 488 this.profilesItemTreeElement.select(); | 488 this.profilesItemTreeElement.select(); |
| 489 this._showLauncherView(); | 489 this._showLauncherView(); |
| 490 | 490 |
| 491 this._createFileSelectorElement(); | 491 this._createFileSelectorElement(); |
| 492 this.element.addEventListener("contextmenu", this._handleContextMenuEvent.bi
nd(this), true); | 492 this.element.addEventListener("contextmenu", this._handleContextMenuEvent.bi
nd(this), true); |
| 493 this._registerShortcuts(); | 493 this._registerShortcuts(); |
| 494 | 494 |
| 495 this.contentElement.addEventListener("keydown", this._onKeyDown.bind(this),
false); |
| 496 |
| 495 WebInspector.targetManager.addEventListener(WebInspector.TargetManager.Event
s.SuspendStateChanged, this._onSuspendStateChanged, this); | 497 WebInspector.targetManager.addEventListener(WebInspector.TargetManager.Event
s.SuspendStateChanged, this._onSuspendStateChanged, this); |
| 496 } | 498 } |
| 497 | 499 |
| 498 WebInspector.ProfilesPanel.prototype = { | 500 WebInspector.ProfilesPanel.prototype = { |
| 499 /** | 501 /** |
| 502 * @param {!Event} event |
| 503 */ |
| 504 _onKeyDown: function(event) |
| 505 { |
| 506 var handled = false; |
| 507 if (event.keyIdentifier === "Down" && !event.altKey) |
| 508 handled = this._sidebarTree.selectNext(); |
| 509 else if (event.keyIdentifier === "Up" && !event.altKey) |
| 510 handled = this._sidebarTree.selectPrevious(); |
| 511 if (handled) |
| 512 event.consume(true); |
| 513 }, |
| 514 |
| 515 /** |
| 500 * @override | 516 * @override |
| 501 * @return {?WebInspector.SearchableView} | 517 * @return {?WebInspector.SearchableView} |
| 502 */ | 518 */ |
| 503 searchableView: function() | 519 searchableView: function() |
| 504 { | 520 { |
| 505 return this.visibleView && this.visibleView.searchableView ? this.visibl
eView.searchableView() : null; | 521 return this.visibleView && this.visibleView.searchableView ? this.visibl
eView.searchableView() : null; |
| 506 }, | 522 }, |
| 507 | 523 |
| 508 _createFileSelectorElement: function() | 524 _createFileSelectorElement: function() |
| 509 { | 525 { |
| (...skipping 752 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1262 WebInspector.ProfilesPanelFactory.prototype = { | 1278 WebInspector.ProfilesPanelFactory.prototype = { |
| 1263 /** | 1279 /** |
| 1264 * @override | 1280 * @override |
| 1265 * @return {!WebInspector.Panel} | 1281 * @return {!WebInspector.Panel} |
| 1266 */ | 1282 */ |
| 1267 createPanel: function() | 1283 createPanel: function() |
| 1268 { | 1284 { |
| 1269 return WebInspector.ProfilesPanel._instance(); | 1285 return WebInspector.ProfilesPanel._instance(); |
| 1270 } | 1286 } |
| 1271 } | 1287 } |
| OLD | NEW |