summaryrefslogtreecommitdiffstats
path: root/chrome/browser/resources/offline_load.html
blob: 9a0602285d14ca53f29a7a6eea3ce887beb8879a (plain)
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
<!DOCTYPE html>
<html id="template_root" i18n-values="dir:textdirection">
<head>
<title i18n-content="title">
</title>
<style>
html {
  height: 100%;
}
body {
  color: #000;
  font-family: Helvetica, Arial, sans-serif;
  background-image: -webkit-linear-gradient(white 50%, rgb(236, 244, 255));
  height: 100%;
  padding: 0;
  margin: 0;
  display: -webkit-box;
  -webkit-box-orient: horizontal;
  -webkit-box-pack: center;
  visibility: hidden;
}

#error {
  margin-top: 150px;
  font-size: 16px;
  display: -webkit-box;
  width : 800px;
  max-width: 80%;
  -webkit-box-orient: horizontal;
}

#error img {
  vertical-align: middle;
  width: 96px;
  height: 96px;
  -webkit-margin-end: 10px;
  -webkit-box-flex: 0;
}

#error #msg_box {
  vertical-align: middle;
  -webkit-box-flex: 1;
}

</style>
<script src="shared/js/local_strings.js"></script>
<script>
var localStrings = new LocalStrings();

function sendCommand(cmd) {
  window.domAutomationController.setAutomationId(1);
  window.domAutomationController.send(cmd);
}
// Show the offline page.
function showPage() {
  document.body.style.visibility = 'visible';
}
document.addEventListener('DOMContentLoaded', function() {
  var timeToWait = localStrings.getString('timeToWait');
  window.setTimeout(showPage, timeToWait);
});
</script>
</head>

<body oncontextmenu="return false;">
<div id="error" i18n-values=".title:url">
  <img i18n-values=".src:icon;.style.display:display_icon">
  <div id="msg_box">
    <h3 i18n-content="heading"></h3>
    <div id="msg" i18n-values=".innerHTML:msg"></div>

    <button id="continue_button" i18n-content="load_button"
            onclick="sendCommand('proceed')">
    </button>
    <button id="cancel_button" i18n-content="cancel_button"
            i18n-values=".style.display:display_cancel"
            onclick="sendCommand('dontproceed')">
    </button>
    <a href="chrome://settings/internet"
       onclick="sendCommand('open_network_settings')"
       i18n-content="network_settings">
    </a>
  </div>
</div>
</body>
</html>