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

SynthToolBarUI.setBorderToXXXX() methods don't correspond inherited spec. They do nothing.

XMLWordPrintable

    • b86
    • generic
    • generic

      The following methods

       javax.swing.plaf.basic.BasicToolBarUI.setBorderToNonRollover(Component c)
       javax.swing.plaf.basic.BasicToolBarUI.setBorderToRollover(Component c)
       javax.swing.plaf.basic.BasicToolBarUI.setBorderToNormal(Component c)

      are overloaded in javax.swing.plaf.synth.SynthToolBarUI and do nothing. However they inherit the spec from BasicToolBarUI.
      Extract from Ri is below:
      -----------------------------------------------------------
          // Overloaded to do nothing so we can share listeners.
          /**
           * @inheritDoc
           */
          @Override
          protected void setBorderToNonRollover(Component c) {}

          // Overloaded to do nothing so we can share listeners.
          /**
           * @inheritDoc
           */
          @Override
          protected void setBorderToRollover(Component c) {}

          // Overloaded to do nothing so we can share listeners.
          /**
           * @inheritDoc
           */
          @Override
          protected void setBorderToNormal(Component c) {}
      -----------------------------------------------------------

      The fact that these methods do nothing should be reflected in the spec.
      For now, for example, for one of these methods the spec says:

      protected void setBorderToNonRollover(Component c)

       Description copied from class: BasicToolBarUI
       Sets the border of the component to have a non-rollover border which was created by the BasicToolBarUI.createNonRolloverBorder() method.

            rupashka Pavel Porvatov (Inactive)
            dbessono Dmitry Bessonov
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: