Index: remoting/webapp/crd/js/app_launcher.js |
diff --git a/remoting/webapp/crd/js/app_launcher.js b/remoting/webapp/crd/js/app_launcher.js |
index 29589dfc45f6f8d9ba358d02e4d37b5a6cf75be5..ed93d449f0e3fa077117ed57a2ada03caaa640f6 100644 |
--- a/remoting/webapp/crd/js/app_launcher.js |
+++ b/remoting/webapp/crd/js/app_launcher.js |
@@ -105,20 +105,27 @@ remoting.V2AppLauncher.prototype.launch = function(opt_launchArgs) { |
* @param {function(*=):void} reject |
*/ |
return new Promise(function(resolve, reject) { |
- chrome.app.window.create(url, { |
- 'width': 800, |
- 'height': 600, |
- 'frame': 'none', |
- 'id': String(remoting.V2AppLauncher.nextWindowId_++) |
- }, |
- /** @param {AppWindow=} appWindow */ |
- function(appWindow) { |
- if (!appWindow) { |
- reject(new Error(chrome.runtime.lastError.message)); |
- } else { |
- resolve(appWindow.id); |
- } |
- }); |
+ var START_FULLSCREEN = 'start-fullscreen'; |
+ /** @param {Object} values */ |
+ var onValues = function(values) { |
+ /** @type {string} */ |
+ var state = values[START_FULLSCREEN] ? 'fullscreen' : 'normal'; |
Jamie
2015/01/23 22:37:24
As discussed, this currently doesn't work due to c
kelvinp
2015/01/23 23:39:58
Should we wait for the apps team before making thi
Jamie
2015/01/24 00:46:35
I decided to go ahead and implement the workaround
|
+ chrome.app.window.create(url, { |
+ 'width': 800, 'height': 600, |
+ 'frame': 'none', |
+ 'id': String(remoting.V2AppLauncher.nextWindowId_++), |
+ 'state': state |
+ }, |
+ /** @param {AppWindow=} appWindow */ |
+ function(appWindow) { |
+ if (!appWindow) { |
+ reject(new Error(chrome.runtime.lastError.message)); |
+ } else { |
+ resolve(appWindow.id); |
+ } |
+ }); |
+ }; |
+ chrome.storage.local.get(START_FULLSCREEN, onValues); |
}); |
}; |