Patch: more AWT code

Bryce McKinlay bryce@albatross.co.nz
Tue Jan 2 17:31:00 GMT 2001


Hmm. Lots of these methods don't exist, according to the JDK 1.3 docs. What spec were you
working from? I suspect the peer should be mantaining Adjustable objects that provide this
functionality, which client code can access with getVAdjustable()/getHAdjustable().

regards

  [ bryce ]

Tom Tromey wrote:

>
> +    public int getBlockIncrement ()
> +    {
> +      return block;
> +    }
> +
> +    public int getMaximum ()
> +    {
> +      Dimension child_d = component[0].getPreferredSize ();
> +      Dimension our_d = getViewportSize ();
> +
> +      int xmax = Math.max (0, child_d.width - our_d.width);
> +      int ymax = Math.max (0, child_d.height - our_d.height);
> +
> +      return (orient == Adjustable.HORIZONTAL) ? xmax : ymax;
> +    }
> +
> +    public int getMinimum ()
> +    {
> +      return 0;
> +    }
> +
> +    public int getOrientation ()
> +    {
> +      return orient;
> +    }



More information about the Java-patches mailing list