Skip to content

Commit

Permalink
Merge pull request #18594 from Snuffleupagus/rm-enableHighlightEditor…
Browse files Browse the repository at this point in the history
…-pref

Remove the `enableHighlightEditor` preference
  • Loading branch information
Snuffleupagus authored Aug 13, 2024
2 parents d0fbfe1 + b9f5e78 commit 17b2463
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 18 deletions.
4 changes: 0 additions & 4 deletions extensions/chromium/preferences_schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -94,10 +94,6 @@
"description": "Whether to allow execution of active content (JavaScript) by PDF files.",
"default": false
},
"enableHighlightEditor": {
"type": "boolean",
"default": false
},
"enableHighlightFloatingButton": {
"type": "boolean",
"default": false
Expand Down
5 changes: 0 additions & 5 deletions web/app.js
Original file line number Diff line number Diff line change
Expand Up @@ -558,11 +558,6 @@ const PDFViewerApplication = {
typeof AbortSignal.any === "function") &&
annotationEditorMode !== AnnotationEditorType.DISABLE
) {
const editorHighlightButton = appConfig.toolbar?.editorHighlightButton;
if (editorHighlightButton && AppOptions.get("enableHighlightEditor")) {
editorHighlightButton.hidden = false;
}

this.annotationEditorParams = new AnnotationEditorParams(
appConfig.annotationEditorParams,
eventBus
Expand Down
8 changes: 0 additions & 8 deletions web/app_options.js
Original file line number Diff line number Diff line change
Expand Up @@ -200,14 +200,6 @@ const defaultOptions = {
value: true,
kind: OptionKind.VIEWER + OptionKind.PREFERENCE + OptionKind.EVENT_DISPATCH,
},
enableHighlightEditor: {
// We'll probably want to make some experiments before enabling this
// in Firefox release, but it has to be temporary.
// TODO: remove it when unnecessary.
/** @type {boolean} */
value: typeof PDFJSDev === "undefined" || PDFJSDev.test("TESTING"),
kind: OptionKind.VIEWER + OptionKind.PREFERENCE,
},
enableHighlightFloatingButton: {
// We'll probably want to make some experiments before enabling this
// in Firefox release, but it has to be temporary.
Expand Down
2 changes: 1 addition & 1 deletion web/viewer.html
Original file line number Diff line number Diff line change
Expand Up @@ -363,7 +363,7 @@
</div>
<div id="toolbarViewerRight">
<div id="editorModeButtons" class="splitToolbarButton toggled" role="radiogroup">
<button id="editorHighlight" class="toolbarButton" type="button" hidden="true" disabled="disabled" title="Highlight" role="radio" aria-checked="false" aria-controls="editorHighlightParamsToolbar" tabindex="31" data-l10n-id="pdfjs-editor-highlight-button">
<button id="editorHighlight" class="toolbarButton" type="button" disabled="disabled" title="Highlight" role="radio" aria-checked="false" aria-controls="editorHighlightParamsToolbar" tabindex="31" data-l10n-id="pdfjs-editor-highlight-button">
<span data-l10n-id="pdfjs-editor-highlight-button-label">Highlight</span>
</button>
<button id="editorFreeText" class="toolbarButton" type="button" disabled="disabled" title="Text" role="radio" aria-checked="false" aria-controls="editorFreeTextParamsToolbar" tabindex="32" data-l10n-id="pdfjs-editor-free-text-button">
Expand Down

0 comments on commit 17b2463

Please sign in to comment.