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

fp.bugs 3263 Win32 applets don't redraw after palette/app switch

XMLWordPrintable

    • x86
    • windows_95

      To see this, you need a Win95 machine, browser and paint application.
      Bring up
      http://www.javasoft.com/applets/applets/ImageTest/example1.html
      or some other pretty-image displaying applet.
      Once the applet is loaded and displaying properly, go to some other app that uses 256 color palettes, like say paint...
      Make sure application windows don't overlap.
      paint some stuff or it won't grab the colors. Notice that the picture of duke changes.
      I've found that you have to actually select the applet itself for color repaint to take place.
      _____Begin Bug Report_____

      Environment:
      * Windows 95 with a graphics card in 256 color mode
      * JDK Beta 2 (or Netscape 2.0 Beta 5)

      Problem:
      My applet draws some multi-colored images. These
      images change colors when another window has the focus,
      presumably because of palette switching. This is to be
      expected.
      However, when my applet is reactivated, it does not have
      an opportunity to redraw itself, and the palette is NOT
      fixed, so the images stay messed up.

      Reproducing this bug:
      This bug can be reproduced with the sample applet
      that you have at:
      http://www.javasoft.com/applets/applets/ImageTest/example1.html

      (1) Run Netscape 2.0 beta 5 and open it to this page. Wait for the applet
      to start running. Resize Netscape so it doesn't take up too much space.
      (2) Run another Windows 95 program that will grab the pallette. I am using
      Microsoft Access 95 for this, but any program that causes the applet's
      colors to weird out is OK.
      (3) Make sure that the two windows are not overlapping at all. (This ins
      ures that appletviewer does NOT receive any repaint() events when it is
      reactivated!)
      (4) Activate Access95 using the keyboard (Alt+TAB). Observe: the pallette
      in the applet is weirded out. Then activate Netscape again using Alt+TAB.

      NOTE: you may have to repeat step 4 several times to really see this
      behavior! it doesn't always happen.

      BUG: the applet colors don't return to what they are supposed to be.
      EXPECTED: the pallete to be fixed, or at least give me a gotFocus() or
      repaint() event!

      It is a separate bug that the applet does not receive a gotFocus() in this
      case.

      Joel
      -------------------------------
      Borland sent the same bug in JDK1.1. (May 1, 97)



            gsaab Georges Saab
            bhagen Benjamin Hagen (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: