| 1 | /* AccessibleState.java -- a state of an accessible object
|
|---|
| 2 | Copyright (C) 2002 Free Software Foundation
|
|---|
| 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., 59 Temple Place, Suite 330, Boston, MA
|
|---|
| 19 | 02111-1307 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 | package javax.accessibility;
|
|---|
| 39 |
|
|---|
| 40 | /**
|
|---|
| 41 | * A state portion of an accessible object. A combination of states represent
|
|---|
| 42 | * the entire object state, in an AccessibleStateSet. For example, this could
|
|---|
| 43 | * be "active" or "selected". This strongly typed "enumeration" supports
|
|---|
| 44 | * localized strings. If the constants of this class are not adequate, new
|
|---|
| 45 | * ones may be added in a similar matter, while avoiding a public constructor.
|
|---|
| 46 | *
|
|---|
| 47 | * @author Eric Blake <[email protected]>
|
|---|
| 48 | * @since 1.2
|
|---|
| 49 | * @status updated to 1.4
|
|---|
| 50 | */
|
|---|
| 51 | public class AccessibleState extends AccessibleBundle
|
|---|
| 52 | {
|
|---|
| 53 | /**
|
|---|
| 54 | * Indicates an active window, as well as an active child in a list or other
|
|---|
| 55 | * collection.
|
|---|
| 56 | *
|
|---|
| 57 | * @see AccessibleRole#WINDOW
|
|---|
| 58 | * @see AccessibleRole#FRAME
|
|---|
| 59 | * @see AccessibleRole#DIALOG
|
|---|
| 60 | */
|
|---|
| 61 | public static final AccessibleState ACTIVE
|
|---|
| 62 | = new AccessibleState("active");
|
|---|
| 63 |
|
|---|
| 64 | /**
|
|---|
| 65 | * Indicates a pushed button, usually when the mouse has been pressed but
|
|---|
| 66 | * not released.
|
|---|
| 67 | *
|
|---|
| 68 | * @see AccessibleRole#PUSH_BUTTON
|
|---|
| 69 | */
|
|---|
| 70 | public static final AccessibleState PRESSED
|
|---|
| 71 | = new AccessibleState("pressed");
|
|---|
| 72 |
|
|---|
| 73 | /**
|
|---|
| 74 | * Indicates an armed object, usually a button which has been pushed and
|
|---|
| 75 | * the mouse has not left the button area.
|
|---|
| 76 | *
|
|---|
| 77 | * @see AccessibleRole#PUSH_BUTTON
|
|---|
| 78 | */
|
|---|
| 79 | public static final AccessibleState ARMED
|
|---|
| 80 | = new AccessibleState("armed");
|
|---|
| 81 |
|
|---|
| 82 | /**
|
|---|
| 83 | * Indicates an object is busy, such as a slider, scroll bar, or progress
|
|---|
| 84 | * bar in transition.
|
|---|
| 85 | *
|
|---|
| 86 | * @see AccessibleRole#PROGRESS_BAR
|
|---|
| 87 | * @see AccessibleRole#SCROLL_BAR
|
|---|
| 88 | * @see AccessibleRole#SLIDER
|
|---|
| 89 | */
|
|---|
| 90 | public static final AccessibleState BUSY
|
|---|
| 91 | = new AccessibleState("busy");
|
|---|
| 92 |
|
|---|
| 93 | /**
|
|---|
| 94 | * Indicates an object is checked.
|
|---|
| 95 | *
|
|---|
| 96 | * @see AccessibleRole#TOGGLE_BUTTON
|
|---|
| 97 | * @see AccessibleRole#RADIO_BUTTON
|
|---|
| 98 | * @see AccessibleRole#CHECK_BOX
|
|---|
| 99 | */
|
|---|
| 100 | public static final AccessibleState CHECKED
|
|---|
| 101 | = new AccessibleState("checked");
|
|---|
| 102 |
|
|---|
| 103 | /**
|
|---|
| 104 | * Indicates the user can edit the component contents. This is usually for
|
|---|
| 105 | * text, as other objects like scroll bars are automatically editable.
|
|---|
| 106 | *
|
|---|
| 107 | * @see #ENABLED
|
|---|
| 108 | */
|
|---|
| 109 | public static final AccessibleState EDITABLE
|
|---|
| 110 | = new AccessibleState("editable");
|
|---|
| 111 |
|
|---|
| 112 | /**
|
|---|
| 113 | * Indicates the object allows progressive disclosure of its children,
|
|---|
| 114 | * usually in a collapsible tree or other hierachical object.
|
|---|
| 115 | *
|
|---|
| 116 | * @see #EXPANDED
|
|---|
| 117 | * @see #COLLAPSED
|
|---|
| 118 | * @see AccessibleRole#TREE
|
|---|
| 119 | */
|
|---|
| 120 | public static final AccessibleState EXPANDABLE
|
|---|
| 121 | = new AccessibleState("expandable");
|
|---|
| 122 |
|
|---|
| 123 | /**
|
|---|
| 124 | * Indicates that the object is collapsed, usually in a tree.
|
|---|
| 125 | *
|
|---|
| 126 | * @see #EXPANDABLE
|
|---|
| 127 | * @see #EXPANDED
|
|---|
| 128 | * @see AccessibleRole#TREE
|
|---|
| 129 | */
|
|---|
| 130 | public static final AccessibleState COLLAPSED
|
|---|
| 131 | = new AccessibleState("collapsed");
|
|---|
| 132 |
|
|---|
| 133 | /**
|
|---|
| 134 | * Indicates that the object is expanded, usually in a tree.
|
|---|
| 135 | *
|
|---|
| 136 | * @see #EXPANDABLE
|
|---|
| 137 | * @see #COLLAPSED
|
|---|
| 138 | * @see AccessibleRole#TREE
|
|---|
| 139 | */
|
|---|
| 140 | public static final AccessibleState EXPANDED
|
|---|
| 141 | = new AccessibleState("expanded");
|
|---|
| 142 |
|
|---|
| 143 | /**
|
|---|
| 144 | * Indicates that an object is enabled. In the absence of this state,
|
|---|
| 145 | * graphics are often grayed out, and cannot be manipulated.
|
|---|
| 146 | */
|
|---|
| 147 | public static final AccessibleState ENABLED
|
|---|
| 148 | = new AccessibleState("enabled");
|
|---|
| 149 |
|
|---|
| 150 | /**
|
|---|
| 151 | * Indicates that an object can accept focus, which means it will process
|
|---|
| 152 | * keyboard events when focused.
|
|---|
| 153 | *
|
|---|
| 154 | * @see #FOCUSED
|
|---|
| 155 | */
|
|---|
| 156 | public static final AccessibleState FOCUSABLE
|
|---|
| 157 | = new AccessibleState("focusable");
|
|---|
| 158 |
|
|---|
| 159 | /**
|
|---|
| 160 | * Indicates that an object has keyboard focus.
|
|---|
| 161 | *
|
|---|
| 162 | * @see #FOCUSABLE
|
|---|
| 163 | */
|
|---|
| 164 | public static final AccessibleState FOCUSED
|
|---|
| 165 | = new AccessibleState("focused");
|
|---|
| 166 |
|
|---|
| 167 | /**
|
|---|
| 168 | * Indicates that an object is minimized to an icon.
|
|---|
| 169 | *
|
|---|
| 170 | * @see AccessibleRole#FRAME
|
|---|
| 171 | * @see AccessibleRole#INTERNAL_FRAME
|
|---|
| 172 | */
|
|---|
| 173 | public static final AccessibleState ICONIFIED
|
|---|
| 174 | = new AccessibleState("iconified");
|
|---|
| 175 |
|
|---|
| 176 | /**
|
|---|
|
|---|