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

Unified Diff: docs/kiosk_mode.md

Issue 1309473002: WIP: Migrate Wiki content over to src/docs (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 4 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 | « docs/ipc_fuzzer.md ('k') | docs/layout_tests_linux.md » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: docs/kiosk_mode.md
diff --git a/docs/kiosk_mode.md b/docs/kiosk_mode.md
new file mode 100644
index 0000000000000000000000000000000000000000..55bc39caab7aa58c719a8a3087677e6a585cca04
--- /dev/null
+++ b/docs/kiosk_mode.md
@@ -0,0 +1,85 @@
+## Introduction
+
+If you have a real world kiosk application that you want to run on Google Chrome, then below are the steps to take to simulate kiosk mode.
+
+
+## Steps to Simulate Kiosk Mode
+
+### Step 1
+
+Compile the following Java code:
+
+```
+import java.awt.*;
+import java.applet.*;
+import java.security.*;
+import java.awt.event.*;
+
+public class FullScreen extends Applet
+{
+ public void fullScreen()
+ {
+ AccessController.doPrivileged
+ (
+ new PrivilegedAction()
+ {
+ public Object run()
+ {
+ try
+ {
+ Robot robot = new Robot();
+ robot.keyPress(KeyEvent.VK_F11);
+ }
+ catch (AWTException e)
+ {
+ e.printStackTrace();
+ }
+ return null;
+ }
+ }
+ );
+ }
+}
+```
+
+### Step 2
+
+Include it in an applet on your kiosk application's home page:
+
+```
+<applet name="appletFullScreen" code="FullScreen.class" width="1" height="1"></applet>
+```
+
+### Step 3
+
+Add the following to the kiosk computer's java.policy file:
+
+```
+grant codeBase "http://yourservername/*"
+{
+ permission java.security.AllPermission;
+};
+```
+
+### Step 4
+
+Include the following JavaScript and assign the doLoad function to the onload event:
+
+```
+var _appletFullScreen;
+
+function doLoad()
+{
+ _appletFullScreen = document.applets[0];
+ doFullScreen();
+}
+
+function doFullScreen()
+{
+ if (_appletFullScreen && _appletFullScreen.fullScreen)
+ {
+// Add an if statement to check whether document.body.clientHeight is not indicative of full screen mode
+ _appletFullScreen.fullScreen();
+ }
+}
+```
« no previous file with comments | « docs/ipc_fuzzer.md ('k') | docs/layout_tests_linux.md » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698