OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 cr.exportPath('options'); | 5 cr.exportPath('options'); |
6 | 6 |
7 /** | 7 /** |
8 * @typedef {{ | 8 * @typedef {{ |
9 * availableColorProfiles: Array<{profileId: number, name: string}>, | 9 * availableColorProfiles: Array<{profileId: number, name: string}>, |
10 * colorProfile: number, | 10 * colorProfile: number, |
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
120 | 120 |
121 DisplayOptions.prototype = { | 121 DisplayOptions.prototype = { |
122 __proto__: Page.prototype, | 122 __proto__: Page.prototype, |
123 | 123 |
124 /** | 124 /** |
125 * Whether the current output status is mirroring displays or not. | 125 * Whether the current output status is mirroring displays or not. |
126 * @private | 126 * @private |
127 */ | 127 */ |
128 mirroring_: false, | 128 mirroring_: false, |
129 | 129 |
130 /* | 130 /** |
131 * Whether the unified desktop is enable or not. | 131 * Whether the unified desktop is enable or not. |
132 * @private | 132 * @private |
133 */ | 133 */ |
134 unifiedDesktopEnabled_: false, | 134 unifiedDesktopEnabled_: false, |
135 | 135 |
136 /* | 136 /** |
137 * Whether the unified desktop option should be present. | 137 * Whether the unified desktop option should be present. |
138 * @private | 138 * @private |
139 */ | 139 */ |
140 showUnifiedDesktopOption_: false, | 140 showUnifiedDesktopOption_: false, |
141 | 141 |
142 /** | 142 /** |
143 * The current secondary display layout. | 143 * The current secondary display layout. |
144 * @private | 144 * @private |
145 */ | 145 */ |
146 layout_: options.SecondaryDisplayLayout.RIGHT, | 146 layout_: options.SecondaryDisplayLayout.RIGHT, |
(...skipping 811 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
958 offset.y + 'px'; | 958 offset.y + 'px'; |
959 break; | 959 break; |
960 } | 960 } |
961 this.secondaryDisplay_.originalPosition = { | 961 this.secondaryDisplay_.originalPosition = { |
962 x: secondaryDiv.offsetLeft, y: secondaryDiv.offsetTop}; | 962 x: secondaryDiv.offsetLeft, y: secondaryDiv.offsetTop}; |
963 } | 963 } |
964 }, | 964 }, |
965 | 965 |
966 /** | 966 /** |
967 * Called when the display arrangement has changed. | 967 * Called when the display arrangement has changed. |
968 * @param {options.MultiDisplayMode} multi display mode. | 968 * @param {options.MultiDisplayMode} mode multi display mode. |
969 * @param {Array<options.DisplayInfo>} displays The list of the display | 969 * @param {Array<options.DisplayInfo>} displays The list of the display |
970 * information. | 970 * information. |
971 * @param {options.SecondaryDisplayLayout} layout The layout strategy. | 971 * @param {options.SecondaryDisplayLayout} layout The layout strategy. |
972 * @param {number} offset The offset of the secondary display. | 972 * @param {number} offset The offset of the secondary display. |
973 * @private | 973 * @private |
974 */ | 974 */ |
975 onDisplayChanged_: function(mode, displays, layout, offset) { | 975 onDisplayChanged_: function(mode, displays, layout, offset) { |
976 if (!this.visible) | 976 if (!this.visible) |
977 return; | 977 return; |
978 | 978 |
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1035 mode, displays, layout, offset) { | 1035 mode, displays, layout, offset) { |
1036 DisplayOptions.getInstance().onDisplayChanged_( | 1036 DisplayOptions.getInstance().onDisplayChanged_( |
1037 mode, displays, layout, offset); | 1037 mode, displays, layout, offset); |
1038 }; | 1038 }; |
1039 | 1039 |
1040 // Export | 1040 // Export |
1041 return { | 1041 return { |
1042 DisplayOptions: DisplayOptions | 1042 DisplayOptions: DisplayOptions |
1043 }; | 1043 }; |
1044 }); | 1044 }); |
OLD | NEW |