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

Side by Side Diff: chrome/browser/resources/chromeos/chromevox/cvox2/background/background.js

Issue 2456633002: Narrow next compat whitelist (Closed)
Patch Set: Created 4 years, 1 month 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
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/chromevox/cvox2/background/desktop_automation_handler.js » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 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 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 /** 5 /**
6 * @fileoverview The entry point for all ChromeVox2 related code for the 6 * @fileoverview The entry point for all ChromeVox2 related code for the
7 * background page. 7 * background page.
8 */ 8 */
9 9
10 goog.provide('Background'); 10 goog.provide('Background');
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 */ 68 */
69 this.classicBlacklistRegExp_ = Background.globsToRegExp_( 69 this.classicBlacklistRegExp_ = Background.globsToRegExp_(
70 chrome.runtime.getManifest()['content_scripts'][0]['exclude_globs']); 70 chrome.runtime.getManifest()['content_scripts'][0]['exclude_globs']);
71 71
72 /** 72 /**
73 * Regular expression for whitelisting Next compat. 73 * Regular expression for whitelisting Next compat.
74 * @type {RegExp} 74 * @type {RegExp}
75 * @private 75 * @private
76 */ 76 */
77 this.nextCompatRegExp_ = Background.globsToRegExp_([ 77 this.nextCompatRegExp_ = Background.globsToRegExp_([
78 '*docs.google.com*' 78 '*docs.google.com/document/*',
79 '*docs.google.com/spreadsheets/*',
80 '*docs.google.com/presentation/*'
dmazzoni 2016/10/31 19:48:56 nit: indentation
79 ]); 81 ]);
80 82
81 /** 83 /**
82 * @type {cursors.Range} 84 * @type {cursors.Range}
83 * @private 85 * @private
84 */ 86 */
85 this.currentRange_ = null; 87 this.currentRange_ = null;
86 88
87 /** 89 /**
88 * @type {cursors.Range} 90 * @type {cursors.Range}
(...skipping 703 matching lines...) Expand 10 before | Expand all | Expand 10 after
792 return new RegExp('^(' + globs.map(function(glob) { 794 return new RegExp('^(' + globs.map(function(glob) {
793 return glob.replace(/[.+^$(){}|[\]\\]/g, '\\$&') 795 return glob.replace(/[.+^$(){}|[\]\\]/g, '\\$&')
794 .replace(/\*/g, '.*') 796 .replace(/\*/g, '.*')
795 .replace(/\?/g, '.'); 797 .replace(/\?/g, '.');
796 }).join('|') + ')$'); 798 }).join('|') + ')$');
797 }; 799 };
798 800
799 new Background(); 801 new Background();
800 802
801 }); // goog.scope 803 }); // goog.scope
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/resources/chromeos/chromevox/cvox2/background/desktop_automation_handler.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698