/[classpath]/classpath/javax/swing/ViewportLayout.java
ViewVC logotype

Diff of /classpath/javax/swing/ViewportLayout.java

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.18 by abalkiss, Wed Oct 26 19:40:26 2005 UTC revision 1.19 by rabbit78, Tue Dec 6 14:31:09 2005 UTC
# Line 153  public class ViewportLayout implements L Line 153  public class ViewportLayout implements L
153        }        }
154      else      else
155        {        {
         viewPref.height = viewMinimum.height;  
156          int overextension = portLowerRight.y - viewPref.height;          int overextension = portLowerRight.y - viewPref.height;
157          if (overextension > 0)          if (overextension > 0)
158              portBounds.y -= overextension;              portBounds.y -= overextension;
# Line 168  public class ViewportLayout implements L Line 167  public class ViewportLayout implements L
167        }        }
168      else      else
169        {        {
         viewPref.width = viewMinimum.width;  
170          int overextension = portLowerRight.x - viewPref.width;          int overextension = portLowerRight.x - viewPref.width;
171          if (overextension > 0)          if (overextension > 0)
172              portBounds.x -= overextension;              portBounds.x -= overextension;
173        }        }
174    
175      port.setViewPosition(portBounds.getLocation());      port.setViewPosition(portBounds.getLocation());
176        // TODO: I doubt that the size should really be touched here, except when
177        // the view is somehow smaller than its minimumSize. I would think that
178        // when the size of a view is set manually to a fixed value, that this
179        // value should be left unchanged, and not reset to the preferred or
180        // minimum size. -- Roman Kennke
181      port.setViewSize(viewPref);      port.setViewSize(viewPref);
182    }    }
183  }  }

Legend:
Removed from v.1.18  
changed lines
  Added in v.1.19

savannah-hackers-public@gnu.org
ViewVC Help
Powered by ViewVC 1.1.26