<Swing Dev> [PATCH] 6219960 NullPointer on ToolTipManager.mouseEntered
Alexander Potochkin
Alexander.Potochkin at Sun.COM
Fri Mar 21 18:28:52 UTC 2008
Hello Jason
> Reordered some statements for this final patch.
Thank you
I'll have a look on Monday
see you
alexp
>
> Jason
>
> ------------------------------------------------------------------------
> Test your Star IQ Play now!
> <http://club.live.com/red_carpet_reveal.aspx?icid=redcarpet_HMTAGMAR>
>
>
> ------------------------------------------------------------------------
>
> --- c:\temp\ToolTipManager.java 2007-09-04 08:53:36.624566600 -0500
> +++ c:\temp\6219960\ToolTipManager.java 2008-03-20 10:10:53.816257200 -0500
> @@ -411,8 +411,10 @@
> return;
> }
>
> + boolean sameComponent = (insideComponent == component);
> if (insideComponent != null) {
> enterTimer.stop();
> + hide(insideComponent);
> }
> // A component in an unactive internal frame is sent two
> // mouseEntered events, make sure we don't end up adding
> @@ -420,8 +422,6 @@
> component.removeMouseMotionListener(this);
> component.addMouseMotionListener(this);
>
> - boolean sameComponent = (insideComponent == component);
> -
> insideComponent = component;
> if (tipWindow != null){
> mouseEvent = event;
> @@ -614,6 +614,7 @@
> }
>
> protected class insideTimerAction implements ActionListener {
> + insideTimerAction() {}
> public void actionPerformed(ActionEvent e) {
> if(insideComponent != null && insideComponent.isShowing()) {
> // Lazy lookup
> @@ -638,12 +639,14 @@
> }
>
> protected class outsideTimerAction implements ActionListener {
> + outsideTimerAction() {}
> public void actionPerformed(ActionEvent e) {
> showImmediately = false;
> }
> }
>
> protected class stillInsideTimerAction implements ActionListener {
> + stillInsideTimerAction() {}
> public void actionPerformed(ActionEvent e) {
> hideTipWindow();
> enterTimer.stop();
> @@ -662,6 +665,7 @@
> * solely on mouse-entered to initiate the tooltip.
> */
> private class MoveBeforeEnterListener extends MouseMotionAdapter {
> + MoveBeforeEnterListener() {}
> public void mouseMoved(MouseEvent e) {
> initiateToolTip(e);
> }
> @@ -800,6 +804,7 @@
> * Unpost Tip: Esc and Ctrl+F1
> */
> private class AccessibilityKeyListener extends KeyAdapter {
> + AccessibilityKeyListener() {}
> public void keyPressed(KeyEvent e) {
> if (!e.isConsumed()) {
> JComponent source = (JComponent) e.getComponent();
More information about the swing-dev
mailing list