* Copyright (c) 2025 Huawei Device Co., Ltd.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
#ifndef FOUNDATION_ACE_INTERFACE_PARAM_CONFIG_H
#define FOUNDATION_ACE_INTERFACE_PARAM_CONFIG_H
#include <cstdint>
#include <string>
namespace OHOS::Ace {
struct ParamConfig {
bool interactionInfo = false;
bool accessibilityInfo = false;
bool cacheNodes = true;
bool withWeb = false;
bool withUIExtension = false;
bool rectCulling = false;
float minOpacity = 0.0f;
};
struct InteractionParamConfig {
bool isTopMost = true;
};
enum class ChangeType {
PAGE = 0,
SCROLL,
SWIPER,
TABS,
TEXT,
DIALOG,
ARKWEB_PAGE,
ARKWEB_TEXT,
IMAGE_LOADED,
};
struct ContentChangeConfig {
int32_t minReportTime = 100;
float textContentRatio = 0.15f;
std::string ignoreEventType;
int32_t minWidth = 100;
int32_t minHeight = 100;
int32_t reportDelayTime = 600;
};
enum ComponentEventType : uint32_t {
COMPONENT_EVENT_NONE = 0,
COMPONENT_EVENT_GESTURE = 1 << 0,
COMPONENT_EVENT_SELECT = 1 << 1,
COMPONENT_EVENT_ANIMATOR = 1 << 2,
COMPONENT_EVENT_PAGE_TRANSITION = 1 << 3,
COMPONENT_EVENT_SCROLL = 1 << 4,
COMPONENT_EVENT_TEXT_INPUT = 1 << 5,
COMPONENT_EVENT_DIALOG = 1 << 6,
COMPONENT_EVENT_IMAGE = 1 << 7,
COMPONENT_EVENT_PICKER = 1 << 8,
COMPONENT_EVENT_PROGRESS = 1 << 9,
COMPONENT_EVENT_SWIPER = 1 << 10,
COMPONENT_EVENT_WEB = 1 << 11,
COMPONENT_EVENT_MENU = 1 << 12,
COMPONENT_EVENT_SHEET_PRESENTATION = 1 << 13,
COMPONENT_EVENT_MODAL_PRESENTATION = 1 << 14,
COMPONENT_EVENT_VIDEO = 1 << 15,
COMPONENT_EVENT_ALL = static_cast<uint32_t>(-1),
};
}
#endif