jdk/src/macosx/classes/sun/lwawt/LWScrollBarPeer.java
changeset 13993 8b3fe3d8badb
parent 13143 31c70a66a053
child 17414 3e422b97a601
equal deleted inserted replaced
13992:d1b65c4e924c 13993:8b3fe3d8badb
    25 
    25 
    26 
    26 
    27 package sun.lwawt;
    27 package sun.lwawt;
    28 
    28 
    29 import java.awt.Adjustable;
    29 import java.awt.Adjustable;
    30 import java.awt.Dimension;
       
    31 import java.awt.Scrollbar;
    30 import java.awt.Scrollbar;
    32 import java.awt.event.AdjustmentEvent;
    31 import java.awt.event.AdjustmentEvent;
    33 import java.awt.event.AdjustmentListener;
    32 import java.awt.event.AdjustmentListener;
    34 import java.awt.peer.ScrollbarPeer;
    33 import java.awt.peer.ScrollbarPeer;
    35 
    34 
    91         synchronized (getDelegateLock()) {
    90         synchronized (getDelegateLock()) {
    92             getDelegate().setBlockIncrement(l);
    91             getDelegate().setBlockIncrement(l);
    93         }
    92         }
    94     }
    93     }
    95 
    94 
    96     @Override
       
    97     public Dimension getPreferredSize() {
       
    98         synchronized (getDelegateLock()) {
       
    99             return getDelegate().getPreferredSize();
       
   100         }
       
   101     }
       
   102 
       
   103     // Peer also registered as a listener for ComponentDelegate component
    95     // Peer also registered as a listener for ComponentDelegate component
   104     @Override
    96     @Override
   105     public void adjustmentValueChanged(final AdjustmentEvent e) {
    97     public void adjustmentValueChanged(final AdjustmentEvent e) {
   106         final int value = e.getValue();
    98         final int value = e.getValue();
   107         synchronized (getDelegateLock()) {
    99         synchronized (getDelegateLock()) {