Revision 24578,
1.3 KB
checked in by rbasch, 14 years ago
(diff) |
In kiosk:
* Add session management support via the D-Bus interface to the
gdm launcher, so it terminates upon the end of the gdm session.
(Trac: #548)
* Make r-kiosk work in Firefox 3.6, by supplying a chrome.manifest
and disabling the version-specific compatibility check.
(Trac: #571)
|
Line | |
---|
1 | #!/bin/sh |
---|
2 | |
---|
3 | # This is the xinit script for the kiosk user. |
---|
4 | |
---|
5 | datadir=/usr/share/debathena-kiosk |
---|
6 | |
---|
7 | # The rkiosk extension's unique ID, and the location of its xpi file. |
---|
8 | rkiosk_id="{4D498D0A-05AD-4fdb-97B5-8A0AABC1FC5B}" |
---|
9 | rkiosk_xpi=$datadir/r-kiosk.xpi |
---|
10 | |
---|
11 | # File with preferences to set in the firefox profile. |
---|
12 | prefs="$datadir/prefs.js" |
---|
13 | |
---|
14 | # User chrome (UI customizations) file. |
---|
15 | chrome="$datadir/userChrome.css" |
---|
16 | |
---|
17 | cd || exit 1 |
---|
18 | |
---|
19 | exec > xinit.log 2>&1 |
---|
20 | |
---|
21 | XAUTHORITY=$HOME/.Xauthority |
---|
22 | export XAUTHORITY |
---|
23 | |
---|
24 | # Run a window manager so that firefox fullscreen mode works. |
---|
25 | metacity --sm-disable & |
---|
26 | |
---|
27 | # Create a new firefox profile. |
---|
28 | rm -rf .mozilla |
---|
29 | firefox -CreateProfile default > /dev/null || exit 1 |
---|
30 | profdir=$(find .mozilla/firefox -type d -name \*.default) |
---|
31 | |
---|
32 | # Add the rkiosk extension. |
---|
33 | rkiosk_dir="$profdir/extensions/$rkiosk_id" |
---|
34 | mkdir -p "$rkiosk_dir" |
---|
35 | (cd "$rkiosk_dir" && unzip "$rkiosk_xpi") || exit 1 |
---|
36 | cat <<EOF >> "$profdir/extensions.ini" |
---|
37 | [ExtensionDirs] |
---|
38 | Extension0=$rkiosk_dir |
---|
39 | EOF |
---|
40 | |
---|
41 | # Firefox 3.6+ requires a chrome.manifest for the extension. |
---|
42 | if [ ! -e "$rkiosk_dir/chrome.manifest" ]; then |
---|
43 | cp "$datadir/chrome.manifest.r-kiosk" "$rkiosk_dir/chrome.manifest" || exit 1 |
---|
44 | fi |
---|
45 | |
---|
46 | # Apply our preference settings and UI customizations. |
---|
47 | cat "$prefs" >> "$profdir/prefs.js" || exit 1 |
---|
48 | cp "$chrome" "$profdir/chrome/userChrome.css" || exit 1 |
---|
49 | |
---|
50 | # Launch firefox. |
---|
51 | firefox |
---|
52 | |
---|
53 | # Clean up. |
---|
54 | rm -rf .mozilla |
---|
Note: See
TracBrowser
for help on using the repository browser.