OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 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 * @fileoverview | 6 * @fileoverview |
7 * 'settings-users-page' is the settings page for managing user accounts on | 7 * 'settings-users-page' is the settings page for managing user accounts on |
8 * the device. | 8 * the device. |
9 */ | 9 */ |
10 Polymer({ | 10 Polymer({ |
(...skipping 34 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
45 | 45 |
46 /** | 46 /** |
47 * @param {!Event} e | 47 * @param {!Event} e |
48 * @private | 48 * @private |
49 */ | 49 */ |
50 openAddUserDialog_: function(e) { | 50 openAddUserDialog_: function(e) { |
51 e.preventDefault(); | 51 e.preventDefault(); |
52 this.$.addUserDialog.open(); | 52 this.$.addUserDialog.open(); |
53 }, | 53 }, |
54 | 54 |
| 55 /** @private */ |
| 56 onAddUserDialogClose_: function() { |
| 57 this.$$('#add-user-button a').focus(); |
| 58 }, |
| 59 |
55 /** | 60 /** |
56 * @param {boolean} isOwner | 61 * @param {boolean} isOwner |
57 * @param {boolean} isWhitelistManaged | 62 * @param {boolean} isWhitelistManaged |
58 * @private | 63 * @private |
59 * @return {boolean} | 64 * @return {boolean} |
60 */ | 65 */ |
61 isEditingDisabled_: function(isOwner, isWhitelistManaged) { | 66 isEditingDisabled_: function(isOwner, isWhitelistManaged) { |
62 return !isOwner || isWhitelistManaged; | 67 return !isOwner || isWhitelistManaged; |
63 }, | 68 }, |
64 | 69 |
65 /** | 70 /** |
66 * @param {boolean} isOwner | 71 * @param {boolean} isOwner |
67 * @param {boolean} isWhitelistManaged | 72 * @param {boolean} isWhitelistManaged |
68 * @param {boolean} allowGuest | 73 * @param {boolean} allowGuest |
69 * @private | 74 * @private |
70 * @return {boolean} | 75 * @return {boolean} |
71 */ | 76 */ |
72 isEditingUsersDisabled_: function(isOwner, isWhitelistManaged, allowGuest) { | 77 isEditingUsersDisabled_: function(isOwner, isWhitelistManaged, allowGuest) { |
73 return !isOwner || isWhitelistManaged || allowGuest; | 78 return !isOwner || isWhitelistManaged || allowGuest; |
74 } | 79 } |
75 }); | 80 }); |
OLD | NEW |