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

Unified Diff: chrome/browser/resources/chromeos/chromevox/host/chrome/earcons_background.js

Issue 1319093003: Use new earcons in ChromeVox Next. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@automation_node_id_fix_2
Patch Set: Rebase Created 5 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/resources/chromeos/chromevox/host/chrome/earcons_background.js
diff --git a/chrome/browser/resources/chromeos/chromevox/host/chrome/earcons_background.js b/chrome/browser/resources/chromeos/chromevox/host/chrome/earcons_background.js
deleted file mode 100644
index 500da1a1e4825b75a2782ed54ac0ad4690b922e8..0000000000000000000000000000000000000000
--- a/chrome/browser/resources/chromeos/chromevox/host/chrome/earcons_background.js
+++ /dev/null
@@ -1,81 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-/**
- * @fileoverview Earcons library that uses the HTML5 Audio element to play back
- * auditory cues.
- *
- */
-
-
-goog.provide('cvox.EarconsBackground');
-
-goog.require('cvox.AbstractEarcons');
-
-
-/**
- * @constructor
- * @extends {cvox.AbstractEarcons}
- */
-cvox.EarconsBackground = function() {
- goog.base(this);
-
- this.audioMap = new Object();
- if (localStorage['earcons'] === 'false') {
- this.enabled = false;
- }
-};
-goog.inherits(cvox.EarconsBackground, cvox.AbstractEarcons);
-
-
-/**
- * @return {string} The human-readable name of the earcon set.
- */
-cvox.EarconsBackground.prototype.getName = function() {
- return 'ChromeVox earcons';
-};
-
-
-/**
- * @return {string} The base URL for loading earcons.
- */
-cvox.EarconsBackground.prototype.getBaseUrl = function() {
- return cvox.EarconsBackground.BASE_URL;
-};
-
-
-/**
- * @override
- */
-cvox.EarconsBackground.prototype.playEarcon = function(earcon) {
- goog.base(this, 'playEarcon', earcon);
- if (!this.enabled) {
- return;
- }
- if (window['console']) {
- window['console']['log']('Earcon ' + earcon);
- }
-
- this.currentAudio = this.audioMap[earcon];
- if (!this.currentAudio) {
- this.currentAudio = new Audio(chrome.extension.getURL(this.getBaseUrl() +
- earcon + '.ogg'));
- this.audioMap[earcon] = this.currentAudio;
- }
- try {
- this.currentAudio.currentTime = 0;
- } catch (e) {
- }
- if (this.currentAudio.paused) {
- this.currentAudio.volume = 0.7;
- this.currentAudio.play();
- }
-};
-
-
-/**
- * The base URL for loading eracons.
- * @type {string}
- */
-cvox.EarconsBackground.BASE_URL = 'chromevox/background/earcons/';

Powered by Google App Engine
This is Rietveld 408576698