forked from dnschneid/crouton
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtouch
123 lines (121 loc) · 4.27 KB
/
touch
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
#!/bin/sh -e
# Copyright (c) 2016 The crouton Authors. All rights reserved.
# Use of this source code is governed by a BSD-style license that can be
# found in the LICENSE file.
if [ "${TARGETNOINSTALL:-c}" = 'c' ] &&
[ "$DISTRO" = 'debian' -o "$DISTRO" = 'kali' ]; then
error 99 "touch target is not supported on Debian."
fi
REQUIRES='x11'
DESCRIPTION='Touchscreen and limited generic gesture support.'
. "${TARGETSDIR:="$PWD"}/common"
### Append to prepare.sh:
if release -lt raring; then
# As of 2013-01-30, pre-Raring touchegg is useless. Download it manually.
install_mirror_package 'touchegg' 'pool/universe/t/touchegg'
else
install --minimal touchegg
fi
# The global config file.
cat > /etc/touchegg.conf <<EOF
<touchégg>
<settings>
<property name="composed_gestures_time">0</property>
</settings>
<application name="All">
<gesture type="DRAG" fingers="1" direction="ALL">
<action type="SCROLL">SPEED=5:INVERTED=true</action>
</gesture>
<gesture type="PINCH" fingers="5" direction="OUT">
<action type="SHOW_DESKTOP"></action>
</gesture>
<gesture type="DRAG" fingers="5" direction="UP">
<action type="SHOW_DESKTOP"></action>
</gesture>
<gesture type="PINCH" fingers="4" direction="IN">
<action type="MINIMIZE_WINDOW"></action>
</gesture>
<gesture type="PINCH" fingers="4" direction="OUT">
<action type="MAXIMIZE_RESTORE_WINDOW"></action>
</gesture>
<gesture type="DRAG" fingers="4" direction="LEFT">
<action type="MOVE_WINDOW"></action>
</gesture>
<gesture type="PINCH" fingers="5" direction="IN">
<action type="CLOSE_WINDOW"></action>
</gesture>
<gesture type="DRAG" fingers="5" direction="DOWN">
<action type="CLOSE_WINDOW"></action>
</gesture>
<gesture type="DRAG" fingers="4" direction="DOWN">
<action type="MINIMIZE_WINDOW"></action>
</gesture>
<gesture type="DRAG" fingers="4" direction="UP">
<action type="MAXIMIZE_RESTORE_WINDOW"></action>
</gesture>
<gesture type="TAP" fingers="3" direction="">
<action type="MOUSE_CLICK">BUTTON=2</action>
</gesture>
<gesture type="TAP" fingers="2" direction="">
<action type="MOUSE_CLICK">BUTTON=3</action>
</gesture>
<gesture type="DRAG" fingers="3" direction="ALL">
<action type="CHANGE_DESKTOP"></action>
</gesture>
<gesture type="TAP" fingers="1" direction="">
<action type="MOUSE_CLICK">BUTTON=1</action>
</gesture>
<gesture type="DRAG" fingers="4" direction="RIGHT">
<action type="MOVE_WINDOW"></action>
</gesture>
</application>
<application name="Okular, Gwenview">
<gesture type="ROTATE" fingers="2" direction="LEFT">
<action type="SEND_KEYS">Control+L</action>
</gesture>
<gesture type="PINCH" fingers="2" direction="IN">
<action type="SEND_KEYS">Control+KP_Add</action>
</gesture>
<gesture type="PINCH" fingers="2" direction="OUT">
<action type="SEND_KEYS">Control+KP_Subtract</action>
</gesture>
<gesture type="ROTATE" fingers="2" direction="RIGHT">
<action type="SEND_KEYS">Control+R</action>
</gesture>
</application>
<application name="Google-chrome, Firefox, Dolphin, Chromium-browser">
<gesture type="DRAG" fingers="2" direction="DOWN">
<action type="SEND_KEYS">Control+minus</action>
</gesture>
<gesture type="PINCH" fingers="2" direction="IN">
<action type="SEND_KEYS">Control+minus</action>
</gesture>
<gesture type="PINCH" fingers="2" direction="OUT">
<action type="SEND_KEYS">Control+equal</action>
</gesture>
<gesture type="DRAG" fingers="2" direction="RIGHT">
<action type="SEND_KEYS">Alt+Left</action>
</gesture>
<gesture type="DRAG" fingers="2" direction="UP">
<action type="SEND_KEYS">Control+equal</action>
</gesture>
<gesture type="DRAG" fingers="2" direction="LEFT">
<action type="SEND_KEYS">Alt+Right</action>
</gesture>
</application>
<application name="Evince">
<gesture type="ROTATE" fingers="2" direction="LEFT">
<action type="SEND_KEYS">Control+Right</action>
</gesture>
<gesture type="PINCH" fingers="2" direction="IN">
<action type="SEND_KEYS">Control+KP_Add</action>
</gesture>
<gesture type="PINCH" fingers="2" direction="OUT">
<action type="SEND_KEYS">Control+KP_Subtract</action>
</gesture>
<gesture type="ROTATE" fingers="2" direction="RIGHT">
<action type="SEND_KEYS">Control+Left</action>
</gesture>
</application>
</touchégg>
EOF