aboutsummaryrefslogtreecommitdiff
path: root/ext/js/background/backend.js
diff options
context:
space:
mode:
Diffstat (limited to 'ext/js/background/backend.js')
-rw-r--r--ext/js/background/backend.js26
1 files changed, 0 insertions, 26 deletions
diff --git a/ext/js/background/backend.js b/ext/js/background/backend.js
index db43ec57..4e86a23c 100644
--- a/ext/js/background/backend.js
+++ b/ext/js/background/backend.js
@@ -127,7 +127,6 @@ class Backend {
['triggerDatabaseUpdated', {async: false, contentScript: true, handler: this._onApiTriggerDatabaseUpdated.bind(this)}],
['testMecab', {async: true, contentScript: true, handler: this._onApiTestMecab.bind(this)}],
['textHasJapaneseCharacters', {async: false, contentScript: true, handler: this._onApiTextHasJapaneseCharacters.bind(this)}],
- ['documentStart', {async: false, contentScript: true, handler: this._onApiDocumentStart.bind(this)}],
['getTermFrequencies', {async: true, contentScript: true, handler: this._onApiGetTermFrequencies.bind(this)}]
]);
this._messageHandlersWithProgress = new Map([
@@ -747,12 +746,6 @@ class Backend {
return this._japaneseUtil.isStringPartiallyJapanese(text);
}
- _onApiDocumentStart(params, sender) {
- const {tab, frameId, url} = sender;
- if (typeof url !== 'string' || typeof tab !== 'object' || tab === null) { return; }
- this._updateTabAccessibility(url, tab.id, frameId);
- }
-
async _onApiGetTermFrequencies({termReadingList, dictionaries}) {
return await this._translator.getTermFrequencies(termReadingList, dictionaries);
}
@@ -2140,25 +2133,6 @@ class Backend {
}
}
- async _updateTabAccessibility(url, tabId, frameId) {
- let file = null;
-
- switch (new URL(url).hostname) {
- case 'docs.google.com':
- {
- const optionsContext = {depth: 0, url};
- const options = this._getProfileOptions(optionsContext);
- if (!options.accessibility.forceGoogleDocsHtmlRendering) { return; }
- file = 'js/accessibility/google-docs.js';
- }
- break;
- }
-
- if (file === null) { return; }
-
- await this._scriptManager.injectScript(file, tabId, frameId, false, true, 'document_start');
- }
-
async _getNormalizedDictionaryDatabaseMedia(targets) {
const results = await this._dictionaryDatabase.getMedia(targets);
for (const item of results) {