Uploaded image for project: 'Batik'
  1. Batik
  2. BATIK-520

Some UpdateManager Events fired in UpdateManager are constructed with a "source" as an anonymous inner class

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Resolution: Fixed
    • 1.5
    • None
    • Bridge
    • None
    • Operating System: Windows 2000
      Platform: PC

    Description

      On several locations within org.apache.batik.bridge.UpdateManager,
      UpdateManagerEventS are created inside anonymous inner classes with a reference
      to "this" as the source of the event, as opposed to "UpdateManager.this".

      Run and confirmed against batik 1.5.1, using j2sdk1.4.2_03 on W2KS.

      Line numbers (on the Feb 20 release):

      Lines 234 and 365: inside new Runnable()

      {...}

      Line 577 and 590: inside UpdateManager.UpdateManagerRunHander:
      executionSuspended()
      executionResumed()

      Demonstration code:

      (snipped from an instance of an UpdateManagerListener implementation subscribed
      at least one JSVGComponent.)

      public void managerStarted(UpdateManagerEvent evt) {
      System.out.println("evt.getSource().getClass()="+evt.getSource().getClass());
      }

      Observed output:

      evt.getSource().getClass()=class org.apache.batik.bridge.UpdateManager$8

      (note the "$8" denoting an anonymous inner class.)

      Expected output:

      e.getSource().getClass()=class org.apache.batik.bridge.UpdateManager

      Regards,

      • Ian

      (P.S: Batik rocks.)

      Attachments

        Activity

          People

            batik-dev@xmlgraphics.apache.org Batik Developer's Mailing list
            ian.sollars@gmx.net Ian Sollars
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: