RFR: JDK-8275406: Add copy-to-clipboard feature to snippet UI [v2]

Pavel Rappo prappo at openjdk.java.net
Wed Oct 20 14:45:12 UTC 2021


On Wed, 20 Oct 2021 10:18:24 GMT, Hannes Wallnöfer <hannesw at openjdk.org> wrote:

>> test/langtools/jdk/javadoc/lib/javadoc/tester/LinkChecker.java line 354:
>> 
>>> 352:         void addReference(String name, Path from, int line) {
>>> 353:             if (checked) {
>>> 354:                 if (name != null && !name.isEmpty()) {
>> 
>> I wonder if we should make this check more specific so as to allow only the snippet copy-to-clipboard link.
>
> I think this should be ok for the general case. Linking to "#" (i.e. empty fragment) is common practice for links that trigger script functions.

What I mean is that the amended test will now pass for a URL which has an empty fragment but is not a "button".

-------------

PR: https://git.openjdk.java.net/jdk/pull/6011



More information about the build-dev mailing list