source: trunk/gcc/libjava/javax/swing/JSeparator.java

Last change on this file was 1389, checked in by bird, 21 years ago

Initial revision

  • Property cvs2svn:cvs-rev set to 1.1
  • Property svn:eol-style set to native
  • Property svn:executable set to *
File size: 5.6 KB
Line 
1/* JSeparator.java --
2 Copyright (C) 2002 Free Software Foundation, Inc.
3
4This file is part of GNU Classpath.
5
6GNU Classpath is free software; you can redistribute it and/or modify
7it under the terms of the GNU General Public License as published by
8the Free Software Foundation; either version 2, or (at your option)
9any later version.
10
11GNU Classpath is distributed in the hope that it will be useful, but
12WITHOUT ANY WARRANTY; without even the implied warranty of
13MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14General Public License for more details.
15
16You should have received a copy of the GNU General Public License
17along with GNU Classpath; see the file COPYING. If not, write to the
18Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
1902111-1307 USA.
20
21Linking this library statically or dynamically with other modules is
22making a combined work based on this library. Thus, the terms and
23conditions of the GNU General Public License cover the whole
24combination.
25
26As a special exception, the copyright holders of this library give you
27permission to link this library with independent modules to produce an
28executable, regardless of the license terms of these independent
29modules, and to copy and distribute the resulting executable under
30terms of your choice, provided that you also meet, for each linked
31independent module, the terms and conditions of the license of that
32module. An independent module is a module which is not derived from
33or based on this library. If you modify this library, you may extend
34this exception to your version of the library, but you are not
35obligated to do so. If you do not wish to do so, delete this
36exception statement from your version. */
37
38package javax.swing;
39
40// Imports
41import java.io.*;
42import javax.accessibility.*;
43import javax.swing.plaf.*;
44
45/**
46 * JSeparator
47 * @author Andrew Selkirk
48 * @version 1.0
49 */
50public class JSeparator extends JComponent
51 implements SwingConstants, Accessible {
52
53 //-------------------------------------------------------------
54 // Classes ----------------------------------------------------
55 //-------------------------------------------------------------
56
57 /**
58 * AccessibleJSeparator
59 */
60 protected class AccessibleJSeparator extends AccessibleJComponent {
61
62 //-------------------------------------------------------------
63 // Variables --------------------------------------------------
64 //-------------------------------------------------------------
65
66
67 //-------------------------------------------------------------
68 // Initialization ---------------------------------------------
69 //-------------------------------------------------------------
70
71 /**
72 * Constructor AccessibleJSeparator
73 * @param component TODO
74 */
75 protected AccessibleJSeparator(JSeparator component) {
76 super(component);
77 // TODO
78 } // AccessibleJSeparator()
79
80
81 //-------------------------------------------------------------
82 // Methods ----------------------------------------------------
83 //-------------------------------------------------------------
84
85 /**
86 * getAccessibleRole
87 * @returns AccessibleRole
88 */
89 public AccessibleRole getAccessibleRole() {
90 return AccessibleRole.SEPARATOR;
91 } // getAccessibleRole()
92
93
94 } // AccessibleJSeparator
95
96
97 //-------------------------------------------------------------
98 // Variables --------------------------------------------------
99 //-------------------------------------------------------------
100
101 /**
102 * uiClassID
103 */
104 private static final String uiClassID = "SeparatorUI";
105
106 /**
107 * orientation
108 */
109 private int orientation;
110
111
112 //-------------------------------------------------------------
113 // Initialization ---------------------------------------------
114 //-------------------------------------------------------------
115
116 /**
117 * Constructor JSeparator
118 */
119 public JSeparator() {
120 this(HORIZONTAL);
121 } // JSeparator()
122
123 /**
124 * Constructor JSeparator
125 * @param value0 TODO
126 */
127 public JSeparator(int orientation) {
128 this.orientation = orientation;
129 // TODO
130 } // JSeparator()
131
132
133 //-------------------------------------------------------------
134 // Methods ----------------------------------------------------
135 //-------------------------------------------------------------
136
137 /**
138 * writeObject
139 * @param stream TODO
140 * @exception IOException TODO
141 */
142 private void writeObject(ObjectOutputStream stream) throws IOException {
143 // TODO
144 } // writeObject()
145
146 /**
147 * getUI
148 * @returns SeparatorUI
149 */
150 public SeparatorUI getUI() {
151 return (SeparatorUI) ui;
152 } // getUI()
153
154 /**
155 * setUI
156 * @param ui TODO
157 */
158 public void setUI(SeparatorUI ui) {
159 super.setUI(ui);
160 } // setUI()
161
162 /**
163 * updateUI
164 */
165 public void updateUI() {
166 setUI((SeparatorUI) UIManager.get(this));
167 invalidate();
168 } // updateUI()
169
170 /**
171 * getUIClassID
172 * @returns String
173 */
174 public String getUIClassID() {
175 return uiClassID;
176 } // getUIClassID()
177
178 /**
179 * getOrientation
180 * @returns int
181 */
182 public int getOrientation() {
183 return orientation;
184 } // getOrientation()
185
186 /**
187 * setOrientation
188 * @param orientation TODO
189 */
190 public void setOrientation(int orientation) {
191 this.orientation = orientation;
192 // TODO
193 } // setOrientation()
194
195 /**
196 * paramString
197 * @returns String
198 */
199 protected String paramString() {
200 return null; // TODO
201 } // paramString()
202
203 /**
204 * isFocusTraversable
205 * @returns boolean
206 */
207 public boolean isFocusTraversable() {
208 return false;
209 } // isFocusTraversable()
210
211 /**
212 * getAccessibleContext
213 * @returns AccessibleContext
214 */
215 public AccessibleContext getAccessibleContext() {
216 if (accessibleContext == null) {
217 accessibleContext = new AccessibleJSeparator(this);
218 } // if
219 return accessibleContext;
220 } // getAccessibleContext()
221
222
223} // JSeparator
Note: See TracBrowser for help on using the repository browser.