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

Side by Side Diff: chrome/browser/resources/security_warnings/safe_browsing.js

Issue 935663004: Add checkbox for reporting invalid TLS/SSL cert chains (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: revert accidental deletion (fixes failing CaptivePortal tests) Created 5 years, 9 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
OLDNEW
(Empty)
1 // Copyright 2014 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 // Other constants defined in safe_browsing_blocking_page.cc.
6 var SB_BOX_CHECKED = 'boxchecked';
7 var SB_DISPLAY_CHECK_BOX = 'displaycheckbox';
8
9 // This sets up the Extended Safe Browsing Reporting opt-in.
10 function setupCheckbox() {
11 if (loadTimeData.getString('type') != 'SAFEBROWSING' ||
12 !loadTimeData.getBoolean(SB_DISPLAY_CHECK_BOX)) {
13 return;
14 }
15
16 $('opt-in-label').innerHTML = loadTimeData.getString('optInLink');
17 $('opt-in-checkbox').checked = loadTimeData.getBoolean(SB_BOX_CHECKED);
18 $('malware-opt-in').classList.remove('hidden');
19 $('body').classList.add('safe-browsing-has-checkbox');
20
21 $('opt-in-checkbox').addEventListener('click', function() {
22 sendCommand(
23 $('opt-in-checkbox').checked ? CMD_DO_REPORT : CMD_DONT_REPORT);
24 });
25 }
OLDNEW
« no previous file with comments | « chrome/browser/resources/security_warnings/interstitial_v2.js ('k') | chrome/browser/safe_browsing/ping_manager.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698