1/************************************************************************* 2 * 3 * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 4 * 5 * Copyright 2000, 2010 Oracle and/or its affiliates. 6 * 7 * OpenOffice.org - a multi-platform office productivity suite 8 * 9 * This file is part of OpenOffice.org. 10 * 11 * OpenOffice.org is free software: you can redistribute it and/or modify 12 * it under the terms of the GNU Lesser General Public License version 3 13 * only, as published by the Free Software Foundation. 14 * 15 * OpenOffice.org is distributed in the hope that it will be useful, 16 * but WITHOUT ANY WARRANTY; without even the implied warranty of 17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 18 * GNU Lesser General Public License version 3 for more details 19 * (a copy is included in the LICENSE file that accompanied this code). 20 * 21 * You should have received a copy of the GNU Lesser General Public License 22 * version 3 along with OpenOffice.org. If not, see 23 * <http://www.openoffice.org/license.html> 24 * for a copy of the LGPLv3 License. 25 * 26 ************************************************************************/ 27#ifndef __com_sun_star_accessibility_AccessibleEventId_idl__ 28#define __com_sun_star_accessibility_AccessibleEventId_idl__ 29 30module com { module sun { module star { module accessibility { 31 32/** These constants identify the type of <type>AccessibleEventObject</type> 33 objects. 34 35 <p>The <member>AccessibleEventObject::OldValue</member> and 36 <member>AccessibleEventObject::NewValue</member> fields contain, where 37 applicable and not otherwise stated, the old and new value of the 38 property in question.</p> 39 40 @see AccessibleEventObject 41 @see XAccessibleEventListener 42 43 @since OOo 1.1.2 44*/ 45published constants AccessibleEventId 46{ 47 /** Use this event type to indicate a change of the name string 48 of an accessible object. The 49 <member>AccessibleEventObject::OldValue</member> and 50 <member>AccessibleEventObject::NewValue</member> fields contain the 51 name before and after the change. 52 */ 53 const short NAME_CHANGED = 1; 54 55 /** Use this event type to indicate a change of the description string 56 of an accessible object. The 57 <member>AccessibleEventObject::OldValue</member> and 58 <member>AccessibleEventObject::NewValue</member> fields contain the 59 description before and after the change. 60 */ 61 const short DESCRIPTION_CHANGED = 2; 62 63 /** The change of the number or attributes of actions of an accessible 64 object is signaled by events of this type. 65 <p>The <member>AccessibleEventObject::OldValue</member> and 66 <member>AccessibleEventObject::NewValue</member> fields contain the 67 old and new number of actions. 68 */ 69 const short ACTION_CHANGED = 3; 70 71 /** State changes are signaled with this event type. Use one event for 72 every state that is set or reset. The 73 <member>AccessibleEventObject::OldValue</member> and 74 <member>AccessibleEventObject::NewValue</member> fields contain the 75 old and new value respectively. To set a state put the state id 76 into the <member>AccessibleEventObject::NewValue</member> field and 77 leave <member>AccessibleEventObject::OldValue</member> empty. To 78 reset a state put the state id into the 79 <member>AccessibleEventObject::OldValue</member> field and leave 80 <member>AccessibleEventObject::NewValue</member> empty. 81 */ 82 const short STATE_CHANGED = 4; 83 84 /** Constant used to determine when the active descendant of a component 85 has changed. The active descendant is used in objects with 86 transient children. The <member>AccessibleEventObject::NewValue</member> 87 contains the now active object. The 88 <member>AccessibleEventObject::OldValue</member> contains the 89 previously active child. Empty references indicate that no child 90 has been respectively is currently active. 91 */ 92 const short ACTIVE_DESCENDANT_CHANGED = 5; 93 94 /** This event indicates a change of the bounding rectangle of an 95 accessible object with respect only to its size or relative 96 position. If the absolute position changes but not the relative 97 position then its is not necessary to send an event. 98 99 <p>Use this event rather than the 100 <const>VISIBLE_DATA_EVENT</const> when really only the 101 (relative) bounding box of an accessible object has changed. It is 102 much more specific than the later one and reduces the number of 103 calls an AT-Tool has to make to retrieve all affected data.</p> 104 105 <p>The <member>AccessibleEventObject::OldValue</member> and 106 <member>AccessibleEventObject::NewValue</member> remain empty. Use 107 a call to the <member>XAccessibleComponent::getBounds()</member> 108 method to determine the new bounding box.</p> 109 */ 110 const short BOUNDRECT_CHANGED = 6; 111 112 /** A child event indicates the addition of a new or the removal of an 113 existing child. The contents of the 114 <member>AccessibleEventObject::OldValue</member> and 115 <member>AccessibleEventObject::NewValue</member> fields determines 116 which of both has taken place. 117 118 <p>If a new child has been added then 119 the <member>AccessibleEventObject::NewValue</member> contains a 120 reference to this new object and 121 <member>AccessibleEventObject::OldValue</member> remains empty.</p> 122 123 <p>If a child has been removed then the 124 <member>AccessibleEventObject::OldValue</member> contains a 125 reference to this object and 126 <member>AccessibleEventObject::NewValue</member> remains empty.</p> 127 128 <p>If a child has been added and a another one has been removed 129 don't set both fields at the same. Send separate events 130 instead.</p> 131 132 <p>Note that a child event is sent after a child has been added or 133 removed. Especially in the case of a removal this means that the 134 removed object does not have a parent anymore.</p> 135 */ 136 const short CHILD = 7; 137 138 /** Use this event to tell the listeners to re-retrieve the whole set of 139 children. This should be used by a parent object which exchanges all 140 or most of its children. It is a short form of first sending one 141 <const>CHILD</const> event for every old child indicating that 142 this child is about to be removed and then sending one 143 <const>CHILD</const> for every new child indicating that this 144 child has been added to the list of children. 145 146 <p>When this API is used by Java or Gnome AT-Tools then a bridge can 147 generate the events described above automatically.</p> 148 */ 149 const short INVALIDATE_ALL_CHILDREN = 8; 150 151 /** Events of this type indicate changes of the selection. The 152 <member>AccessibleEventObject::OldValue</member> and 153 <member>AccessibleEventObject::NewValue</member> fields remain empty. 154 */ 155 const short SELECTION_CHANGED = 9; 156 157 /** A visibile data event indicates the change of the visual appearance 158 of an accessible object. This includes for example most of the 159 attributes available over the <type>XAccessibleComponent</type> and 160 <type>XAccessibleExtendedComponent</type> interfaces. The 161 <member>AccessibleEventObject::OldValue</member> and 162 <member>AccessibleEventObject::NewValue</member> fields are left empty. 163 */ 164 const short VISIBLE_DATA_CHANGED = 10; 165 166 /** This constant indicates changes of the value of an 167 <type>XAccessibleValue</type> interface. The 168 <member>AccessibleEventObject::OldValue</member> and 169 <member>AccessibleEventObject::NewValue</member> field contain the 170 old and new value as a number. Its exact type is implementation 171 dependant but has to be the same as is returned by the 172 <member>XAccessibleValue::getCurrentValue</member> function. 173 */ 174 175 const short VALUE_CHANGED = 11; 176 177 /** Identifies the change of a relation set: The content flow has 178 changed. 179 180 <p>Not used: The <member>AccessibleEventObject::OldValue</member> and 181 <member>AccessibleEventObject::NewValue</member> fields contain 182 refrences to the old and new predecessor. Note that both references 183 my be <NULL/> to indicate that a flow to the sending object has not 184 existed or does not exist anymore.</p> 185 */ 186 const short CONTENT_FLOWS_FROM_RELATION_CHANGED = 12; 187 188 /** Identifies the change of a relation set: The content flow has 189 changed. 190 191 <p>Not used: The <member>AccessibleEventObject::OldValue</member> and 192 <member>AccessibleEventObject::NewValue</member> fields contain 193 refrences to the old and new successor. Note that both references 194 my be <NULL/> to indicate that a flow from the sending object has not 195 existed or does not exist anymore.</p> 196 */ 197 const short CONTENT_FLOWS_TO_RELATION_CHANGED = 13; 198 199 /** Identifies the change of a relation set: The target object that is 200 doing the controlling has changed. The 201 <member>AccessibleEventObject::OldValue</member> and 202 <member>AccessibleEventObject::NewValue</member> fields contain the 203 old and new controlling objects. 204 */ 205 const short CONTROLLED_BY_RELATION_CHANGED = 14; 206 207 /** Identifies the change of a relation set: The controller for the 208 target object has changed. The 209 <member>AccessibleEventObject::OldValue</member> and 210 <member>AccessibleEventObject::NewValue</member> fields contain the 211 old and new number of controlled objects. 212 */ 213 const short CONTROLLER_FOR_RELATION_CHANGED = 15; 214 215 /** Identifies the change of a relation set: The target group for a 216 label has changed. The 217 <member>AccessibleEventObject::OldValue</member> and 218 <member>AccessibleEventObject::NewValue</member> fields contain the 219 old and new number labeled objects. 220 */ 221 const short LABEL_FOR_RELATION_CHANGED = 16; 222 223 /** Identifies the change of a relation set: The objects that are doing 224 the labeling have changed. The 225 <member>AccessibleEventObject::OldValue</member> and 226 <member>AccessibleEventObject::NewValue</member> fields contain the 227 old and new accessible label. 228 */ 229 const short LABELED_BY_RELATION_CHANGED = 17; 230 231 /** Identifies the change of a relation set: The group membership has 232 changed. The 233 <member>AccessibleEventObject::OldValue</member> and 234 <member>AccessibleEventObject::NewValue</member> fields contain the 235 old and new number of members. 236 */ 237 const short MEMBER_OF_RELATION_CHANGED = 18; 238 239 /** Identifies the change of a relation set: The sub-window-of relation 240 has changed. The 241 <member>AccessibleEventObject::OldValue</member> and 242 <member>AccessibleEventObject::NewValue</member> fields contain the 243 old and new accessible parent window objects. 244 */ 245 const short SUB_WINDOW_OF_RELATION_CHANGED = 19; 246 247 /** Events of this type are sent when the caret has moved to a new 248 position. The old and new position can be found in the 249 <member>AccessibleEventObject::OldValue</member> and 250 <member>AccessibleEventObject::NewValue</member> fields. 251 */ 252 const short CARET_CHANGED = 20; 253 254 /** Events of this type signal changes of the selection. The old or new 255 selection is <em>not</em> available through the event object. You 256 have to query the <type>XAccessibleText</type> interface of the 257 event source for this information. The type of content of the 258 <member>AccessibleEventObject::OldValue</member> and 259 <member>AccessibleEventObject::NewValue</member> fields is not 260 specified at the moment. This may change in the future. 261 */ 262 const short TEXT_SELECTION_CHANGED = 21; 263 264 /** Use this id to indicate general text changes, i.e. changes to text 265 that is exposed through the <type>XAccessibleText</type> and 266 <type>XAccessibleEditableText</type> interfaces. 267 268 <p>The affected text ranges are represented by <type 269 scope="com::sun::star::accessibility">TextSegment</type> structures.<p> 270 271 <p>The content of the <member>AccessibleEventObject::OldValue</member> and 272 <member>AccessibleEventObject::NewValue</member> expresses the type 273 of text change: <ul> <li>Insertion: the 274 <member>AccessibleEventObject::NewValue</member> field specifies the 275 inserted text after the insertion, the 276 <member>AccessibleEventObject::OldValue</member> field remains 277 empty.</li> <li>Deletion: the 278 <member>AccessibleEventObject::OldValue</member> field specifies the 279 deleted text before the deletion, the 280 <member>AccessibleEventObject::NewValue</member> field remains 281 empty.</li> <li>Update/Replace/Modification: the 282 <member>AccessibleEventObject::OldValue</member> and 283 <member>AccessibleEventObject::NewValue</member> fields specify the 284 modified text before respectively after the modification.</li> 285 <li>Unknown: when the type of text change or the place where it took 286 place can not be determined by the event broadcaster then both 287 fields remain empty. In this case the whole text may have changed 288 and the listener should refetch the text completely.</li> </ol> 289 290 <p>When broadcasting an event allways prefer the first three cases 291 to the last one. Use it only as a last resort.</p> 292 293 <p> Text ranges should be as small as possible but, of course, 294 include all the text that is involved in a modification. That means 295 that when two or more discontiguous text ranges are inserted, 296 deleted, or otherwise modified the two fields of the event have to 297 cover all the effected text ranges as well as the text in 298 between.</p> 299 */ 300 const short TEXT_CHANGED = 22; 301 302 303 /** This entry is reserved for future extension. Don't use it right now. 304 */ 305 const short TEXT_ATTRIBUTE_CHANGED = 23; 306 307 /** Constant used to indicate that a hypertext element has received 308 focus. The <member>AccessibleEventObject::OldValue</member> field 309 contains the start index of previously focused element. The 310 <member>AccessibleEventObject::NewValue</member> field holds the 311 start index in the document of the current element that has focus. A 312 value of -1 indicates that an element does not or did not have 313 focus. 314 */ 315 const short HYPERTEXT_CHANGED = 24; 316 /** Constant used to indicate that the table caption has changed. The 317 <member>AccessibleEventObject::OldValue</member> and 318 <member>AccessibleEventObject::NewValue</member> fields contain the 319 old and new accessible objects representing the table caption. 320 */ 321 const short TABLE_CAPTION_CHANGED = 25; 322 323 /** Constant used to indicate that the column description has changed. 324 The <member>AccessibleEventObject::NewValue</member> field contains 325 the column index. The 326 <member>AccessibleEventObject::OldValue</member> is left empty. 327 */ 328 const short TABLE_COLUMN_DESCRIPTION_CHANGED = 26; 329 330 /** Constant used to indicate that the column header has changed. The 331 <member>AccessibleEventObject::OldValue</member> is empty, the 332 <member>AccessibleEventObject::NewValue</member> field contains an 333 <type>AccessibleTableModelChange</type> representing the header 334 change. 335 */ 336 const short TABLE_COLUMN_HEADER_CHANGED = 27; 337 338 /** Constant used to indicate that the table data has changed. The 339 <member>AccessibleEventObject::OldValue</member> is empty, the 340 <member>AccessibleEventObject::NewValue</member> field contains an 341 <type>AccessibleTableModelChange</type> representing the data 342 change. 343 */ 344 const short TABLE_MODEL_CHANGED = 28; 345 346 /** Constant used to indicate that the row description has changed. The 347 <member>AccessibleEventObject::NewValue</member> field contains the 348 row index. The <member>AccessibleEventObject::OldValue</member> is 349 left empty. 350 */ 351 const short TABLE_ROW_DESCRIPTION_CHANGED = 29; 352 353 /** Constant used to indicate that the row header has changed. The 354 <member>AccessibleEventObject::OldValue</member> is empty, the 355 <member>AccessibleEventObject::NewValue</member> field contains an 356 <type>AccessibleTableModelChange</type> representing the header 357 change. 358 */ 359 const short TABLE_ROW_HEADER_CHANGED = 30; 360 361 /** Constant used to indicate that the table summary has changed. The 362 <member>AccessibleEventObject::OldValue</member> and 363 <member>AccessibleEventObject::NewValue</member> fields contain the 364 old and new accessible objects representing the table summary. 365 */ 366 const short TABLE_SUMMARY_CHANGED = 31; 367 368 /** Constant used to indicate that a list box entry has been expanded. 369 <member>AccessibleEventObject::OldValue</member> is empty. 370 <member>AccessibleEventObject::NewValue</member> contains the expanded list box entry. 371 372 @since OOo 3.2 373 */ 374 const short LISTBOX_ENTRY_EXPANDED = 32; 375 376 /** Constant used to indicate that a list box entry has been collapsed. 377 <member>AccessibleEventObject::OldValue</member> is empty. 378 <member>AccessibleEventObject::NewValue</member> contains the collapsed list box entry. 379 380 @since OOo 3.2 381 */ 382 const short LISTBOX_ENTRY_COLLAPSED = 33; 383}; 384 385}; }; }; }; 386 387#endif 388