swing/src/net/sf/xframe/swing JXTable.java,1.5,1.6

Kurt Riede <[email protected]> Thu, 21 Oct 2004 08:37:13 +0000
Newsgroups gmane.text.xml.xframe.xsddoc.devel
Message-ID <[email protected]>
Update of /cvsroot/xframe/swing/src/net/sf/xframe/swing
In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv24806/src/net/sf/xframe/swing

Modified Files:
	JXTable.java 
Log Message:
minor changes, static references corrected

Index: JXTable.java
===================================================================
RCS file: /cvsroot/xframe/swing/src/net/sf/xframe/swing/JXTable.java,v
retrieving revision 1.5
retrieving revision 1.6
diff -C2 -d -r1.5 -r1.6
*** JXTable.java	5 Aug 2004 21:29:19 -0000	1.5
--- JXTable.java	21 Oct 2004 08:37:10 -0000	1.6
***************
*** 45,48 ****
--- 45,49 ----
  import javax.swing.JViewport;
  import javax.swing.ListSelectionModel;
+ import javax.swing.ScrollPaneConstants;
  import javax.swing.Scrollable;
  import javax.swing.border.Border;
***************
*** 90,94 ****
       * horizontal scrollbars are displayed only when needed.
       */
!     public static final int HORIZONTAL_SCROLLBAR_AS_NEEDED = JScrollPane.HORIZONTAL_SCROLLBAR_AS_NEEDED;
  
      /**
--- 91,95 ----
       * horizontal scrollbars are displayed only when needed.
       */
!     public static final int HORIZONTAL_SCROLLBAR_AS_NEEDED = ScrollPaneConstants.HORIZONTAL_SCROLLBAR_AS_NEEDED;
  
      /**
***************
*** 96,100 ****
       * horizontal scrollbars are never displayed.
       */
!     public static final int HORIZONTAL_SCROLLBAR_NEVER = JScrollPane.HORIZONTAL_SCROLLBAR_NEVER;
  
      /**
--- 97,101 ----
       * horizontal scrollbars are never displayed.
       */
!     public static final int HORIZONTAL_SCROLLBAR_NEVER = ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER;
  
      /**
***************
*** 102,106 ****
       * horizontal scrollbars are always displayed.
       */
!     public static final int HORIZONTAL_SCROLLBAR_ALWAYS = JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS;
  
      /** Do not adjust column widths automatically; use a scrollbar. */
--- 103,107 ----
       * horizontal scrollbars are always displayed.
       */
!     public static final int HORIZONTAL_SCROLLBAR_ALWAYS = ScrollPaneConstants.HORIZONTAL_SCROLLBAR_ALWAYS;
  
      /** Do not adjust column widths automatically; use a scrollbar. */
***************
*** 270,276 ****
          lockedTable.setTableHeader(lockedHeader);
          scrollTable.setTableHeader(scrollHeader);
!         scrollPane.setCorner(JScrollPane.UPPER_LEFT_CORNER, lockedHeader);
          scrollPane.setViewportView(scrollTable);
!         scrollPane.setVerticalScrollBarPolicy(JScrollPane.VERTICAL_SCROLLBAR_ALWAYS);
          setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
          setResizingAllowed(true);
--- 271,277 ----
          lockedTable.setTableHeader(lockedHeader);
          scrollTable.setTableHeader(scrollHeader);
!         scrollPane.setCorner(ScrollPaneConstants.UPPER_LEFT_CORNER, lockedHeader);
          scrollPane.setViewportView(scrollTable);
!         scrollPane.setVerticalScrollBarPolicy(ScrollPaneConstants.VERTICAL_SCROLLBAR_ALWAYS);
          setAutoResizeMode(JTable.AUTO_RESIZE_OFF);
          setResizingAllowed(true);
***************
*** 1244,1252 ****
       * <code>equals</code>.
       *
       * @return  the <code>TableColumn</code> object that matches the identifier
       * @exception IllegalArgumentException      if <code>identifier</code> is <code>null</code> or no <code>TableColumn</code>
       * has this identifier
-      *
-      * @param   identifier the identifier object
       */
      public TableColumn getColumn(final Object identifier) throws IllegalArgumentException {
--- 1245,1252 ----
       * <code>equals</code>.
       *
+      * @param identifier the identifier object
       * @return  the <code>TableColumn</code> object that matches the identifier
       * @exception IllegalArgumentException      if <code>identifier</code> is <code>null</code> or no <code>TableColumn</code>
       * has this identifier
       */
      public TableColumn getColumn(final Object identifier) throws IllegalArgumentException {
***************
*** 1389,1393 ****
       *
       * @return  the height in pixels of a table row
!      * @see     #setRowHeight
       */
      public int getRowHeight() {
--- 1389,1393 ----
       *
       * @return  the height in pixels of a table row
!      * @see     #setRowHeight(int)
       */
      public int getRowHeight() {
***************
*** 1858,1862 ****
       *
       * @param   rowHeight                       new row height
!      * @see     #getRowHeight
       */
      public void setRowHeight(final int rowHeight) {
--- 1858,1862 ----
       *
       * @param   rowHeight                       new row height
!      * @see     #getRowHeight()
       */
      public void setRowHeight(final int rowHeight) {
***************
*** 1932,1938 ****
      /**
       * Sizes the table columns to fit the available space.
       * @deprecated As of Swing version 1.0.3,
       * replaced by <code>doLayout()</code>.
!      * @see #doLayout
       */
      public void sizeColumnsToFit(final boolean lastColumnOnly) {
--- 1932,1939 ----
      /**
       * Sizes the table columns to fit the available space.
+      * @param lastColumnOnly
       * @deprecated As of Swing version 1.0.3,
       * replaced by <code>doLayout()</code>.
!      * @see #doLayout()
       */
      public void sizeColumnsToFit(final boolean lastColumnOnly) {
***************
*** 1945,1949 ****
       * @param resizingColumn    the column whose resizing made this adjustment
       *                          necessary or -1 if there is no such column
!      * @see  #doLayout
       */
      public void sizeColumnsToFit(final int resizingColumn) {
--- 1946,1950 ----
       * @param resizingColumn    the column whose resizing made this adjustment
       *                          necessary or -1 if there is no such column
!      * @see  #doLayout()
       */
      public void sizeColumnsToFit(final int resizingColumn) {
***************
*** 2206,2210 ****
          }
          // Remove the scrollable columns from the locked table
-         final TableColumnModel lockedColumnModel = lockedTable.getColumnModel();
          while (lockedTable.getColumnCount() > frozenColumns) {
              cm1.removeColumn(cm1.getColumn(frozenColumns));
--- 2207,2210 ----
***************
*** 2230,2234 ****
                  e.getSource(), e.getFirstRow(), e.getLastRow(),
                  e.getColumn()  - frozenColumns, e.getType());
!             scrollTable.tableChanged(e);
          }
      }
--- 2230,2234 ----
                  e.getSource(), e.getFirstRow(), e.getLastRow(),
                  e.getColumn()  - frozenColumns, e.getType());
!             scrollTable.tableChanged(event);
          }
      }
***************
*** 2346,2351 ****
       * @return  the autoResizeMode of the table
       *
!      * @see     #setAutoResizeMode
!      * @see     #doLayout
       */
      public int getAutoResizeMode() {
--- 2346,2351 ----
       * @return  the autoResizeMode of the table
       *
!      * @see     #setAutoResizeMode(int)
!      * @see     #doLayout()
       */
      public int getAutoResizeMode() {
***************
*** 2435,2443 ****
       * inclusive.
       *
       * @exception IllegalArgumentException      if <code>index0</code> or
       *                      <code>index1</code> lie outside
       *                                          [0, <code>getColumnCount()</code>-1]
-      * @param   index0 one end of the interval
-      * @param   index1 the other end of the interval
       */
      public void setColumnSelectionInterval(final int index0, final int index1) throws IllegalArgumentException {
--- 2435,2443 ----
       * inclusive.
       *
+      * @param   index0 one end of the interval
+      * @param   index1 the other end of the interval
       * @exception IllegalArgumentException      if <code>index0</code> or
       *                      <code>index1</code> lie outside
       *                                          [0, <code>getColumnCount()</code>-1]
       */
      public void setColumnSelectionInterval(final int index0, final int index1) throws IllegalArgumentException {
***************
*** 2456,2464 ****
       * inclusive, to the current selection.
       *
       * @exception IllegalArgumentException      if <code>index0</code> or
       *                      <code>index1</code> lie outside
       *                                          [0, <code>getColumnCount()</code>-1]
-      * @param   index0 one end of the interval
-      * @param   index1 the other end of the interval
       */
      public void addColumnSelectionInterval(final int index0, final int index1) throws IllegalArgumentException {
--- 2456,2464 ----
       * inclusive, to the current selection.
       *
+      * @param   index0 one end of the interval
+      * @param   index1 the other end of the interval
       * @exception IllegalArgumentException      if <code>index0</code> or
       *                      <code>index1</code> lie outside
       *                                          [0, <code>getColumnCount()</code>-1]
       */
      public void addColumnSelectionInterval(final int index0, final int index1) throws IllegalArgumentException {
***************
*** 2612,2621 ****
       * Sets the L&F object that renders this component and repaints.
       *
!      * @param ui  the TableUI L&F object
!      * @see UIDefaults#getUI
       */
!     public void setUI(final TableUI ui) {
!         lockedTable.setUI(ui);
!         scrollTable.setUI(ui);
      }
  
--- 2612,2621 ----
       * Sets the L&F object that renders this component and repaints.
       *
!      * @param tableUi  the TableUI L&F object
!      * @see JTable#setUI()
       */
!     public void setUI(final TableUI tableUi) {
!         lockedTable.setUI(tableUi);
!         scrollTable.setUI(tableUi);
      }
  



-------------------------------------------------------
This SF.net email is sponsored by: IT Product Guide on ITManagersJournal
Use IT products in your business? Tell us what you think of them. Give us
Your Opinions, Get Free ThinkGeek Gift Certificates! Click to find out more
http://productguide.itmanagersjournal.com/guidepromo.tmpl