1
0
Fork 0
mirror of https://github.com/mozilla/pdf.js.git synced 2025-04-21 07:38:07 +02:00

Move parsing of destination dictionaries to a helper function

This not only reduces code duplication, but it also allow us to easily support the same kind of URLs we currently do for Link annotations in the Outline as well.
This commit is contained in:
Jonas Jenwald 2016-09-30 16:08:03 +02:00
parent 6906623462
commit e64bc1fd13
4 changed files with 126 additions and 117 deletions

View file

@ -644,6 +644,7 @@ describe('api', function() {
expect(typeof outlineItemTwo.title).toEqual('string');
expect(outlineItemTwo.dest).toEqual(null);
expect(outlineItemTwo.url).toEqual('http://google.com');
expect(outlineItemTwo.newWindow).toBeUndefined();
var outlineItemOne = outline[1];
expect(outlineItemOne.bold).toEqual(false);