Add accesskeys accessibility implementation. Need to keep adding other pages, especi...
[squirrelmail.git] / include / options / accessibility.php
1 <?php
2
3 /**
4 * options_accessibility.php
5 *
6 * Displays all options concerning accessibility features in SquirrelMail.
7 *
8 * @copyright &copy; 1999-2007 The SquirrelMail Project Team
9 * @license http://opensource.org/licenses/gpl-license.php GNU Public License
10 * @version $Id$
11 * @package squirrelmail
12 */
13
14 /** Define the group constants for this options page. */
15 define('SMOPT_GRP_ACCESSKEYS_READ_MESSAGE', 0);
16 define('SMOPT_GRP_ACCESSKEYS_COMPOSE', 1);
17
18 /**
19 * This function builds an array with all the information about
20 * the options available to the user, and returns it. The options
21 * are grouped by the groups in which they are displayed.
22 * For each option, the following information is stored:
23 * - name: the internal (variable) name
24 * - caption: the description of the option in the UI
25 * - type: one of SMOPT_TYPE_*
26 * - refresh: one of SMOPT_REFRESH_*
27 * - size: one of SMOPT_SIZE_*
28 * - save: the name of a function to call when saving this option
29 * @return array all option information
30 */
31 function load_optpage_data_accessibility() {
32
33 global $a_to_z;
34 $my_a_to_z = array_merge(array('NONE' => _("Not used")), $a_to_z);
35
36 /* Build a simple array into which we will build options. */
37 $optgrps = array();
38 $optvals = array();
39
40 /******************************************************/
41 /* LOAD EACH GROUP OF OPTIONS INTO THE OPTIONS ARRAY. */
42 /******************************************************/
43
44 /*** Load the Access Key Options for the Read Message page into the array ***/
45 $optgrps[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE] = _("Access Keys For Read Message Screen");
46 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE] = array();
47
48 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
49 'name' => 'accesskey_read_msg_reply',
50 'caption' => _("Reply"),
51 'type' => SMOPT_TYPE_STRLIST,
52 'refresh' => SMOPT_REFRESH_NONE,
53 'size' => SMOPT_SIZE_TINY,
54 'posvals' => $my_a_to_z,
55 );
56
57 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
58 'name' => 'accesskey_read_msg_reply_all',
59 'caption' => _("Reply All"),
60 'type' => SMOPT_TYPE_STRLIST,
61 'refresh' => SMOPT_REFRESH_NONE,
62 'size' => SMOPT_SIZE_TINY,
63 'posvals' => $my_a_to_z,
64 );
65
66 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
67 'name' => 'accesskey_read_msg_forward',
68 'caption' => _("Forward"),
69 'type' => SMOPT_TYPE_STRLIST,
70 'refresh' => SMOPT_REFRESH_NONE,
71 'size' => SMOPT_SIZE_TINY,
72 'posvals' => $my_a_to_z,
73 );
74
75 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
76 'name' => 'accesskey_read_msg_as_attach',
77 'caption' => _("As Attachment"),
78 'type' => SMOPT_TYPE_STRLIST,
79 'refresh' => SMOPT_REFRESH_NONE,
80 'size' => SMOPT_SIZE_TINY,
81 'posvals' => $my_a_to_z,
82 );
83
84 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
85 'name' => 'accesskey_read_msg_delete',
86 'caption' => _("Delete"),
87 'type' => SMOPT_TYPE_STRLIST,
88 'refresh' => SMOPT_REFRESH_NONE,
89 'size' => SMOPT_SIZE_TINY,
90 'posvals' => $my_a_to_z,
91 );
92
93 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
94 'name' => 'accesskey_read_msg_bypass_trash',
95 'caption' => _("Bypass Trash"),
96 'type' => SMOPT_TYPE_STRLIST,
97 'refresh' => SMOPT_REFRESH_NONE,
98 'size' => SMOPT_SIZE_TINY,
99 'posvals' => $my_a_to_z,
100 );
101
102 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
103 'name' => 'accesskey_read_msg_move_to',
104 'caption' => _("Move To"),
105 'type' => SMOPT_TYPE_STRLIST,
106 'refresh' => SMOPT_REFRESH_NONE,
107 'size' => SMOPT_SIZE_TINY,
108 'posvals' => $my_a_to_z,
109 );
110
111 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
112 'name' => 'accesskey_read_msg_move',
113 'caption' => _("Move"),
114 'type' => SMOPT_TYPE_STRLIST,
115 'refresh' => SMOPT_REFRESH_NONE,
116 'size' => SMOPT_SIZE_TINY,
117 'posvals' => $my_a_to_z,
118 );
119
120 $optvals[SMOPT_GRP_ACCESSKEYS_READ_MESSAGE][] = array(
121 'name' => 'accesskey_read_msg_copy',
122 'caption' => _("Copy"),
123 'type' => SMOPT_TYPE_STRLIST,
124 'refresh' => SMOPT_REFRESH_NONE,
125 'size' => SMOPT_SIZE_TINY,
126 'posvals' => $my_a_to_z,
127 );
128
129
130 /*** Load the Access Key Options for the Compose page into the array ***/
131 $optgrps[SMOPT_GRP_ACCESSKEYS_COMPOSE] = _("Access Keys For Compose Screen");
132 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE] = array();
133
134 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
135 'name' => 'accesskey_compose_to',
136 'caption' => _("To"),
137 'type' => SMOPT_TYPE_STRLIST,
138 'refresh' => SMOPT_REFRESH_NONE,
139 'size' => SMOPT_SIZE_TINY,
140 'posvals' => $my_a_to_z,
141 );
142
143 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
144 'name' => 'accesskey_compose_cc',
145 'caption' => _("Cc"),
146 'type' => SMOPT_TYPE_STRLIST,
147 'refresh' => SMOPT_REFRESH_NONE,
148 'size' => SMOPT_SIZE_TINY,
149 'posvals' => $my_a_to_z,
150 );
151
152 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
153 'name' => 'accesskey_compose_bcc',
154 'caption' => _("Bcc"),
155 'type' => SMOPT_TYPE_STRLIST,
156 'refresh' => SMOPT_REFRESH_NONE,
157 'size' => SMOPT_SIZE_TINY,
158 'posvals' => $my_a_to_z,
159 );
160
161 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
162 'name' => 'accesskey_compose_subject',
163 'caption' => _("Subject"),
164 'type' => SMOPT_TYPE_STRLIST,
165 'refresh' => SMOPT_REFRESH_NONE,
166 'size' => SMOPT_SIZE_TINY,
167 'posvals' => $my_a_to_z,
168 );
169
170 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
171 'name' => 'accesskey_compose_priority',
172 'caption' => _("Priority"),
173 'type' => SMOPT_TYPE_STRLIST,
174 'refresh' => SMOPT_REFRESH_NONE,
175 'size' => SMOPT_SIZE_TINY,
176 'posvals' => $my_a_to_z,
177 );
178
179 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
180 'name' => 'accesskey_compose_on_read',
181 'caption' => _("On Read"),
182 'type' => SMOPT_TYPE_STRLIST,
183 'refresh' => SMOPT_REFRESH_NONE,
184 'size' => SMOPT_SIZE_TINY,
185 'posvals' => $my_a_to_z,
186 );
187
188 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
189 'name' => 'accesskey_compose_on_delivery',
190 'caption' => _("On Delivery"),
191 'type' => SMOPT_TYPE_STRLIST,
192 'refresh' => SMOPT_REFRESH_NONE,
193 'size' => SMOPT_SIZE_TINY,
194 'posvals' => $my_a_to_z,
195 );
196
197 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
198 'name' => 'accesskey_compose_signature',
199 'caption' => _("Signature"),
200 'type' => SMOPT_TYPE_STRLIST,
201 'refresh' => SMOPT_REFRESH_NONE,
202 'size' => SMOPT_SIZE_TINY,
203 'posvals' => $my_a_to_z,
204 );
205
206 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
207 'name' => 'accesskey_compose_addresses',
208 'caption' => _("Addresses"),
209 'type' => SMOPT_TYPE_STRLIST,
210 'refresh' => SMOPT_REFRESH_NONE,
211 'size' => SMOPT_SIZE_TINY,
212 'posvals' => $my_a_to_z,
213 );
214
215 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
216 'name' => 'accesskey_compose_save_draft',
217 'caption' => _("Save Draft"),
218 'type' => SMOPT_TYPE_STRLIST,
219 'refresh' => SMOPT_REFRESH_NONE,
220 'size' => SMOPT_SIZE_TINY,
221 'posvals' => $my_a_to_z,
222 );
223
224 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
225 'name' => 'accesskey_compose_send',
226 'caption' => _("Send"),
227 'type' => SMOPT_TYPE_STRLIST,
228 'refresh' => SMOPT_REFRESH_NONE,
229 'size' => SMOPT_SIZE_TINY,
230 'posvals' => $my_a_to_z,
231 );
232
233 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
234 'name' => 'accesskey_compose_body',
235 'caption' => _("Body"),
236 'type' => SMOPT_TYPE_STRLIST,
237 'refresh' => SMOPT_REFRESH_NONE,
238 'size' => SMOPT_SIZE_TINY,
239 'posvals' => $my_a_to_z,
240 );
241
242 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
243 'name' => 'accesskey_compose_attach_browse',
244 'caption' => _("Browse"),
245 'type' => SMOPT_TYPE_STRLIST,
246 'refresh' => SMOPT_REFRESH_NONE,
247 'size' => SMOPT_SIZE_TINY,
248 'posvals' => $my_a_to_z,
249 );
250
251 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
252 'name' => 'accesskey_compose_attach',
253 'caption' => _("Attach"),
254 'type' => SMOPT_TYPE_STRLIST,
255 'refresh' => SMOPT_REFRESH_NONE,
256 'size' => SMOPT_SIZE_TINY,
257 'posvals' => $my_a_to_z,
258 );
259
260 $optvals[SMOPT_GRP_ACCESSKEYS_COMPOSE][] = array(
261 'name' => 'accesskey_compose_delete_attach',
262 'caption' => _("Delete Selected Attachments"),
263 'type' => SMOPT_TYPE_STRLIST,
264 'refresh' => SMOPT_REFRESH_NONE,
265 'size' => SMOPT_SIZE_TINY,
266 'posvals' => $my_a_to_z,
267 );
268
269
270 /* Assemble all this together and return it as our result. */
271 $result = array(
272 'grps' => $optgrps,
273 'vals' => $optvals
274 );
275 return ($result);
276 }
277
278 /******************************************************************/
279 /** Define any specialized save functions for this option page. ***/
280 /** ***/
281 /** You must add every function that is set in save parameter ***/
282 /******************************************************************/
283