1 /* 2 * Copyright (C) 2022 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16 #ifndef ACCESSIBILITY_CONSTANTS_H 17 #define ACCESSIBILITY_CONSTANTS_H 18 19 #include <cstdint> 20 #include <string> 21 22 namespace OHOS { 23 namespace Accessibility { 24 // text move step 25 extern const std::string MOVE_UNIT_CHARACTER; 26 extern const std::string MOVE_UNIT_WORD; 27 extern const std::string MOVE_UNIT_LINE; 28 extern const std::string MOVE_UNIT_PAGE; 29 extern const std::string MOVE_UNIT_PARAGRAPH; 30 31 // Operation Arguments Type 32 extern const std::string ACTION_ARGU_INVALID; 33 extern const std::string ACTION_ARGU_SELECT_TEXT_START; 34 extern const std::string ACTION_ARGU_SELECT_TEXT_END; 35 extern const std::string ACTION_ARGU_HTML_ELEMENT; 36 extern const std::string ACTION_ARGU_SET_TEXT; 37 extern const std::string ACTION_ARGU_MOVE_UNIT; 38 39 // HtmlItemType 40 extern const std::string HTML_ITEM_INVALID; 41 extern const std::string HTML_ITEM_LINK; 42 extern const std::string HTML_ITEM_CONTROL; 43 extern const std::string HTML_ITEM_GRAPHIC; 44 extern const std::string HTML_ITEM_LIST_ITEM; 45 extern const std::string HTML_ITEM_LIST; 46 extern const std::string HTML_ITEM_TABLE; 47 extern const std::string HTML_ITEM_COMBOX; 48 extern const std::string HTML_ITEM_HEADING; 49 extern const std::string HTML_ITEM_BUTTON; 50 extern const std::string HTML_ITEM_CHECKBOX; 51 extern const std::string HTML_ITEM_LANDMARK; 52 extern const std::string HTML_ITEM_TEXT_FIELD; 53 extern const std::string HTML_ITEM_FOCUSABLE; 54 extern const std::string HTML_ITEM_H1; 55 extern const std::string HTML_ITEM_H2; 56 extern const std::string HTML_ITEM_H3; 57 extern const std::string HTML_ITEM_H4; 58 extern const std::string HTML_ITEM_H5; 59 extern const std::string HTML_ITEM_H6; 60 extern const std::string HTML_ITEM_UNKOWN; 61 62 extern const std::string OHOS_PERMISSION_READ_ACCESSIBILITY_CONFIG; 63 extern const std::string OHOS_PERMISSION_WRITE_ACCESSIBILITY_CONFIG; 64 extern const std::string OHOS_PERMISSION_QUERY_ACCESSIBILITY_ELEMENT; 65 66 extern const int32_t PREFETCH_PREDECESSORS; 67 extern const int32_t PREFETCH_SIBLINGS; 68 extern const int32_t PREFETCH_CHILDREN; 69 extern const int32_t PREFETCH_RECURSIVE_CHILDREN; 70 extern const int32_t GET_SOURCE_MODE; 71 extern const int32_t UNDEFINED; 72 extern const int32_t GET_SOURCE_PREFETCH_MODE; 73 extern const int32_t UNDEFINED_SELECTION_INDEX; 74 extern const int32_t UNDEFINED_ITEM_ID; 75 extern const int32_t ROOT_ITEM_ID; 76 extern const int32_t MAX_TEXT_LENGTH; 77 extern const int32_t HOST_VIEW_ID; 78 extern const int64_t ROOT_NODE_ID; 79 80 // Focus types 81 extern const int32_t FOCUS_TYPE_INVALID; 82 extern const int32_t FOCUS_TYPE_INPUT; 83 extern const int32_t FOCUS_TYPE_ACCESSIBILITY; 84 85 // grid mode 86 extern const int32_t SELECTION_MODE_NONE; 87 extern const int32_t SELECTION_MODE_SINGLE; 88 extern const int32_t SELECTION_MODE_MULTIPLE; 89 90 extern const int32_t INVALID_WINDOW_ID; 91 extern const int32_t ANY_WINDOW_ID; 92 extern const int32_t ACTIVE_WINDOW_ID; 93 94 extern const uint32_t STATE_ACCESSIBILITY_ENABLED; 95 extern const uint32_t STATE_EXPLORATION_ENABLED; 96 extern const uint32_t STATE_CAPTION_ENABLED; 97 extern const uint32_t STATE_KEYEVENT_ENABLED; 98 extern const uint32_t STATE_GESTURE_ENABLED; 99 extern const uint32_t STATE_SCREENMAGNIFIER_ENABLED; 100 extern const uint32_t STATE_MOUSEKEY_ENABLED; 101 extern const uint32_t STATE_SHORTKEY_ENABLED; 102 extern const uint32_t STATE_HIGHCONTRAST_ENABLED; 103 extern const uint32_t STATE_INVETRTCOLOR_ENABLED; 104 extern const uint32_t STATE_ANIMATIONOFF_ENABLED; 105 extern const uint32_t STATE_DALTONIZATION_STATE_ENABLED; 106 extern const uint32_t STATE_AUDIOMONO_ENABLED; 107 extern const uint32_t STATE_IGNORE_REPEAT_CLICK_ENABLED; 108 extern const int32_t INVALID_CHANNEL_ID; 109 } // namespace Accessibility 110 } // namespace OHOS 111 #endif // ACCESSIBILITY_CONSTANTS_H