src/share/classes/com/sun/tools/doclets/formats/html/HtmlDocletWriter.java

changeset 1383
b980e8e6aabf
parent 1381
23fe1a96bc0f
child 1410
bfec2a1cc869
     1.1 --- a/src/share/classes/com/sun/tools/doclets/formats/html/HtmlDocletWriter.java	Wed Oct 31 08:31:40 2012 -0700
     1.2 +++ b/src/share/classes/com/sun/tools/doclets/formats/html/HtmlDocletWriter.java	Wed Oct 31 13:48:15 2012 -0700
     1.3 @@ -723,7 +723,8 @@
     1.4          if (helpfile.isEmpty()) {
     1.5              helpfilenm = DocPaths.HELP_DOC;
     1.6          } else {
     1.7 -            helpfilenm = DocPath.create(new File(helpfile).getName());
     1.8 +            DocFile file = DocFile.createFileForInput(configuration, helpfile);
     1.9 +            helpfilenm = DocPath.create(file.getName());
    1.10          }
    1.11          Content linkContent = getHyperLink(pathToRoot.resolve(helpfilenm),
    1.12                  helpLabel, "", "");
    1.13 @@ -1671,12 +1672,13 @@
    1.14       * @return an HtmlTree for the lINK tag which provides the stylesheet location
    1.15       */
    1.16      public HtmlTree getStyleSheetProperties() {
    1.17 -        String filename = configuration.stylesheetfile;
    1.18 +        String stylesheetfile = configuration.stylesheetfile;
    1.19          DocPath stylesheet;
    1.20 -        if (filename.length() > 0) {
    1.21 -            stylesheet = DocPath.create(new File(filename).getName());
    1.22 +        if (stylesheetfile.isEmpty()) {
    1.23 +            stylesheet = DocPaths.STYLESHEET;
    1.24          } else {
    1.25 -            stylesheet = DocPaths.STYLESHEET;
    1.26 +            DocFile file = DocFile.createFileForInput(configuration, stylesheetfile);
    1.27 +            stylesheet = DocPath.create(file.getName());
    1.28          }
    1.29          HtmlTree link = HtmlTree.LINK("stylesheet", "text/css",
    1.30                  pathToRoot.resolve(stylesheet).getPath(),

mercurial