Add pdfBugEnabled to the default preferences

This commit is contained in:
Jonas Jenwald 2014-06-16 21:46:39 +02:00
parent 13efe84d37
commit 1ba31a6cb7
3 changed files with 5 additions and 4 deletions

View File

@ -348,9 +348,6 @@ ChromeActions.prototype = {
return 'null';
}
},
pdfBugEnabled: function() {
return getBoolPref(PREF_PREFIX + '.pdfBugEnabled', false);
},
supportsIntegratedFind: function() {
// Integrated find is only supported when we're not in a frame
if (this.domWindow.frameElement !== null) {

View File

@ -24,6 +24,7 @@ var DEFAULT_PREFERENCES = {
sidebarViewOnLoad: 0,
enableHandToolOnLoad: false,
enableWebGL: false,
pdfBugEnabled: false,
disableRange: false,
disableAutoFetch: false,
disableFontFace: false,

View File

@ -228,6 +228,9 @@ var PDFView = {
Preferences.get('sidebarViewOnLoad').then(function resolved(value) {
self.preferenceSidebarViewOnLoad = value;
}),
Preferences.get('pdfBugEnabled').then(function resolved(value) {
self.preferencesPdfBugEnabled = value;
}),
Preferences.get('disableTextLayer').then(function resolved(value) {
if (PDFJS.disableTextLayer === true) {
return;
@ -1810,7 +1813,7 @@ function webViewerInitialized() {
//#if !(FIREFOX || MOZCENTRAL)
if ('pdfBug' in hashParams) {
//#else
//if ('pdfBug' in hashParams && FirefoxCom.requestSync('pdfBugEnabled')) {
//if ('pdfBug' in hashParams && PDFView.preferencesPdfBugEnabled) {
//#endif
PDFJS.pdfBug = true;
var pdfBug = hashParams['pdfBug'];