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

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

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

revision 1.14 by rabbit78, Fri Jun 17 10:12:29 2005 UTC revision 1.15 by rabbit78, Mon Jun 20 14:35:52 2005 UTC
# Line 78  public class DefaultListSelectionModel i Line 78  public class DefaultListSelectionModel i
78     */     */
79    int selectionMode = MULTIPLE_INTERVAL_SELECTION;    int selectionMode = MULTIPLE_INTERVAL_SELECTION;
80    
   
81    /**    /**
82     * The index of the "lead" of the most recent selection. The lead is the     * The index of the "lead" of the most recent selection. The lead is the
83     * second argument in any call to {@link #setSelectionInterval}, {@link     * second argument in any call to {@link #setSelectionInterval}, {@link
# Line 88  public class DefaultListSelectionModel i Line 87  public class DefaultListSelectionModel i
87     */     */
88    int leadSelectionIndex = -1;    int leadSelectionIndex = -1;
89    
   
90    /**    /**
91     * The index of the "anchor" of the most recent selection. The anchor is     * The index of the "anchor" of the most recent selection. The anchor is
92     * the first argument in any call to {@link #setSelectionInterval},     * the first argument in any call to {@link #setSelectionInterval},
# Line 102  public class DefaultListSelectionModel i Line 100  public class DefaultListSelectionModel i
100     */     */
101    int anchorSelectionIndex = -1;    int anchorSelectionIndex = -1;
102    
   
103    /**    /**
104     * controls the range of indices provided in any {@link     * controls the range of indices provided in any {@link
105     * ListSelectionEvent} fired by the selectionModel. Let     * ListSelectionEvent} fired by the selectionModel. Let
# Line 120  public class DefaultListSelectionModel i Line 117  public class DefaultListSelectionModel i
117     */     */
118    protected boolean leadAnchorNotificationEnabled = true;    protected boolean leadAnchorNotificationEnabled = true;
119    
   
120    /**    /**
121     * Whether the selection is currently "adjusting". Any {@link     * Whether the selection is currently "adjusting". Any {@link
122     * ListSelectionEvent} events constructed in response to changes in this     * ListSelectionEvent} events constructed in response to changes in this
# Line 140  public class DefaultListSelectionModel i Line 136  public class DefaultListSelectionModel i
136     */     */
137    BitSet sel = new BitSet();    BitSet sel = new BitSet();
138    
   
139    /**    /**
140     * Gets the value of the {@link #selectionMode} property.     * Gets the value of the {@link #selectionMode} property.
141     *     *
# Line 290  public class DefaultListSelectionModel i Line 285  public class DefaultListSelectionModel i
285      leadAnchorNotificationEnabled = l;      leadAnchorNotificationEnabled = l;
286    }    }
287    
   
288    /**    /**
289     * Gets the value of the {@link #valueIsAdjusting} property.     * Gets the value of the {@link #valueIsAdjusting} property.
290     *     *
# Line 326  public class DefaultListSelectionModel i Line 320  public class DefaultListSelectionModel i
320      return sel.isEmpty();      return sel.isEmpty();
321    }    }
322    
   
323    /**    /**
324     * Gets the smallest index which is currently a member of a selection     * Gets the smallest index which is currently a member of a selection
325     * interval.     * interval.
326     *     *
327     * @return The least integer <code>i</code> such that <code>i >=     * @return The least integer <code>i</code> such that <code>i >=
328     * 0</code> and <code>i</code> is a member of a selected interval, or     *     0</code> and <code>i</code> is a member of a selected interval, or
329     * <code>-1</code> if there are no selected intervals     *     <code>-1</code> if there are no selected intervals
330     *     *
331     * @see #getMaxSelectionIndex     * @see #getMaxSelectionIndex
332     */     */
# Line 350  public class DefaultListSelectionModel i Line 343  public class DefaultListSelectionModel i
343     * interval.     * interval.
344     *     *
345     * @return The greatest integer <code>i</code> such that <code>i >=     * @return The greatest integer <code>i</code> such that <code>i >=
346     * 0</code> and <code>i</code> is a member of a selected interval, or     *     0</code> and <code>i</code> is a member of a selected interval, or
347     * <code>-1</code> if there are no selected intervals     *     <code>-1</code> if there are no selected intervals
348     *     *
349     * @see #getMinSelectionIndex     * @see #getMinSelectionIndex
350     */     */
# Line 375  public class DefaultListSelectionModel i Line 368  public class DefaultListSelectionModel i
368     * @param a The index to search for     * @param a The index to search for
369     *     *
370     * @return <code>true</code> if the index is a member of a selection interval,     * @return <code>true</code> if the index is a member of a selection interval,
371     * otherwise <code>false</code>     *     otherwise <code>false</code>
372     */     */
373    public boolean isSelectedIndex(int a)    public boolean isSelectedIndex(int a)
374    {    {
# Line 495  public class DefaultListSelectionModel i Line 488  public class DefaultListSelectionModel i
488     * @param index The position to insert indices at     * @param index The position to insert indices at
489     * @param length The number of indices to insert     * @param length The number of indices to insert
490     * @param before Indicates whether to insert the indices before the index     * @param before Indicates whether to insert the indices before the index
491     * or after it     *     or after it
492     */     */
493    public void insertIndexInterval(int index,    public void insertIndexInterval(int index,
494                                    int length,                                    int length,
# Line 572  public class DefaultListSelectionModel i Line 565  public class DefaultListSelectionModel i
565     * @param firstIndex The low index of the changed range     * @param firstIndex The low index of the changed range
566     * @param lastIndex The high index of the changed range     * @param lastIndex The high index of the changed range
567     * @param isAdjusting Whether this change is part of a seqence of adjustments     * @param isAdjusting Whether this change is part of a seqence of adjustments
568     * made to the selection, such as during interactive scrolling     *     made to the selection, such as during interactive scrolling
569     */     */
570    protected void fireValueChanged(int firstIndex, int lastIndex,    protected void fireValueChanged(int firstIndex, int lastIndex,
571                                    boolean isAdjusting)                                    boolean isAdjusting)

Legend:
Removed from v.1.14  
changed lines
  Added in v.1.15

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