GNU Classpath (0.17) | ||
Frames | No Frames |
1: /* DefaultTreeCellEditor.java -- 2: Copyright (C) 2002, 2004 Free Software Foundation, Inc. 3: 4: This file is part of GNU Classpath. 5: 6: GNU Classpath is free software; you can redistribute it and/or modify 7: it under the terms of the GNU General Public License as published by 8: the Free Software Foundation; either version 2, or (at your option) 9: any later version. 10: 11: GNU Classpath is distributed in the hope that it will be useful, but 12: WITHOUT ANY WARRANTY; without even the implied warranty of 13: MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 14: General Public License for more details. 15: 16: You should have received a copy of the GNU General Public License 17: along with GNU Classpath; see the file COPYING. If not, write to the 18: Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 19: 02110-1301 USA. 20: 21: Linking this library statically or dynamically with other modules is 22: making a combined work based on this library. Thus, the terms and 23: conditions of the GNU General Public License cover the whole 24: combination. 25: 26: As a special exception, the copyright holders of this library give you 27: permission to link this library with independent modules to produce an 28: executable, regardless of the license terms of these independent 29: modules, and to copy and distribute the resulting executable under 30: terms of your choice, provided that you also meet, for each linked 31: independent module, the terms and conditions of the license of that 32: module. An independent module is a module which is not derived from 33: or based on this library. If you modify this library, you may extend 34: this exception to your version of the library, but you are not 35: obligated to do so. If you do not wish to do so, delete this 36: exception statement from your version. */ 37: 38: 39: package javax.swing.tree; 40: 41: import java.awt.Color; 42: import java.awt.Component; 43: import java.awt.Container; 44: import java.awt.Dimension; 45: import java.awt.Font; 46: import java.awt.Graphics; 47: import java.awt.event.ActionEvent; 48: import java.awt.event.ActionListener; 49: import java.io.IOException; 50: import java.io.ObjectInputStream; 51: import java.io.ObjectOutputStream; 52: import java.util.EventObject; 53: 54: import javax.swing.Icon; 55: import javax.swing.JTextField; 56: import javax.swing.JTree; 57: import javax.swing.border.Border; 58: import javax.swing.event.CellEditorListener; 59: import javax.swing.event.EventListenerList; 60: import javax.swing.event.TreeSelectionEvent; 61: import javax.swing.event.TreeSelectionListener; 62: 63: /** 64: * DefaultTreeCellEditor 65: * @author Andrew Selkirk 66: */ 67: public class DefaultTreeCellEditor 68: implements ActionListener, TreeCellEditor, TreeSelectionListener 69: { 70: /** 71: * EditorContainer 72: */ 73: public class EditorContainer extends Container 74: { 75: /** 76: * Creates an <code>EditorContainer</code> object. 77: */ 78: public EditorContainer() 79: { 80: // Do nothing here. 81: } 82: 83: /** 84: * This method only exists for API compatibility and is useless as it does 85: * nothing. It got probably introduced by accident. 86: */ 87: public void EditorContainer() 88: { 89: // Do nothing here. 90: } 91: 92: /** 93: * getPreferredSize 94: * @return Dimension 95: */ 96: public Dimension getPreferredSize() 97: { 98: return null; // TODO 99: } 100: 101: /** 102: * paint 103: * @param value0 TODO 104: */ 105: public void paint(Graphics value0) 106: { 107: // TODO 108: } 109: 110: /** 111: * doLayout 112: */ 113: public void doLayout() 114: { 115: // TODO 116: } 117: } 118: 119: /** 120: * DefaultTextField 121: */ 122: public class DefaultTextField extends JTextField 123: { 124: /** 125: * border 126: */ 127: protected Border border; 128: 129: /** 130: * Creates a <code>DefaultTextField</code> object. 131: * 132: * @param border the border to use 133: */ 134: public DefaultTextField(Border border) 135: { 136: this.border = border; 137: } 138: 139: /** 140: * getFont 141: * @return Font 142: */ 143: public Font getFont() 144: { 145: return null; // TODO 146: } 147: 148: /** 149: * Returns the border of the text field. 150: * 151: * @return the border 152: */ 153: public Border getBorder() 154: { 155: return border; 156: } 157: 158: /** 159: * getPreferredSize 160: * @return Dimension 161: */ 162: public Dimension getPreferredSize() 163: { 164: return null; // TODO 165: } 166: } 167: 168: private EventListenerList listenerList = new EventListenerList(); 169: 170: /** 171: * realEditor 172: */ 173: protected TreeCellEditor realEditor; 174: 175: /** 176: * renderer 177: */ 178: protected DefaultTreeCellRenderer renderer; 179: 180: /** 181: * editingContainer 182: */ 183: protected Container editingContainer; 184: 185: /** 186: * editingComponent 187: */ 188: protected transient Component editingComponent; 189: 190: /** 191: * canEdit 192: */ 193: protected boolean canEdit; 194: 195: /** 196: * offset 197: */ 198: protected transient int offset; 199: 200: /** 201: * tree 202: */ 203: protected transient JTree tree; 204: 205: /** 206: * lastPath 207: */ 208: protected transient TreePath lastPath; 209: 210: /** 211: * timer 212: */ 213: protected transient javax.swing.Timer timer; // TODO 214: 215: /** 216: * lastRow 217: */ 218: protected transient int lastRow; 219: 220: /** 221: * borderSelectionColor 222: */ 223: protected Color borderSelectionColor; 224: 225: /** 226: * editingIcon 227: */ 228: protected transient Icon editingIcon; 229: 230: /** 231: * font 232: */ 233: protected Font font; 234: 235: /** 236: * Constructor DefaultTreeCellEditor 237: * @param value0 TODO 238: * @param value1 TODO 239: */ 240: public DefaultTreeCellEditor(JTree value0, DefaultTreeCellRenderer value1) 241: { 242: // TODO 243: } 244: 245: /** 246: * Constructor DefaultTreeCellEditor 247: * @param value0 TODO 248: * @param value1 TODO 249: * @param value2 TODO 250: */ 251: public DefaultTreeCellEditor(JTree value0, DefaultTreeCellRenderer value1, 252: TreeCellEditor value2) 253: { 254: // TODO 255: } 256: 257: /** 258: * writeObject 259: * @param value0 TODO 260: * @exception IOException TODO 261: */ 262: private void writeObject(ObjectOutputStream value0) throws IOException 263: { 264: // TODO 265: } 266: 267: /** 268: * readObject 269: * @param value0 TODO 270: * @exception IOException TODO 271: * @exception ClassNotFoundException TODO 272: */ 273: private void readObject(ObjectInputStream value0) 274: throws IOException, ClassNotFoundException 275: { 276: // TODO 277: } 278: 279: /** 280: * setBorderSelectionColor 281: * @param value0 TODO 282: */ 283: public void setBorderSelectionColor(Color value0) 284: { 285: // TODO 286: } 287: 288: /** 289: * getBorderSelectionColor 290: * @return Color 291: */ 292: public Color getBorderSelectionColor() 293: { 294: return null; // TODO 295: } 296: 297: /** 298: * setFont 299: * @param value0 TODO 300: */ 301: public void setFont(Font value0) 302: { 303: // TODO 304: } 305: 306: /** 307: * getFont 308: * @return Font 309: */ 310: public Font getFont() 311: { 312: return null; // TODO 313: } 314: 315: /** 316: * getTreeCellEditorComponent 317: * @param value0 TODO 318: * @param value1 TODO 319: * @param value2 TODO 320: * @param value3 TODO 321: * @param value4 TODO 322: * @param value5 TODO 323: * @return Component 324: */ 325: public Component getTreeCellEditorComponent(JTree value0, Object value1, 326: boolean value2, boolean value3, 327: boolean value4, int value5) 328: { 329: return null; // TODO 330: } 331: 332: /** 333: * getCellEditorValue 334: * @return Object 335: */ 336: public Object getCellEditorValue() 337: { 338: return null; // TODO 339: } 340: 341: /** 342: * isCellEditable 343: * @param value0 TODO 344: * @return boolean 345: */ 346: public boolean isCellEditable(EventObject value0) 347: { 348: return false; // TODO 349: } 350: 351: /** 352: * shouldSelectCell 353: * @param value0 TODO 354: * @return boolean 355: */ 356: public boolean shouldSelectCell(EventObject value0) 357: { 358: return false; // TODO 359: } 360: 361: /** 362: * stopCellEditing 363: * @return boolean 364: */ 365: public boolean stopCellEditing() 366: { 367: return false; // TODO 368: } 369: 370: /** 371: * cancelCellEditing 372: */ 373: public void cancelCellEditing() 374: { 375: // TODO 376: } 377: 378: /** 379: * Adds a <code>CellEditorListener</code> object to this editor. 380: * 381: * @param listener the listener to add 382: */ 383: public void addCellEditorListener(CellEditorListener listener) 384: { 385: listenerList.add(CellEditorListener.class, listener); 386: } 387: 388: /** 389: * Removes a <code>CellEditorListener</code> object. 390: * 391: * @param listener the listener to remove 392: */ 393: public void removeCellEditorListener(CellEditorListener listener) 394: { 395: listenerList.remove(CellEditorListener.class, listener); 396: } 397: 398: /** 399: * Returns all added <code>CellEditorListener</code> objects to this editor. 400: * 401: * @return an array of listeners 402: * 403: * @since 1.4 404: */ 405: public CellEditorListener[] getCellEditorListeners() 406: { 407: return (CellEditorListener[]) listenerList.getListeners(CellEditorListener.class); 408: } 409: 410: /** 411: * valueChanged 412: * @param value0 TODO 413: */ 414: public void valueChanged(TreeSelectionEvent value0) 415: { 416: // TODO 417: } 418: 419: /** 420: * actionPerformed 421: * @param value0 TODO 422: */ 423: public void actionPerformed(ActionEvent value0) 424: { 425: // TODO 426: } 427: 428: /** 429: * setTree 430: * @param value0 TODO 431: */ 432: protected void setTree(JTree value0) 433: { 434: // TODO 435: } 436: 437: /** 438: * shouldStartEditingTimer 439: * @param value0 TODO 440: * @return boolean 441: */ 442: protected boolean shouldStartEditingTimer(EventObject value0) 443: { 444: return false; // TODO 445: } 446: 447: /** 448: * startEditingTimer 449: */ 450: protected void startEditingTimer() 451: { 452: // TODO 453: } 454: 455: /** 456: * canEditImmediately 457: * @param value0 TODO 458: * @return boolean 459: */ 460: protected boolean canEditImmediately(EventObject value0) 461: { 462: return false; // TODO 463: } 464: 465: /** 466: * inHitRegion 467: * @param value0 TODO 468: * @param value1 TODO 469: * @return boolean 470: */ 471: protected boolean inHitRegion(int value0, int value1) 472: { 473: return false; // TODO 474: } 475: 476: /** 477: * determineOffset 478: * @param value0 TODO 479: * @param value1 TODO 480: * @param value2 TODO 481: * @param value3 TODO 482: * @param value4 TODO 483: * @param value5 TODO 484: */ 485: protected void determineOffset(JTree value0, Object value1, boolean value2, 486: boolean value3, boolean value4, int value5) 487: { 488: // TODO 489: } 490: 491: /** 492: * prepareForEditing 493: */ 494: protected void prepareForEditing() 495: { 496: // TODO 497: } 498: 499: /** 500: * createContainer 501: * @return Container 502: */ 503: protected Container createContainer() 504: { 505: return null; // TODO 506: } 507: 508: /** 509: * createTreeCellEditor 510: * @return TreeCellEditor 511: */ 512: protected TreeCellEditor createTreeCellEditor() 513: { 514: return null; // TODO 515: } 516: }
GNU Classpath (0.17) |