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

Should clarify Canvas.update and repaint javadoc wrt overriding by client code

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P5 P5
    • 1.4.0
    • 1.4.0
    • client-libs
    • None
    • beta
    • generic
    • generic

      There seems to be a little confusion about whether or not subclasses of
      Canvas.java need to call super.update() and super.paint() when they override
      those methods.

      They should call super.update(), or put the same functionality into their
      own update method: clearing the damaged region by calling g.clearRect(),
      and then calling paint().

      It is not necessary (or desirable) to call super.paint().

            ehawkessunw Eric Hawkes (Inactive)
            ehawkessunw Eric Hawkes (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: