src/jdk.javadoc/share/classes/jdk/javadoc/internal/doclets/formats/html/ModulePackageIndexFrameWriter.java
changeset 51797 3efead10e303
parent 49569 d4d2f634b72f
child 53562 0d9dee001667
equal deleted inserted replaced
51796:9d3a00c8c047 51797:3efead10e303
    82 
    82 
    83     /**
    83     /**
    84      * {@inheritDoc}
    84      * {@inheritDoc}
    85      */
    85      */
    86     protected void addModulePackagesList(Map<ModuleElement, Set<PackageElement>> modules, String text,
    86     protected void addModulePackagesList(Map<ModuleElement, Set<PackageElement>> modules, String text,
    87             String tableSummary, Content body, ModuleElement mdle) {
    87             String tableSummary, Content main, ModuleElement mdle) {
    88         Content profNameContent = new StringContent(mdle.getQualifiedName().toString());
    88         Content profNameContent = new StringContent(mdle.getQualifiedName().toString());
    89         Content heading = HtmlTree.HEADING(HtmlConstants.PACKAGE_HEADING, true,
    89         Content heading = HtmlTree.HEADING(HtmlConstants.PACKAGE_HEADING, true,
    90                 getTargetModuleLink("classFrame", profNameContent, mdle));
    90                 getTargetModuleLink("classFrame", profNameContent, mdle));
    91         heading.addContent(Contents.SPACE);
    91         heading.addContent(Contents.SPACE);
    92         heading.addContent(contents.packagesLabel);
    92         heading.addContent(contents.packagesLabel);
    93         HtmlTree htmlTree = (configuration.allowTag(HtmlTag.MAIN))
    93         HtmlTree htmlTree = HtmlTree.DIV(HtmlStyle.indexContainer, heading);
    94                 ? HtmlTree.MAIN(HtmlStyle.indexContainer, heading)
       
    95                 : HtmlTree.DIV(HtmlStyle.indexContainer, heading);
       
    96         HtmlTree ul = new HtmlTree(HtmlTag.UL);
    94         HtmlTree ul = new HtmlTree(HtmlTag.UL);
    97         ul.setTitle(contents.packagesLabel);
    95         ul.setTitle(contents.packagesLabel);
    98         List<PackageElement> packages = new ArrayList<>(modules.get(mdle));
    96         List<PackageElement> packages = new ArrayList<>(modules.get(mdle));
    99         for (PackageElement pkg : packages) {
    97         for (PackageElement pkg : packages) {
   100             if ((!(configuration.nodeprecated && utils.isDeprecated(pkg)))) {
    98             if ((!(configuration.nodeprecated && utils.isDeprecated(pkg)))) {
   101                 ul.addContent(getPackage(pkg, mdle));
    99                 ul.addContent(getPackage(pkg, mdle));
   102             }
   100             }
   103         }
   101         }
   104         htmlTree.addContent(ul);
   102         htmlTree.addContent(ul);
   105         body.addContent(htmlTree);
   103         main.addContent(htmlTree);
   106     }
   104     }
   107 
   105 
   108     /**
   106     /**
   109      * {@inheritDoc}
   107      * {@inheritDoc}
   110      */
   108      */
   155     }
   153     }
   156 
   154 
   157     /**
   155     /**
   158      * {@inheritDoc}
   156      * {@inheritDoc}
   159      */
   157      */
   160     protected void addNavigationBarHeader(Content body) {
   158     protected void addNavigationBarHeader(Content header) {
   161         Content headerContent;
   159         Content headerContent;
   162         if (configuration.packagesheader.length() > 0) {
   160         if (configuration.packagesheader.length() > 0) {
   163             headerContent = new RawHtml(replaceDocRootDir(configuration.packagesheader));
   161             headerContent = new RawHtml(replaceDocRootDir(configuration.packagesheader));
   164         } else {
   162         } else {
   165             headerContent = new RawHtml(replaceDocRootDir(configuration.header));
   163             headerContent = new RawHtml(replaceDocRootDir(configuration.header));
   166         }
   164         }
   167         Content heading = HtmlTree.HEADING(HtmlConstants.TITLE_HEADING, true,
   165         Content heading = HtmlTree.HEADING(HtmlConstants.TITLE_HEADING, true,
   168                 HtmlStyle.bar, headerContent);
   166                 HtmlStyle.bar, headerContent);
   169         body.addContent(heading);
   167         header.addContent(heading);
   170     }
   168     }
   171 
   169 
   172     /**
   170     /**
   173      * Do nothing as there is no overview information in this page.
   171      * Do nothing as there is no overview information in this page.
   174      */
   172      */
   230     }
   228     }
   231 
   229 
   232     /**
   230     /**
   233      * {@inheritDoc}
   231      * {@inheritDoc}
   234      */
   232      */
   235     protected void addNavigationBarFooter(Content body) {
   233     protected void addNavigationBarFooter(Content footer) {
   236         Content p = HtmlTree.P(Contents.SPACE);
   234         Content p = HtmlTree.P(Contents.SPACE);
   237         body.addContent(p);
   235         footer.addContent(p);
   238     }
   236     }
   239 }
   237 }