- add sources.
[platform/framework/web/crosswalk.git] / src / chrome / common / extensions / docs / examples / api / downloads / download_filename_controller / options.html
1 <!doctype html>
2 <html>
3 <head>
4 <title>Download Filename Controller</title>
5 <script src="options.js"></script>
6 </head>
7 <body>
8 <table id=rules></table>
9 <button id=new>New Rule</button>
10 <table hidden>
11 <tr id=rule-template hidden>
12   <td class=nowrap><button class=move-up>&uarr;</button>
13     <button class=move-down>&darr;</button></td>
14   <td>
15     <select class=matcher>
16       <option value=hostname>Hostname</option>
17       <option value=url-regex>URL RegExp</option>
18       <option value=default>Default Filename</option>
19       <option value=default-regex>Default Filename RegExp</option>
20       <option value=js>Javascript</option>
21     </select>
22     <input type=text class=match-param>
23     <select class=action>
24       <option value=overwrite>Overwrite default filename</option>
25       <option value=prompt>Prompt if default filename exists</option>
26       <option value=js>Javascript</option>
27     </select>
28     <textarea class=action-js rows=5 cols=83>console.log(item.url)
29 console.log(item.filename)
30 // http://developer.chrome.com/extensions/downloads.html#type-DownloadItem
31 // http://developer.chrome.com/extensions/downloads.html#type-FilenameConflictAction
32 suggest('hello.txt', 'overwrite')</textarea></td>
33   <td><span class=nowrap><input type=checkbox class=enabled checked>
34       <label class=enabled-label>Enabled</label></span>
35     <button class=remove>Remove</button></td>
36 </tr>
37 </table>
38 </body>
39 </html>