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

Side by Side Diff: chrome/browser/resources/repost_form_warning.html

Issue 7828065: chromeos: Add WebUI implementation of form repost dialog. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge. again. Created 9 years, 3 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « chrome/browser/resources/http_auth.html ('k') | chrome/browser/ui/views/dialog_stubs_gtk.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
1 <!DOCTYPE html>
2 <html i18n-values="dir:textdirection">
3 <head>
4 <link rel="stylesheet" href="dialog.css">
5 <style>
6 body {
7 -webkit-user-select: none;
8 margin: 10px 10px 0 10px;
9 }
10
11 form {
12 margin: 0;
13 }
14
15 #explanation {
16 cursor: default;
17 }
18
19 #buttons {
20 padding: 10px 0;
21 text-align: end;
22 }
23
24 </style>
25 <script>
26 function $(o) {
27 return document.getElementById(o);
28 }
29
30 function disableControls() {
31 $('cancel').disabled = true;
32 $('resend').disabled = true;
33 }
34
35 function cancel() {
36 disableControls();
37 chrome.send('DialogClose', [JSON.stringify(false)]);
38 }
39
40 function handleSubmit(e) {
41 disableControls();
42 e.preventDefault();
43 chrome.send('DialogClose', [JSON.stringify(true)]);
44 }
45
46 function handleKeyDown(e) {
47 if (e.keyCode == 27) { // Escape
48 e.preventDefault();
49 cancel();
50 }
51 }
52
53 function load() {
54 document.addEventListener('keydown', handleKeyDown);
55 $('form').onsubmit = handleSubmit;
56 $('cancel').onclick = cancel;
57 $('cancel').focus();
58 }
59
60 document.addEventListener('DOMContentLoaded', load);
61 </script>
62 </head>
63 <body i18n-values=".style.fontFamily:fontfamily;.style.fontSize:fontsize">
64 <div id="explanation" i18n-content="explanation"></div>
65 <form id="form">
66 <div id="buttons">
67 <input id="cancel" type="reset" i18n-values="value:cancel" autofocus>
68 <input id="resend" type="submit" i18n-values="value:resend">
69 </div>
70 </form>
71 </body>
72 </html>
OLDNEW
« no previous file with comments | « chrome/browser/resources/http_auth.html ('k') | chrome/browser/ui/views/dialog_stubs_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698