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

Side by Side Diff: chrome/browser/resources/md_bookmarks/folder_node.js

Issue 2912893002: MD Bookmarks: Support policies for disabling bookmark editing (Closed)
Patch Set: canEdit -> globalCanEdit Created 3 years, 6 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 unified diff | Download patch
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 Polymer({ 5 Polymer({
6 is: 'bookmarks-folder-node', 6 is: 'bookmarks-folder-node',
7 7
8 behaviors: [ 8 behaviors: [
9 bookmarks.StoreClient, 9 bookmarks.StoreClient,
10 ], 10 ],
(...skipping 61 matching lines...) Expand 10 before | Expand all | Expand 10 after
72 /** @return {HTMLElement} */ 72 /** @return {HTMLElement} */
73 getFocusTarget: function() { 73 getFocusTarget: function() {
74 return this.$.container; 74 return this.$.container;
75 }, 75 },
76 76
77 /** @return {HTMLElement} */ 77 /** @return {HTMLElement} */
78 getDropTarget: function() { 78 getDropTarget: function() {
79 return this.$.container; 79 return this.$.container;
80 }, 80 },
81 81
82 /** @return {boolean} */
83 isTopLevelFolder_: function() {
84 return this.depth == 0;
85 },
86
87 /** 82 /**
88 * @private 83 * @private
89 * @param {!Event} e 84 * @param {!Event} e
90 */ 85 */
91 onKeydown_: function(e) { 86 onKeydown_: function(e) {
92 var yDirection = 0; 87 var yDirection = 0;
93 var xDirection = 0; 88 var xDirection = 0;
94 var handled = true; 89 var handled = true;
95 if (e.key == 'ArrowUp') { 90 if (e.key == 'ArrowUp') {
96 yDirection = -1; 91 yDirection = -1;
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
340 }, 335 },
341 336
342 /** 337 /**
343 * @private 338 * @private
344 * @return {string} 339 * @return {string}
345 */ 340 */
346 getTabIndex_: function() { 341 getTabIndex_: function() {
347 return this.isSelectedFolder_ ? '0' : ''; 342 return this.isSelectedFolder_ ? '0' : '';
348 }, 343 },
349 }); 344 });
OLDNEW
« no previous file with comments | « chrome/browser/resources/md_bookmarks/folder_node.html ('k') | chrome/browser/resources/md_bookmarks/reducers.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698