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

Unified Diff: chrome/test/data/chromeos/demo_app/js/background.js

Issue 205713002: Add a basic demo mode browser test. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 years, 9 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/test/data/chromeos/demo_app/html/background.html ('k') | chromeos/chromeos_switches.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/test/data/chromeos/demo_app/js/background.js
diff --git a/chrome/test/data/chromeos/demo_app/js/background.js b/chrome/test/data/chromeos/demo_app/js/background.js
new file mode 100644
index 0000000000000000000000000000000000000000..0d4516cf0f0b7224bcc0dfc3a4e6a8bf136b34a9
--- /dev/null
+++ b/chrome/test/data/chromeos/demo_app/js/background.js
@@ -0,0 +1,14 @@
+/**
+ * Copyright 2014 The Chromium OS Authors. All rights reserved.
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+chrome.app.runtime.onLaunched.addListener(function() {
+ console.log('Demo app launched.');
xiyuan 2014/03/20 21:59:44 nit: This might not be needed though since no one
rkc 2014/03/20 22:04:45 Done.
+ chrome.app.window.create('html/background.html', {'state': 'fullscreen'},
+ function() {
+ console.log('Demo app window created.');
+ chrome.test.sendMessage('launchedDemoApp');
+ });
+});
« no previous file with comments | « chrome/test/data/chromeos/demo_app/html/background.html ('k') | chromeos/chromeos_switches.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698