Closed Bug 392462 Opened 17 years ago Closed 10 years ago

tooltips on swing components in java applets do not repaint properly

Categories

(Plugins Graveyard :: Java (Java Embedding Plugin), defect)

PowerPC
macOS
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED INCOMPLETE

People

(Reporter: rkunkel, Unassigned)

Details

User-Agent:       Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1; .NET CLR 1.1.4322; .NET CLR 2.0.50727)
Build Identifier: Mozilla/5.0 (Macintosh;U;PPC Mac OS X Mach-0;en-US;rv:1.8.1.6)Gecko/20070725 Firefox 2.0.0.6

If a java applet is embedded in a FireFox browser frame, tooltips are not repainting properly.  If one moves the mouse from component to component quickly,  the tooltip from the previous componet remains visible even as the new one is displayed. Eventually one can get a screen showing multiple tooltips that don't disappear at all including some in various stages of being wiped clean. If the mouse is moved slowly between components the problem does not seem to occur. 
This has been observed on multiple macs running JRE 1.5.0_07. It does not occur with Safari on the same machines. It also does not occur with FireFox 1.5.
In addition, if the applet is run in a window separate from the browser, e.g. a JFrame, JDialog etc., the problem does not occur.

Here is some simple applet code that will demonstrate the problem:

package apptest;
import javax.swing.*;
import java.awt.*;

public class MyApplet extends JApplet {

	private JPanel mainPanel;
	

	public void init() {
                       mainPanel = new JPanel(new GridLayout(4,2,15,15));
                       for(int i = 0; i < 8; i++) {
			JButton b = new JButton(String.valueOf(i + 1));
			b.setToolTipText("I'm button " + (i + 1));
			
			mainPanel.add(b);
		}
		
		getContentPane().add(mainPanel);
         }
    }
	
The following html can be used to load the applet if the applet is placed in a subdirectory called apptest, compiled and placed in a jar file called apptest.jar

<html>
	<embed width="800" height="548" scriptable="true" 
				pluginspage="http://java.sun.com/products/plugin/index.html#download" 
					   mayscript="true"  archive="apptest.jar" 
				type="application/x-java-applet;version=1.5" 
				code="apptest.MyApplet.class" 
				java_codebase="." id="applet_test"/> 
</embed>
</html>
				

Reproducible: Always

Steps to Reproduce:
1.Run the applet in the description
2.quickly move the mouse over the 8 buttons
3.multiple tool tips will show that do not go away
Actual Results:  
compile the applet code as described above. open the html to start the applet.

Expected Results:  
tooltips do not disappear if the buttons are moused over quickly

tooltip for previous button should disappear as a new one is encountered.
This appears to be an Apple bug (even though it doesn't happen in
Safari).

I'm not sure what I'm going to be able to do about it.

I'm easily able to reproduce this bug in Carbon-based browsers
(Firefox and SeaMonkey), and somewhat less easily in Camino, all on OS
X 10.4.10.

But I can't reproduce this at all on OS X 10.3.9 or OS X 10.5 (the
WWDC beta) ... which is what (I think) identifies this problem as an
Apple bug.

The Java Embedding Plugin has already fixed or worked around _many_
Apple bugs (fixing these bugs is in fact the very reason for its
existence).  But the fact that this bug is fixed in Apple's next major
OS version puts it lower on my priority list.  And it's also a problem
that I currently have no idea how I might work around this Apple bug
on OS X 10.4.X.
Status: UNCONFIRMED → NEW
Component: General → Java Embedding Plugin
Ever confirmed: true
Product: Firefox → Core
Hardware: PC → Macintosh
Assignee: nobody → smichaud
QA Contact: general → java.jep
Component: Java Embedding Plugin → Java (Java Embedding Plugin)
Product: Core → Plugins
This was probably not a JEP or Mozilla bug.  But in any case the JEP is long gone.
Assignee: smichaud → nobody
Status: NEW → RESOLVED
Closed: 10 years ago
Resolution: --- → INCOMPLETE
Product: Plugins → Plugins Graveyard
You need to log in before you can comment on or make changes to this bug.