| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a |
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. |
| 4 | 4 |
| 5 // Generated from namespace: app.window | 5 // Generated from namespace: app.window |
| 6 | 6 |
| 7 part of chrome; | 7 part of chrome; |
| 8 | 8 |
| 9 /** | 9 /** |
| 10 * Types | 10 * Types |
| (...skipping 17 matching lines...) Expand all Loading... |
| 28 /* | 28 /* |
| 29 * Private constructor | 29 * Private constructor |
| 30 */ | 30 */ |
| 31 AppWindowBounds._proxy(_jsObject) : super._proxy(_jsObject); | 31 AppWindowBounds._proxy(_jsObject) : super._proxy(_jsObject); |
| 32 | 32 |
| 33 /* | 33 /* |
| 34 * Public accessors | 34 * Public accessors |
| 35 */ | 35 */ |
| 36 int get left => JS('int', '#.left', this._jsObject); | 36 int get left => JS('int', '#.left', this._jsObject); |
| 37 | 37 |
| 38 void set left(int left) { | 38 set left(int left) { |
| 39 JS('void', '#.left = #', this._jsObject, left); | 39 JS('void', '#.left = #', this._jsObject, left); |
| 40 } | 40 } |
| 41 | 41 |
| 42 int get top => JS('int', '#.top', this._jsObject); | 42 int get top => JS('int', '#.top', this._jsObject); |
| 43 | 43 |
| 44 void set top(int top) { | 44 set top(int top) { |
| 45 JS('void', '#.top = #', this._jsObject, top); | 45 JS('void', '#.top = #', this._jsObject, top); |
| 46 } | 46 } |
| 47 | 47 |
| 48 int get width => JS('int', '#.width', this._jsObject); | 48 int get width => JS('int', '#.width', this._jsObject); |
| 49 | 49 |
| 50 void set width(int width) { | 50 set width(int width) { |
| 51 JS('void', '#.width = #', this._jsObject, width); | 51 JS('void', '#.width = #', this._jsObject, width); |
| 52 } | 52 } |
| 53 | 53 |
| 54 int get height => JS('int', '#.height', this._jsObject); | 54 int get height => JS('int', '#.height', this._jsObject); |
| 55 | 55 |
| 56 void set height(int height) { | 56 set height(int height) { |
| 57 JS('void', '#.height = #', this._jsObject, height); | 57 JS('void', '#.height = #', this._jsObject, height); |
| 58 } | 58 } |
| 59 | 59 |
| 60 } | 60 } |
| 61 | 61 |
| 62 class AppWindowCreateWindowOptions extends ChromeObject { | 62 class AppWindowCreateWindowOptions extends ChromeObject { |
| 63 /* | 63 /* |
| 64 * Public constructor | 64 * Public constructor |
| 65 */ | 65 */ |
| 66 AppWindowCreateWindowOptions({String id, int defaultWidth, int defaultHeight,
int defaultLeft, int defaultTop, int width, int height, int left, int top, int m
inWidth, int minHeight, int maxWidth, int maxHeight, String type, String frame,
AppWindowBounds bounds, bool transparentBackground, String state, bool hidden, b
ool resizable, bool singleton}) { | 66 AppWindowCreateWindowOptions({String id, int defaultWidth, int defaultHeight,
int defaultLeft, int defaultTop, int width, int height, int left, int top, int m
inWidth, int minHeight, int maxWidth, int maxHeight, String type, String frame,
AppWindowBounds bounds, bool transparentBackground, String state, bool hidden, b
ool resizable, bool singleton}) { |
| (...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 114 AppWindowCreateWindowOptions._proxy(_jsObject) : super._proxy(_jsObject); | 114 AppWindowCreateWindowOptions._proxy(_jsObject) : super._proxy(_jsObject); |
| 115 | 115 |
| 116 /* | 116 /* |
| 117 * Public accessors | 117 * Public accessors |
| 118 */ | 118 */ |
| 119 /// Id to identify the window. This will be used to remember the size and | 119 /// Id to identify the window. This will be used to remember the size and |
| 120 /// position of the window and restore that geometry when a window with the | 120 /// position of the window and restore that geometry when a window with the |
| 121 /// same id is later opened. | 121 /// same id is later opened. |
| 122 String get id => JS('String', '#.id', this._jsObject); | 122 String get id => JS('String', '#.id', this._jsObject); |
| 123 | 123 |
| 124 void set id(String id) { | 124 set id(String id) { |
| 125 JS('void', '#.id = #', this._jsObject, id); | 125 JS('void', '#.id = #', this._jsObject, id); |
| 126 } | 126 } |
| 127 | 127 |
| 128 /// Default width of the window. (Deprecated; regular bounds act like this | 128 /// Default width of the window. (Deprecated; regular bounds act like this |
| 129 /// now.) | 129 /// now.) |
| 130 int get defaultWidth => JS('int', '#.defaultWidth', this._jsObject); | 130 int get defaultWidth => JS('int', '#.defaultWidth', this._jsObject); |
| 131 | 131 |
| 132 void set defaultWidth(int defaultWidth) { | 132 set defaultWidth(int defaultWidth) { |
| 133 JS('void', '#.defaultWidth = #', this._jsObject, defaultWidth); | 133 JS('void', '#.defaultWidth = #', this._jsObject, defaultWidth); |
| 134 } | 134 } |
| 135 | 135 |
| 136 /// Default height of the window. (Deprecated; regular bounds act like this | 136 /// Default height of the window. (Deprecated; regular bounds act like this |
| 137 /// now.) | 137 /// now.) |
| 138 int get defaultHeight => JS('int', '#.defaultHeight', this._jsObject); | 138 int get defaultHeight => JS('int', '#.defaultHeight', this._jsObject); |
| 139 | 139 |
| 140 void set defaultHeight(int defaultHeight) { | 140 set defaultHeight(int defaultHeight) { |
| 141 JS('void', '#.defaultHeight = #', this._jsObject, defaultHeight); | 141 JS('void', '#.defaultHeight = #', this._jsObject, defaultHeight); |
| 142 } | 142 } |
| 143 | 143 |
| 144 /// Default X coordinate of the window. (Deprecated; regular bounds act like | 144 /// Default X coordinate of the window. (Deprecated; regular bounds act like |
| 145 /// this now.) | 145 /// this now.) |
| 146 int get defaultLeft => JS('int', '#.defaultLeft', this._jsObject); | 146 int get defaultLeft => JS('int', '#.defaultLeft', this._jsObject); |
| 147 | 147 |
| 148 void set defaultLeft(int defaultLeft) { | 148 set defaultLeft(int defaultLeft) { |
| 149 JS('void', '#.defaultLeft = #', this._jsObject, defaultLeft); | 149 JS('void', '#.defaultLeft = #', this._jsObject, defaultLeft); |
| 150 } | 150 } |
| 151 | 151 |
| 152 /// Default Y coordinate of the window. (Deprecated; regular bounds act like | 152 /// Default Y coordinate of the window. (Deprecated; regular bounds act like |
| 153 /// this now.) | 153 /// this now.) |
| 154 int get defaultTop => JS('int', '#.defaultTop', this._jsObject); | 154 int get defaultTop => JS('int', '#.defaultTop', this._jsObject); |
| 155 | 155 |
| 156 void set defaultTop(int defaultTop) { | 156 set defaultTop(int defaultTop) { |
| 157 JS('void', '#.defaultTop = #', this._jsObject, defaultTop); | 157 JS('void', '#.defaultTop = #', this._jsObject, defaultTop); |
| 158 } | 158 } |
| 159 | 159 |
| 160 /// Width of the window. (Deprecated; use 'bounds'.) | 160 /// Width of the window. (Deprecated; use 'bounds'.) |
| 161 int get width => JS('int', '#.width', this._jsObject); | 161 int get width => JS('int', '#.width', this._jsObject); |
| 162 | 162 |
| 163 void set width(int width) { | 163 set width(int width) { |
| 164 JS('void', '#.width = #', this._jsObject, width); | 164 JS('void', '#.width = #', this._jsObject, width); |
| 165 } | 165 } |
| 166 | 166 |
| 167 /// Height of the window. (Deprecated; use 'bounds'.) | 167 /// Height of the window. (Deprecated; use 'bounds'.) |
| 168 int get height => JS('int', '#.height', this._jsObject); | 168 int get height => JS('int', '#.height', this._jsObject); |
| 169 | 169 |
| 170 void set height(int height) { | 170 set height(int height) { |
| 171 JS('void', '#.height = #', this._jsObject, height); | 171 JS('void', '#.height = #', this._jsObject, height); |
| 172 } | 172 } |
| 173 | 173 |
| 174 /// X coordinate of the window. (Deprecated; use 'bounds'.) | 174 /// X coordinate of the window. (Deprecated; use 'bounds'.) |
| 175 int get left => JS('int', '#.left', this._jsObject); | 175 int get left => JS('int', '#.left', this._jsObject); |
| 176 | 176 |
| 177 void set left(int left) { | 177 set left(int left) { |
| 178 JS('void', '#.left = #', this._jsObject, left); | 178 JS('void', '#.left = #', this._jsObject, left); |
| 179 } | 179 } |
| 180 | 180 |
| 181 /// Y coordinate of the window. (Deprecated; use 'bounds'.) | 181 /// Y coordinate of the window. (Deprecated; use 'bounds'.) |
| 182 int get top => JS('int', '#.top', this._jsObject); | 182 int get top => JS('int', '#.top', this._jsObject); |
| 183 | 183 |
| 184 void set top(int top) { | 184 set top(int top) { |
| 185 JS('void', '#.top = #', this._jsObject, top); | 185 JS('void', '#.top = #', this._jsObject, top); |
| 186 } | 186 } |
| 187 | 187 |
| 188 /// Minimum width for the lifetime of the window. | 188 /// Minimum width for the lifetime of the window. |
| 189 int get minWidth => JS('int', '#.minWidth', this._jsObject); | 189 int get minWidth => JS('int', '#.minWidth', this._jsObject); |
| 190 | 190 |
| 191 void set minWidth(int minWidth) { | 191 set minWidth(int minWidth) { |
| 192 JS('void', '#.minWidth = #', this._jsObject, minWidth); | 192 JS('void', '#.minWidth = #', this._jsObject, minWidth); |
| 193 } | 193 } |
| 194 | 194 |
| 195 /// Minimum height for the lifetime of the window. | 195 /// Minimum height for the lifetime of the window. |
| 196 int get minHeight => JS('int', '#.minHeight', this._jsObject); | 196 int get minHeight => JS('int', '#.minHeight', this._jsObject); |
| 197 | 197 |
| 198 void set minHeight(int minHeight) { | 198 set minHeight(int minHeight) { |
| 199 JS('void', '#.minHeight = #', this._jsObject, minHeight); | 199 JS('void', '#.minHeight = #', this._jsObject, minHeight); |
| 200 } | 200 } |
| 201 | 201 |
| 202 /// Maximum width for the lifetime of the window. | 202 /// Maximum width for the lifetime of the window. |
| 203 int get maxWidth => JS('int', '#.maxWidth', this._jsObject); | 203 int get maxWidth => JS('int', '#.maxWidth', this._jsObject); |
| 204 | 204 |
| 205 void set maxWidth(int maxWidth) { | 205 set maxWidth(int maxWidth) { |
| 206 JS('void', '#.maxWidth = #', this._jsObject, maxWidth); | 206 JS('void', '#.maxWidth = #', this._jsObject, maxWidth); |
| 207 } | 207 } |
| 208 | 208 |
| 209 /// Maximum height for the lifetime of the window. | 209 /// Maximum height for the lifetime of the window. |
| 210 int get maxHeight => JS('int', '#.maxHeight', this._jsObject); | 210 int get maxHeight => JS('int', '#.maxHeight', this._jsObject); |
| 211 | 211 |
| 212 void set maxHeight(int maxHeight) { | 212 set maxHeight(int maxHeight) { |
| 213 JS('void', '#.maxHeight = #', this._jsObject, maxHeight); | 213 JS('void', '#.maxHeight = #', this._jsObject, maxHeight); |
| 214 } | 214 } |
| 215 | 215 |
| 216 /// Type of window to create. | 216 /// Type of window to create. |
| 217 String get type => JS('String', '#.type', this._jsObject); | 217 String get type => JS('String', '#.type', this._jsObject); |
| 218 | 218 |
| 219 void set type(String type) { | 219 set type(String type) { |
| 220 JS('void', '#.type = #', this._jsObject, type); | 220 JS('void', '#.type = #', this._jsObject, type); |
| 221 } | 221 } |
| 222 | 222 |
| 223 /// Frame type: 'none' or 'chrome' (defaults to 'chrome'). | 223 /// Frame type: 'none' or 'chrome' (defaults to 'chrome'). |
| 224 String get frame => JS('String', '#.frame', this._jsObject); | 224 String get frame => JS('String', '#.frame', this._jsObject); |
| 225 | 225 |
| 226 void set frame(String frame) { | 226 set frame(String frame) { |
| 227 JS('void', '#.frame = #', this._jsObject, frame); | 227 JS('void', '#.frame = #', this._jsObject, frame); |
| 228 } | 228 } |
| 229 | 229 |
| 230 /// Size and position of the content in the window (excluding the titlebar). I
f | 230 /// Size and position of the content in the window (excluding the titlebar). I
f |
| 231 /// an id is also specified and a window with a matching id has been shown | 231 /// an id is also specified and a window with a matching id has been shown |
| 232 /// before, the remembered bounds of the window will be used instead. | 232 /// before, the remembered bounds of the window will be used instead. |
| 233 AppWindowBounds get bounds => new AppWindowBounds._proxy(JS('', '#.bounds', th
is._jsObject)); | 233 AppWindowBounds get bounds => new AppWindowBounds._proxy(JS('', '#.bounds', th
is._jsObject)); |
| 234 | 234 |
| 235 void set bounds(AppWindowBounds bounds) { | 235 set bounds(AppWindowBounds bounds) { |
| 236 JS('void', '#.bounds = #', this._jsObject, convertArgument(bounds)); | 236 JS('void', '#.bounds = #', this._jsObject, convertArgument(bounds)); |
| 237 } | 237 } |
| 238 | 238 |
| 239 /// Enable window background transparency. Only supported in ash. Requires | 239 /// Enable window background transparency. Only supported in ash. Requires |
| 240 /// experimental API permission. | 240 /// experimental API permission. |
| 241 bool get transparentBackground => JS('bool', '#.transparentBackground', this._
jsObject); | 241 bool get transparentBackground => JS('bool', '#.transparentBackground', this._
jsObject); |
| 242 | 242 |
| 243 void set transparentBackground(bool transparentBackground) { | 243 set transparentBackground(bool transparentBackground) { |
| 244 JS('void', '#.transparentBackground = #', this._jsObject, transparentBackgro
und); | 244 JS('void', '#.transparentBackground = #', this._jsObject, transparentBackgro
und); |
| 245 } | 245 } |
| 246 | 246 |
| 247 /// The initial state of the window, allowing it to be created already | 247 /// The initial state of the window, allowing it to be created already |
| 248 /// fullscreen, maximized, or minimized. Defaults to 'normal'. | 248 /// fullscreen, maximized, or minimized. Defaults to 'normal'. |
| 249 String get state => JS('String', '#.state', this._jsObject); | 249 String get state => JS('String', '#.state', this._jsObject); |
| 250 | 250 |
| 251 void set state(String state) { | 251 set state(String state) { |
| 252 JS('void', '#.state = #', this._jsObject, state); | 252 JS('void', '#.state = #', this._jsObject, state); |
| 253 } | 253 } |
| 254 | 254 |
| 255 /// If true, the window will be created in a hidden state. Call show() on the | 255 /// If true, the window will be created in a hidden state. Call show() on the |
| 256 /// window to show it once it has been created. Defaults to false. | 256 /// window to show it once it has been created. Defaults to false. |
| 257 bool get hidden => JS('bool', '#.hidden', this._jsObject); | 257 bool get hidden => JS('bool', '#.hidden', this._jsObject); |
| 258 | 258 |
| 259 void set hidden(bool hidden) { | 259 set hidden(bool hidden) { |
| 260 JS('void', '#.hidden = #', this._jsObject, hidden); | 260 JS('void', '#.hidden = #', this._jsObject, hidden); |
| 261 } | 261 } |
| 262 | 262 |
| 263 /// If true, the window will be resizable by the user. Defaults to true. | 263 /// If true, the window will be resizable by the user. Defaults to true. |
| 264 bool get resizable => JS('bool', '#.resizable', this._jsObject); | 264 bool get resizable => JS('bool', '#.resizable', this._jsObject); |
| 265 | 265 |
| 266 void set resizable(bool resizable) { | 266 set resizable(bool resizable) { |
| 267 JS('void', '#.resizable = #', this._jsObject, resizable); | 267 JS('void', '#.resizable = #', this._jsObject, resizable); |
| 268 } | 268 } |
| 269 | 269 |
| 270 /// By default if you specify an id for the window, the window will only be | 270 /// By default if you specify an id for the window, the window will only be |
| 271 /// created if another window with the same id doesn't already exist. If a | 271 /// created if another window with the same id doesn't already exist. If a |
| 272 /// window with the same id already exists that window is activated instead. I
f | 272 /// window with the same id already exists that window is activated instead. I
f |
| 273 /// you do want to create multiple windows with the same id, you can set this | 273 /// you do want to create multiple windows with the same id, you can set this |
| 274 /// property to false. | 274 /// property to false. |
| 275 bool get singleton => JS('bool', '#.singleton', this._jsObject); | 275 bool get singleton => JS('bool', '#.singleton', this._jsObject); |
| 276 | 276 |
| 277 void set singleton(bool singleton) { | 277 set singleton(bool singleton) { |
| 278 JS('void', '#.singleton = #', this._jsObject, singleton); | 278 JS('void', '#.singleton = #', this._jsObject, singleton); |
| 279 } | 279 } |
| 280 | 280 |
| 281 } | 281 } |
| 282 | 282 |
| 283 class AppWindowAppWindow extends ChromeObject { | 283 class AppWindowAppWindow extends ChromeObject { |
| 284 /* | 284 /* |
| 285 * Private constructor | 285 * Private constructor |
| 286 */ | 286 */ |
| 287 AppWindowAppWindow._proxy(_jsObject) : super._proxy(_jsObject); | 287 AppWindowAppWindow._proxy(_jsObject) : super._proxy(_jsObject); |
| (...skipping 219 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 507 | 507 |
| 508 API_app_window(this._jsObject) { | 508 API_app_window(this._jsObject) { |
| 509 onBoundsChanged = new Event_app_window_onBoundsChanged(JS('', '#.onBoundsCha
nged', this._jsObject)); | 509 onBoundsChanged = new Event_app_window_onBoundsChanged(JS('', '#.onBoundsCha
nged', this._jsObject)); |
| 510 onClosed = new Event_app_window_onClosed(JS('', '#.onClosed', this._jsObject
)); | 510 onClosed = new Event_app_window_onClosed(JS('', '#.onClosed', this._jsObject
)); |
| 511 onFullscreened = new Event_app_window_onFullscreened(JS('', '#.onFullscreene
d', this._jsObject)); | 511 onFullscreened = new Event_app_window_onFullscreened(JS('', '#.onFullscreene
d', this._jsObject)); |
| 512 onMaximized = new Event_app_window_onMaximized(JS('', '#.onMaximized', this.
_jsObject)); | 512 onMaximized = new Event_app_window_onMaximized(JS('', '#.onMaximized', this.
_jsObject)); |
| 513 onMinimized = new Event_app_window_onMinimized(JS('', '#.onMinimized', this.
_jsObject)); | 513 onMinimized = new Event_app_window_onMinimized(JS('', '#.onMinimized', this.
_jsObject)); |
| 514 onRestored = new Event_app_window_onRestored(JS('', '#.onRestored', this._js
Object)); | 514 onRestored = new Event_app_window_onRestored(JS('', '#.onRestored', this._js
Object)); |
| 515 } | 515 } |
| 516 } | 516 } |
| OLD | NEW |