Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6300487

JScrollPane.getCorner(String) returns null for valid keys

XMLWordPrintable

    • b48
    • x86
    • windows_2000, windows_xp
    • Verified

      The spec J2SE 5.0 has incorrect statements in JScrollPane javadoc:
       "public Component getCorner(String key)
        ..
        Returns: one of the components listed below or null if key is invalid:
                 lowerLeft
                 lowerRight
                 upperLeft
                 upperRight"

      However, the current implementation returns null for valid keys. I assume the spec is incorrect
      to not list this valid case. It should be explicitly stated that "or null if key is invalid or
      if there is no corner component".

      Also the spec mentions "By default, the corners are empty." which is hard to interpret.

            shickeysunw Shannon Hickey (Inactive)
            visaenko Vasily Isaenko (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: