From: kramm Date: Sun, 16 Dec 2001 19:28:28 +0000 (+0000) Subject: store named links in swf, too. X-Git-Tag: release-0-2-2~90 X-Git-Url: http://git.asbjorn.biz/?p=swftools.git;a=commitdiff_plain;h=ded7d89c8c2fcf46c5b9820dd03f5592d9df70f8 store named links in swf, too. --- diff --git a/pdf2swf/SWFOutputDev.cc b/pdf2swf/SWFOutputDev.cc index 1ac8940..78be919 100644 --- a/pdf2swf/SWFOutputDev.cc +++ b/pdf2swf/SWFOutputDev.cc @@ -631,6 +631,7 @@ void SWFOutputDev::drawLink(Link *link, Catalog *catalog) char*s = "-?-"; char*type = "-?-"; char*url = 0; + char*named = 0; int page = -1; switch(action->getKind()) { @@ -666,6 +667,7 @@ void SWFOutputDev::drawLink(Link *link, Catalog *catalog) GString*name = l->getName(); if(name) { s = name->lowerCase()->getCString(); + named = name->getCString(); if(strstr(s, "next") || strstr(s, "forward")) { page = currentpage + 1; @@ -732,6 +734,10 @@ void SWFOutputDev::drawLink(Link *link, Catalog *catalog) { swfoutput_linktourl(&output, url, points); } + else if(named) + { + swfoutput_namedlink(&output, named, points); + } logf(" \"%s\" link to \"%s\" (%d)\n", type, s, page); } }