/[classpath]/classpath/javax/swing/table/TableColumn.java
ViewVC logotype

Diff of /classpath/javax/swing/table/TableColumn.java

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

revision 1.7.2.2 by gnu_andrew, Sat Jan 15 17:02:21 2005 UTC revision 1.7.2.3 by gnu_andrew, Sun Jan 16 15:15:13 2005 UTC
# Line 151  public class TableColumn Line 151  public class TableColumn
151    
152    /**    /**
153     * Constructor TableColumn     * Constructor TableColumn
154     * @param modelIndex TODO     *
155       * @param modelIndex the index of the column in the model
156     */     */
157    public TableColumn(int modelIndex)    public TableColumn(int modelIndex)
158    {    {
# Line 160  public class TableColumn Line 161  public class TableColumn
161    
162    /**    /**
163     * Constructor TableColumn     * Constructor TableColumn
164     * @param modelIndex TODO     *
165     * @param width TODO     * @param modelIndex the index of the column in the model
166       * @param width the width
167     */     */
168    public TableColumn(int modelIndex, int width)    public TableColumn(int modelIndex, int width)
169    {    {
# Line 170  public class TableColumn Line 172  public class TableColumn
172    
173    /**    /**
174     * Constructor TableColumn     * Constructor TableColumn
175     * @param modelIndex TODO     *
176     * @param width TODO     * @param modelIndex the index of the column in the model
177     * @param cellRenderer TODO     * @param width the width
178     * @param cellEditor TODO     * @param cellRenderer the cell renderer
179       * @param cellEditor the cell editor
180     */     */
181    public TableColumn(int modelIndex, int width,    public TableColumn(int modelIndex, int width,
182                       TableCellRenderer cellRenderer, TableCellEditor cellEditor)                       TableCellRenderer cellRenderer, TableCellEditor cellEditor)
# Line 189  public class TableColumn Line 192  public class TableColumn
192    
193    /**    /**
194     * firePropertyChange     * firePropertyChange
195     * @param property TODO     *
196     * @param oldValue TODO     * @param property the name of the property
197     * @param newValue TODO     * @param oldValue the old value
198       * @param newValue the new value
199     */     */
200    private void firePropertyChange(String property, Object oldValue,    private void firePropertyChange(String property, Object oldValue,
201                                    Object newValue)                                    Object newValue)
# Line 201  public class TableColumn Line 205  public class TableColumn
205    
206    /**    /**
207     * firePropertyChange     * firePropertyChange
208     * @param property TODO     *
209     * @param oldValue TODO     * @param property the name of the property
210     * @param newValue TODO     * @param oldValue the old value
211       * @param newValue the new value
212     */     */
213    private void firePropertyChange(String property, int oldValue, int newValue)    private void firePropertyChange(String property, int oldValue, int newValue)
214    {    {
# Line 212  public class TableColumn Line 217  public class TableColumn
217    
218    /**    /**
219     * firePropertyChange     * firePropertyChange
220     * @param property TODO     *
221     * @param oldValue TODO     * @param property the name of the property
222     * @param newValue TODO     * @param oldValue the old value
223       * @param newValue the new value
224     */     */
225    private void firePropertyChange(String property, boolean oldValue,    private void firePropertyChange(String property, boolean oldValue,
226                                    boolean newValue)                                    boolean newValue)
# Line 225  public class TableColumn Line 231  public class TableColumn
231    
232    /**    /**
233     * setModelIndex     * setModelIndex
234     * @param modelIndex TODO     *
235       * @param modelIndex the index to set
236     */     */
237    public void setModelIndex(int modelIndex)    public void setModelIndex(int modelIndex)
238    {    {
# Line 234  public class TableColumn Line 241  public class TableColumn
241    
242    /**    /**
243     * getModelIndex     * getModelIndex
244     * @return int     *
245       * @return the model index
246     */     */
247    public int getModelIndex()    public int getModelIndex()
248    {    {
# Line 243  public class TableColumn Line 251  public class TableColumn
251    
252    /**    /**
253     * setIdentifier     * setIdentifier
254     * @param identifier TODO     *
255       * @param identifier the identifier
256     */     */
257    public void setIdentifier(Object identifier)    public void setIdentifier(Object identifier)
258    {    {
# Line 252  public class TableColumn Line 261  public class TableColumn
261    
262    /**    /**
263     * getIdentifier     * getIdentifier
264     * @return Object     *
265       * @return the identifier
266     */     */
267    public Object getIdentifier()    public Object getIdentifier()
268    {    {
# Line 263  public class TableColumn Line 273  public class TableColumn
273    
274    /**    /**
275     * setHeaderValue     * setHeaderValue
276     * @param headerValue TODO     *
277       * @param headerValue the value of the header
278     */     */
279    public void setHeaderValue(Object headerValue)    public void setHeaderValue(Object headerValue)
280    {    {
281      // Variables      if (this.headerValue == headerValue)
282      Object oldValue;        return;
283        
284      // Get Old Value      Object oldValue = this.headerValue;
     oldValue = this.headerValue;  
   
     // Set Propeprty  
285      this.headerValue = headerValue;      this.headerValue = headerValue;
   
     // Notify Listeners of change  
286      firePropertyChange(HEADER_VALUE_PROPERTY, oldValue, headerValue);      firePropertyChange(HEADER_VALUE_PROPERTY, oldValue, headerValue);
287    }    }
288    
289    /**    /**
290     * getHeaderValue     * getHeaderValue
291     * @return Object     *
292       * @return the value of the header
293     */     */
294    public Object getHeaderValue()    public Object getHeaderValue()
295    {    {
# Line 291  public class TableColumn Line 298  public class TableColumn
298    
299    /**    /**
300     * setHeaderRenderer     * setHeaderRenderer
301     * @param headerRenderer TODO     *
302       * @param headerRenderer the renderer to se
303     */     */
304    public void setHeaderRenderer(TableCellRenderer renderer)    public void setHeaderRenderer(TableCellRenderer renderer)
305    {    {
# Line 315  public class TableColumn Line 323  public class TableColumn
323    
324    /**    /**
325     * setCellRenderer     * setCellRenderer
326     * @param cellRenderer TODO     *
327       * @param cellRenderer the cell renderer
328     */     */
329    public void setCellRenderer(TableCellRenderer renderer)    public void setCellRenderer(TableCellRenderer renderer)
330    {    {
# Line 330  public class TableColumn Line 339  public class TableColumn
339    
340    /**    /**
341     * getCellRenderer     * getCellRenderer
342     * @return TableCellRenderer     *
343       * @return the cell renderer
344     */     */
345    public TableCellRenderer getCellRenderer()    public TableCellRenderer getCellRenderer()
346    {    {
# Line 339  public class TableColumn Line 349  public class TableColumn
349    
350    /**    /**
351     * setCellEditor     * setCellEditor
352     * @param cellEditor TODO     *
353       * @param cellEditor the cell editor
354     */     */
355    public void setCellEditor(TableCellEditor cellEditor)    public void setCellEditor(TableCellEditor cellEditor)
356    {    {
# Line 348  public class TableColumn Line 359  public class TableColumn
359    
360    /**    /**
361     * getCellEditor     * getCellEditor
362     * @return TableCellEditor     *
363       * @return the cell editor
364     */     */
365    public TableCellEditor getCellEditor()    public TableCellEditor getCellEditor()
366    {    {
# Line 357  public class TableColumn Line 369  public class TableColumn
369    
370    /**    /**
371     * setWidth     * setWidth
372     * @param newWidth TODO     *
373       * @param newWidth the width
374     */     */
375    public void setWidth(int newWidth)    public void setWidth(int newWidth)
376    {    {
# Line 378  public class TableColumn Line 391  public class TableColumn
391    
392    /**    /**
393     * getWidth     * getWidth
394       *
395     * @return int     * @return int
396     */     */
397    public int getWidth()    public int getWidth()
# Line 387  public class TableColumn Line 401  public class TableColumn
401    
402    /**    /**
403     * setPreferredWidth     * setPreferredWidth
404     * @param preferredWidth TODO     *
405       * @param preferredWidth the preferred width
406     */     */
407    public void setPreferredWidth(int preferredWidth)    public void setPreferredWidth(int preferredWidth)
408    {    {
# Line 401  public class TableColumn Line 416  public class TableColumn
416    
417    /**    /**
418     * getPreferredWidth     * getPreferredWidth
419     * @return int     *
420       * @return the preferred width
421     */     */
422    public int getPreferredWidth()    public int getPreferredWidth()
423    {    {
# Line 410  public class TableColumn Line 426  public class TableColumn
426    
427    /**    /**
428     * setMinWidth     * setMinWidth
429     * @param minWidth TODO     *
430       * @param minWidth the minium width
431     */     */
432    public void setMinWidth(int minWidth)    public void setMinWidth(int minWidth)
433    {    {
# Line 421  public class TableColumn Line 438  public class TableColumn
438    
439    /**    /**
440     * getMinWidth     * getMinWidth
441     * @return int     *
442       * @return the minimum width
443     */     */
444    public int getMinWidth()    public int getMinWidth()
445    {    {
# Line 430  public class TableColumn Line 448  public class TableColumn
448    
449    /**    /**
450     * setMaxWidth     * setMaxWidth
451     * @param maxWidth TODO     *
452       * @param maxWidth the maximum width
453     */     */
454    public void setMaxWidth(int maxWidth)    public void setMaxWidth(int maxWidth)
455    {    {
# Line 441  public class TableColumn Line 460  public class TableColumn
460    
461    /**    /**
462     * getMaxWidth     * getMaxWidth
463     * @return int     * @return the maximim width
464     */     */
465    public int getMaxWidth()    public int getMaxWidth()
466    {    {
# Line 450  public class TableColumn Line 469  public class TableColumn
469    
470    /**    /**
471     * setResizable     * setResizable
472     * @param isResizable TODO     *
473       * @param isResizable <code>true</code> if this column is resizable,
474       * <code>false</code> otherwise
475     */     */
476    public void setResizable(boolean isResizable)    public void setResizable(boolean isResizable)
477    {    {
# Line 459  public class TableColumn Line 480  public class TableColumn
480    
481    /**    /**
482     * getResizable     * getResizable
483     * @return boolean     *
484       * @return <code>true</code> if this column is resizable,
485       * <code>false</code> otherwise
486     */     */
487    public boolean getResizable()    public boolean getResizable()
488    {    {

Legend:
Removed from v.1.7.2.2  
changed lines
  Added in v.1.7.2.3

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