File tree Expand file tree Collapse file tree 2 files changed +9
-8
lines changed Expand file tree Collapse file tree 2 files changed +9
-8
lines changed Original file line number Diff line number Diff line change 76
76
< script type ="text/javascript " src ="viewer.js "> </ script >
77
77
</ head >
78
78
79
- < body >
79
+ < body tabindex =" 1 " >
80
80
< div id ="outerContainer " class ="loadingInProgress ">
81
81
82
82
< div id ="sidebarContainer ">
212
212
data-l10n-id ="page_rotate_cw " > </ menuitem >
213
213
</ menu >
214
214
215
- < div id ="viewerContainer " tabindex =" 1 " >
215
+ < div id ="viewerContainer ">
216
216
< div id ="viewer " contextmenu ="viewerContextMenu "> </ div >
217
217
</ div >
218
218
Original file line number Diff line number Diff line change @@ -1442,6 +1442,13 @@ var PDFView = {
1442
1442
left + ',' + top ;
1443
1443
}
1444
1444
self .setInitialView (storedHash , scale );
1445
+
1446
+ // Make all navigation keys work on document load,
1447
+ // unless the viewer is embedded in another page.
1448
+ if (window .parent === window ) {
1449
+ PDFView .container .focus ();
1450
+ PDFView .container .blur ();
1451
+ }
1445
1452
});
1446
1453
1447
1454
pagesPromise .then (function () {
@@ -1480,12 +1487,6 @@ var PDFView = {
1480
1487
self .outline = new DocumentOutlineView (outline );
1481
1488
document .getElementById ('viewOutline' ).disabled = !outline ;
1482
1489
});
1483
-
1484
- // Make all navigation keys work on document load,
1485
- // unless the viewer is embedded in another page.
1486
- if (window .parent .location === window .location ) {
1487
- PDFView .container .focus ();
1488
- }
1489
1490
});
1490
1491
1491
1492
pdfDocument .getMetadata ().then (function (data ) {
You can’t perform that action at this time.
0 commit comments