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

Side by Side Diff: chrome/browser/resources/ssl/roadblock.js

Issue 23965003: New SSL blocking screen (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 years, 2 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
OLDNEW
(Empty)
1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 var showedMore = false;
6
7 function toggleMoreInfo(collapse) {
8 $('more-info-long').hidden = collapse;
9 $('more-info-short').hidden = !collapse;
10 if (!collapse && !showedMore) {
11 sendCommand(CMD_MORE);
12 showedMore = true;
13 }
14 }
15
16 // UI modifications and event listeners that take place after load.
17 function setupEvents() {
18 $('proceed-button').hidden = false;
19 $('proceed-button').addEventListener('click', function() {
20 sendCommand(CMD_PROCEED);
21 });
22
23 if ($('more-info-title').textContent == '') {
24 $('more-info-short').hidden = true;
25 $('more-info-long').hidden = true;
26 $('twisty-closed').style.display = 'none';
27 } else {
28 $('more-info-short').addEventListener('click', function() {
29 toggleMoreInfo(false);
30 });
31 $('more-info-long').addEventListener('click', function() {
32 toggleMoreInfo(true);
33 });
34 }
35
36 $('exit-button').addEventListener('click', function() {
37 sendCommand(CMD_DONT_PROCEED);
38 });
39 }
40
41 document.addEventListener('DOMContentLoaded', setupEvents);
OLDNEW
« no previous file with comments | « chrome/browser/resources/ssl/roadblock.html ('k') | chrome/browser/resources/ssl/ssl_errors_common.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698