Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(421)

Unified Diff: third_party/WebKit/Source/devtools/front_end/resources/DOMStorageItemsView.js

Issue 2662403002: [DevTools] Merge filter bar with the main toolbar (Closed)
Patch Set: [DevTools] Merge filter bar with the main toolbar Created 3 years, 11 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: third_party/WebKit/Source/devtools/front_end/resources/DOMStorageItemsView.js
diff --git a/third_party/WebKit/Source/devtools/front_end/resources/DOMStorageItemsView.js b/third_party/WebKit/Source/devtools/front_end/resources/DOMStorageItemsView.js
index 22e6266ea02d08693985038283a69de89d00cabe..d2796cdc9dd633aa15a634f114cf044fb0e7d634 100644
--- a/third_party/WebKit/Source/devtools/front_end/resources/DOMStorageItemsView.js
+++ b/third_party/WebKit/Source/devtools/front_end/resources/DOMStorageItemsView.js
@@ -164,8 +164,10 @@ Resources.DOMStorageItemsView = class extends Resources.StorageItemsView {
if (!selectedNode || key === selectedKey)
selectedNode = node;
}
- if (selectedNode)
- selectedNode.selected = true;
+ if (selectedNode) {
+ selectedNode.select();
+ selectedNode.reveal();
+ }
this._dataGrid.addCreationNode(false);
this.setCanDeleteSelected(!!selectedNode);
}
@@ -226,4 +228,17 @@ Resources.DOMStorageItemsView = class extends Resources.StorageItemsView {
if (this._domStorage)
this._domStorage.removeItem(node.data.key);
}
+
+ /**
+ * @override
+ */
+ focusGrid() {
+ if (!this._dataGrid)
+ return;
+ var root = this._dataGrid.rootNode();
+ if (root.children.length === 0)
dgozman 2017/02/03 20:54:53 Make it similar to another place: if (!this._data
eostroukhov 2017/02/03 22:59:25 Done.
+ return;
+ root.children[0].select();
+ this._dataGrid.element.focus();
+ }
};

Powered by Google App Engine
This is Rietveld 408576698