classpath-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cp-patches] FYI: Fixed ScrollPaneLayout


From: David Gilbert
Subject: Re: [cp-patches] FYI: Fixed ScrollPaneLayout
Date: Wed, 12 Oct 2005 16:49:50 +0000
User-agent: Mozilla Thunderbird 1.0.6 (X11/20050728)

Roman Kennke wrote:

The ScrollPaneLayout implementation has been wrong in several places.
First, the minimum/preferredLayoutSize methods actually modified the
layout, which is not allowed and can have severe performance impact and
malfunction. Second, the layoutContainer method could not properly
determine when the scrollbars should be visible or not. This has lead to
ugly flickers.

2005-10-12  Roman Kennke  <address@hidden>

       * javax/swing/ScrollPaneLayout.java
       (preferredLayoutSize): Reworked. The old impl used to actually
       modify the layout, which is not allowed.
       (minimumLayoutSize): Reworked. The old impl used to actually
       modify the layout, which is not allowed.
       (layoutContainer): Reworked. The old impl did not properly
determine
       when the scrollbars should be visible and when not.

/Roman
------------------------------------------------------------------------

I don't know if this patch caused the problem, but something today has made the Swing demo fail (on the List world tab):

java.lang.NullPointerException
at javax.swing.ScrollPaneLayout.minimumLayoutSize (ScrollPaneLayout.java:290) at javax.swing.plaf.basic.BasicScrollPaneUI.getMinimumSize (BasicScrollPaneUI.java:416)
  at javax.swing.JComponent.getMinimumSize (JComponent.java:1053)
at javax.swing.plaf.basic.BasicSplitPaneUI$BasicHorizontalLayoutManager.minimumSizeOfComponent (BasicSplitPaneUI.java:481) at javax.swing.plaf.basic.BasicSplitPaneUI.getMinimumDividerLocation (BasicSplitPaneUI.java:1362) at javax.swing.plaf.basic.BasicSplitPaneUI.validLocation (BasicSplitPaneUI.java:1570) at javax.swing.plaf.basic.BasicSplitPaneUI.finishDraggingTo (BasicSplitPaneUI.java:1537) at javax.swing.plaf.basic.BasicSplitPaneDivider.finishDraggingTo (BasicSplitPaneDivider.java:489) at javax.swing.plaf.basic.BasicSplitPaneDivider$DragController.completeDrag (BasicSplitPaneDivider.java:719) at javax.swing.plaf.basic.BasicSplitPaneDivider$MouseHandler.mouseReleased (BasicSplitPaneDivider.java:586)
  at java.awt.Component.processMouseEvent (Component.java:3111)
  at java.awt.Component.processEvent (Component.java:2972)
  at java.awt.Container.processEvent (Container.java:905)
  at java.awt.Component.dispatchEventImpl (Component.java:4840)
  at java.awt.Container.dispatchEventImpl (Container.java:1644)
  at java.awt.Component.dispatchEvent (Component.java:2339)
  at java.awt.LightweightDispatcher.handleEvent (Container.java:2190)
  at java.awt.Container.dispatchEventImpl (Container.java:1635)
  at java.awt.Window.dispatchEventImpl (Window.java:623)
  at java.awt.Component.dispatchEvent (Component.java:2339)
  at java.awt.EventQueue.dispatchEvent (EventQueue.java:474)
  at java.awt.EventDispatchThread.run (EventDispatchThread.java:75)


Regards,

Dave




reply via email to

[Prev in Thread] Current Thread [Next in Thread]