diff --git a/dm/BUILD.gn b/dm/BUILD.gn index e6ee260292..5c68145bb3 100644 --- a/dm/BUILD.gn +++ b/dm/BUILD.gn @@ -138,6 +138,7 @@ ohos_shared_library("libdm") { "image_framework:image_native", "ipc:ipc_single", "samgr:samgr_proxy", + "graphic_2d:librender_service_base", ] innerapi_tags = [ "platformsdk" ] diff --git a/dmserver/BUILD.gn b/dmserver/BUILD.gn index 4d74bf6046..20c32392d1 100644 --- a/dmserver/BUILD.gn +++ b/dmserver/BUILD.gn @@ -76,6 +76,8 @@ ohos_shared_library("libdms") { "ipc:ipc_single", "libxml2:libxml2", "safwk:system_ability_fwk", + "samgr:samgr_proxy", + "graphic_2d:librender_service_base", ] defines = [] diff --git a/extension/extension_connection/BUILD.gn b/extension/extension_connection/BUILD.gn index 9a3351e0d0..4326cfe6f2 100644 --- a/extension/extension_connection/BUILD.gn +++ b/extension/extension_connection/BUILD.gn @@ -67,6 +67,7 @@ ohos_shared_library("libwindow_extension_client") { "hitrace:hitrace_meter", "input:libmmi-client", "ipc:ipc_single", + "graphic_2d:librender_service_base", ] innerapi_tags = [ "platformsdk_indirect" ] diff --git a/extension/window_extension/BUILD.gn b/extension/window_extension/BUILD.gn index 4edcfc5094..a0da237583 100644 --- a/extension/window_extension/BUILD.gn +++ b/extension/window_extension/BUILD.gn @@ -80,6 +80,9 @@ ohos_shared_library("libwindow_extension") { "input:libmmi-client", "ipc:ipc_single", "napi:ace_napi", + "ipc:ipc_napi", + "ability_runtime:wantagent_innerkits", + "graphic_2d:librender_service_base", ] part_name = "window_manager" diff --git a/interfaces/kits/cj/window_runtime/BUILD.gn b/interfaces/kits/cj/window_runtime/BUILD.gn index 17d9149bb4..74d0cd7442 100644 --- a/interfaces/kits/cj/window_runtime/BUILD.gn +++ b/interfaces/kits/cj/window_runtime/BUILD.gn @@ -69,6 +69,8 @@ ohos_shared_library("cj_window_ffi") { "napi:ace_napi", "napi:cj_bind_ffi", "napi:cj_bind_native", + "ability_runtime:wantagent_innerkits", + "graphic_2d:librender_service_base", ] } else { defines += [ "PREVIEWER" ] diff --git a/interfaces/kits/napi/extension_window/BUILD.gn b/interfaces/kits/napi/extension_window/BUILD.gn index 790447e586..5d79d5c57d 100644 --- a/interfaces/kits/napi/extension_window/BUILD.gn +++ b/interfaces/kits/napi/extension_window/BUILD.gn @@ -107,6 +107,8 @@ ohos_shared_library("extensionwindow_napi") { "hilog:libhilog", "hitrace:hitrace_meter", "napi:ace_napi", + "bundle_framework:appexecfwk_base", + "ability_runtime:ability_manager", ] innerapi_tags = [ "platformsdk" ] diff --git a/interfaces/kits/napi/screen_runtime/BUILD.gn b/interfaces/kits/napi/screen_runtime/BUILD.gn index c84e4781dd..70b3c8cecf 100644 --- a/interfaces/kits/napi/screen_runtime/BUILD.gn +++ b/interfaces/kits/napi/screen_runtime/BUILD.gn @@ -50,6 +50,7 @@ ohos_shared_library("screen_napi") { "ability_runtime:runtime", "c_utils:utils", "graphic_surface:surface", # use for SurfaceUtils + "graphic_2d:librender_service_base", "hilog:libhilog", "hitrace:hitrace_meter", "napi:ace_napi", diff --git a/interfaces/kits/napi/window_runtime/BUILD.gn b/interfaces/kits/napi/window_runtime/BUILD.gn index bca28858c0..7d97c6ee88 100644 --- a/interfaces/kits/napi/window_runtime/BUILD.gn +++ b/interfaces/kits/napi/window_runtime/BUILD.gn @@ -114,6 +114,7 @@ ohos_shared_library("window_napi") { cfi_vcall_icall_only = true debug = false } + defines = ["SUPPORT_SCREEN"] sources = [ "window_manager_napi/js_window_manager.cpp", "window_manager_napi/window_manager_module.cpp", @@ -144,6 +145,8 @@ ohos_shared_library("window_napi") { "hitrace:hitrace_meter", "image_framework:image", "napi:ace_napi", + "ability_runtime:wantagent_innerkits", + "graphic_2d:librender_service_base", ] relative_install_dir = "module" @@ -181,6 +184,7 @@ ohos_shared_library("windowstage_kit") { "c_utils:utils", "hilog:libhilog", "napi:ace_napi", + "ability_runtime:ability_manager", ] innerapi_tags = [ "platformsdk" ] diff --git a/previewer/BUILD.gn b/previewer/BUILD.gn index 4b24e14bd4..0c42bcfae5 100644 --- a/previewer/BUILD.gn +++ b/previewer/BUILD.gn @@ -144,6 +144,7 @@ if (!ispreview) { "ace_engine:ace_uicontent", "hilog:libhilog", "napi:ace_napi", + "ability_runtime:ability_manager", ] cflags_cc = [ "-DWINDOW_PREVIEW" ] diff --git a/setresolution/BUILD.gn b/setresolution/BUILD.gn index ee6a7bd382..f4479c78a7 100644 --- a/setresolution/BUILD.gn +++ b/setresolution/BUILD.gn @@ -40,6 +40,7 @@ ohos_executable("setresolution_screen") { external_deps = [ "c_utils:utils", + "graphic_2d:librender_service_base", "graphic_surface:surface", "init:libbegetutil", ] diff --git a/utils/include/window_transition_info.h b/utils/include/window_transition_info.h index 43b55529ca..c1a48f367e 100644 --- a/utils/include/window_transition_info.h +++ b/utils/include/window_transition_info.h @@ -15,6 +15,9 @@ #ifndef OHOS_ROSEN_WINDOW_TRANSITION_INFO_H #define OHOS_ROSEN_WINDOW_TRANSITION_INFO_H +#ifndef SUPPORT_GRAPHICS +#define SUPPORT_GRAPHICS +#endif #include #include diff --git a/window_scene/intention_event/BUILD.gn b/window_scene/intention_event/BUILD.gn index 878a577f55..6c1e6955a9 100644 --- a/window_scene/intention_event/BUILD.gn +++ b/window_scene/intention_event/BUILD.gn @@ -54,6 +54,8 @@ ohos_shared_library("libintention_event") { "hitrace:hitrace_meter", "init:libbegetutil", "input:libmmi-client", + "libxml2:libxml2", + "graphic_2d:librender_service_base", ] defines = [] diff --git a/window_scene/intention_event/service/BUILD.gn b/window_scene/intention_event/service/BUILD.gn index fd1cbc6577..38c81c52e3 100644 --- a/window_scene/intention_event/service/BUILD.gn +++ b/window_scene/intention_event/service/BUILD.gn @@ -54,6 +54,7 @@ ohos_shared_library("intention_event_anr_manager") { "hisysevent:libhisysevent", "hitrace:hitrace_meter", "ipc:ipc_single", + "bundle_framework:appexecfwk_base", ] if (defined(global_parts_info) && diff --git a/window_scene/intention_event/src/intention_event_manager.cpp b/window_scene/intention_event/src/intention_event_manager.cpp index 03c73cc6dd..f428d0c696 100644 --- a/window_scene/intention_event/src/intention_event_manager.cpp +++ b/window_scene/intention_event/src/intention_event_manager.cpp @@ -95,7 +95,7 @@ bool IntentionEventManager::EnableInputEventListener(Ace::UIContent* uiContent, TLOGI(WmsLogTag::WMS_EVENT, "SetWindowInputEventConsumer success"); if (IS_BETA) { // Xcollie's SetTimerCounter task is set with the params to record count and time of the input down event - int id = HiviewDFX::XCollie::GetInstance().SetTimerCount("FREQUENT_CLICK_WARNING", FREQUENT_CLICK_TIME_LIMIT, + [[maybe_unused]] int id = HiviewDFX::XCollie::GetInstance().SetTimerCount("FREQUENT_CLICK_WARNING", FREQUENT_CLICK_TIME_LIMIT, FREQUENT_CLICK_COUNT_LIMIT); } return true; diff --git a/window_scene/interfaces/kits/napi/scene_session_manager/BUILD.gn b/window_scene/interfaces/kits/napi/scene_session_manager/BUILD.gn index 98ce641ac6..725af7cf38 100644 --- a/window_scene/interfaces/kits/napi/scene_session_manager/BUILD.gn +++ b/window_scene/interfaces/kits/napi/scene_session_manager/BUILD.gn @@ -69,6 +69,9 @@ ohos_shared_library("scenesessionmanager_napi") { "input:libmmi-client", "ipc:ipc_single", "napi:ace_napi", + "libxml2:libxml2", + "preferences:native_preferences", + "graphic_2d:librender_service_base", ] defines = [] diff --git a/window_scene/interfaces/kits/napi/screen_session_manager/BUILD.gn b/window_scene/interfaces/kits/napi/screen_session_manager/BUILD.gn index fb3e6e352e..75b85cd40a 100644 --- a/window_scene/interfaces/kits/napi/screen_session_manager/BUILD.gn +++ b/window_scene/interfaces/kits/napi/screen_session_manager/BUILD.gn @@ -54,6 +54,7 @@ ohos_shared_library("screensessionmanager_napi") { "image_framework:image_native", "ipc:ipc_core", "napi:ace_napi", + "graphic_2d:librender_service_base", ] defines = [] diff --git a/window_scene/interfaces/kits/napi/transaction_manager/BUILD.gn b/window_scene/interfaces/kits/napi/transaction_manager/BUILD.gn index 1f377f5263..44ee48d0cf 100644 --- a/window_scene/interfaces/kits/napi/transaction_manager/BUILD.gn +++ b/window_scene/interfaces/kits/napi/transaction_manager/BUILD.gn @@ -48,6 +48,8 @@ ohos_shared_library("transactionmanager_napi") { "ability_runtime:runtime", "c_utils:utils", "ffrt:libffrt", + "libxml2:libxml2", + "graphic_2d:librender_service_base", "graphic_2d:librender_service_client", "hilog:libhilog", "napi:ace_napi", diff --git a/window_scene/session/BUILD.gn b/window_scene/session/BUILD.gn index 6c3f705d6d..e420abb8e7 100644 --- a/window_scene/session/BUILD.gn +++ b/window_scene/session/BUILD.gn @@ -94,6 +94,7 @@ ohos_shared_library("scene_session") { "init:libbegetutil", "input:libmmi-client", "ipc:ipc_single", + "graphic_2d:librender_service_base", ] if (!(host_os == "linux" && host_cpu == "arm64")) { external_deps += [ "preferences:native_preferences" ] @@ -183,6 +184,7 @@ ohos_shared_library("screen_session") { "hisysevent:libhisysevent", "hitrace:hitrace_meter", "init:libbegetutil", + "graphic_2d:librender_service_base", ] public_external_deps = [ "ability_base:base", diff --git a/window_scene/session_manager/BUILD.gn b/window_scene/session_manager/BUILD.gn index ce3a56e6bf..fb53aa2614 100644 --- a/window_scene/session_manager/BUILD.gn +++ b/window_scene/session_manager/BUILD.gn @@ -132,6 +132,10 @@ ohos_shared_library("scene_session_manager") { "napi:ace_napi", "resource_management:global_resmgr", "samgr:samgr_proxy", + "safwk:system_ability_fwk", + "bundle_framework:libappexecfwk_common", + "preferences:native_preferences", + "graphic_2d:librender_service_base", ] defines = [] @@ -232,6 +236,7 @@ ohos_shared_library("session_manager") { "ipc:ipc_single", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "graphic_2d:librender_service_base", ] innerapi_tags = [ "platformsdk_indirect" ] diff --git a/window_scene/session_manager/include/scene_session_manager.h b/window_scene/session_manager/include/scene_session_manager.h index 8b5829b91c..376b671ce6 100644 --- a/window_scene/session_manager/include/scene_session_manager.h +++ b/window_scene/session_manager/include/scene_session_manager.h @@ -21,6 +21,12 @@ #include #include +#ifndef OHOS_BUILD_ENABLE_SECURITY_COMPONENT // pointer_envent.h +#define OHOS_BUILD_ENABLE_SECURITY_COMPONENT +#endif +#ifndef SUPPORT_SCREEN +#define SUPPORT_SCREEN +#endif #include "mission_snapshot.h" #include "transaction/rs_interfaces.h" diff --git a/window_scene/session_manager/include/session_listener_controller.h b/window_scene/session_manager/include/session_listener_controller.h index 00bfbb6630..9d54b8ddcd 100644 --- a/window_scene/session_manager/include/session_listener_controller.h +++ b/window_scene/session_manager/include/session_listener_controller.h @@ -20,6 +20,10 @@ #include #include +#include "pixel_map.h" +#ifndef SUPPORT_SCREEN +#define SUPPORT_SCREEN +#endif #include "mission_listener_interface.h" #include "ws_common.h" diff --git a/window_scene/session_manager/src/anomaly_detection.cpp b/window_scene/session_manager/src/anomaly_detection.cpp index 4930d48495..3d3e14291d 100644 --- a/window_scene/session_manager/src/anomaly_detection.cpp +++ b/window_scene/session_manager/src/anomaly_detection.cpp @@ -23,7 +23,7 @@ namespace OHOS { namespace Rosen { namespace { -constexpr OHOS::HiviewDFX::HiLogLabel LABEL = { LOG_CORE, HILOG_DOMAIN_WINDOW, "AnomalyDetection" }; +[[maybe_unused]] constexpr OHOS::HiviewDFX::HiLogLabel LABEL = { LOG_CORE, HILOG_DOMAIN_WINDOW, "AnomalyDetection" }; } void AnomalyDetection::SceneZOrderCheckProcess() diff --git a/window_scene/session_manager/src/scene_session_dirty_manager.cpp b/window_scene/session_manager/src/scene_session_dirty_manager.cpp index dd97589682..c91d2ec12f 100644 --- a/window_scene/session_manager/src/scene_session_dirty_manager.cpp +++ b/window_scene/session_manager/src/scene_session_dirty_manager.cpp @@ -256,7 +256,7 @@ void SceneSessionDirtyManager::UpdateHotAreas(sptr sceneSession, s WLOGFE("sceneSession is nullptr"); return; } - WSRect windowRect = sceneSession->GetSessionGlobalRect(); + [[maybe_unused]] WSRect windowRect = sceneSession->GetSessionGlobalRect(); const std::vector& hotAreas = sceneSession->GetTouchHotAreas(); for (auto area : hotAreas) { MMI::Rect rect; diff --git a/window_scene/session_manager/src/scene_session_manager.cpp b/window_scene/session_manager/src/scene_session_manager.cpp index e7dcffe795..afef006327 100644 --- a/window_scene/session_manager/src/scene_session_manager.cpp +++ b/window_scene/session_manager/src/scene_session_manager.cpp @@ -112,7 +112,7 @@ constexpr int SCALE_MAX_WIDTH = 8; constexpr int PID_MAX_WIDTH = 8; constexpr int PARENT_ID_MAX_WIDTH = 6; constexpr int WINDOW_NAME_MAX_LENGTH = 20; -constexpr int32_t STATUS_BAR_AVOID_AREA = 0; +[[maybe_unused]] constexpr int32_t STATUS_BAR_AVOID_AREA = 0; const std::string ARG_DUMP_ALL = "-a"; const std::string ARG_DUMP_WINDOW = "-w"; const std::string ARG_DUMP_SCREEN = "-s"; @@ -638,7 +638,7 @@ void SceneSessionManager::ConfigDecor(const WindowSceneConfig::ConfigItem& decor } else { systemConfig_.freeMultiWindowConfig_.isSystemDecorEnable_ = item.boolValue_; } - bool decorEnable = item.boolValue_; + [[maybe_unused]] bool decorEnable = item.boolValue_; uint32_t support = 0; std::vector supportedModes; item = decorConfig["supportedMode"]; diff --git a/window_scene/session_manager/src/zidl/scene_session_manager_lite_stub.cpp b/window_scene/session_manager/src/zidl/scene_session_manager_lite_stub.cpp index e8164de63e..9eba3a12a7 100644 --- a/window_scene/session_manager/src/zidl/scene_session_manager_lite_stub.cpp +++ b/window_scene/session_manager/src/zidl/scene_session_manager_lite_stub.cpp @@ -21,7 +21,7 @@ namespace OHOS::Rosen { namespace { constexpr HiviewDFX::HiLogLabel LABEL = {LOG_CORE, HILOG_DOMAIN_WINDOW, "SceneSessionManagerLiteStub"}; -constexpr uint32_t MAX_VECTOR_SIZE = 100; +[[maybe_unused]] constexpr uint32_t MAX_VECTOR_SIZE = 100; constexpr uint32_t MAX_TOPN_INFO_SIZE = 200; } diff --git a/window_scene/session_manager/src/zidl/scene_session_manager_proxy.cpp b/window_scene/session_manager/src/zidl/scene_session_manager_proxy.cpp index 3ad7370fbf..a5039762e5 100644 --- a/window_scene/session_manager/src/zidl/scene_session_manager_proxy.cpp +++ b/window_scene/session_manager/src/zidl/scene_session_manager_proxy.cpp @@ -12,7 +12,9 @@ * See the License for the specific language governing permissions and * limitations under the License. */ - +#ifndef SUPPORT_SCREEN +#define SUPPORT_SCREEN +#endif #include "session_manager/include/zidl/scene_session_manager_proxy.h" #include diff --git a/wm/BUILD.gn b/wm/BUILD.gn index 0da8a8deb0..5421314508 100644 --- a/wm/BUILD.gn +++ b/wm/BUILD.gn @@ -132,6 +132,7 @@ ohos_static_library("libwm_static") { "ipc:ipc_single", "napi:ace_napi", "samgr:samgr_proxy", + "bundle_framework:libappexecfwk_common", ] defines = [] @@ -268,6 +269,8 @@ ohos_shared_library("libwm") { "ipc:ipc_single", "napi:ace_napi", "samgr:samgr_proxy", + "bundle_framework:libappexecfwk_common", + "graphic_2d:librender_service_base", ] defines = [] @@ -427,6 +430,7 @@ ohos_shared_library("libwm_ndk") { "hilog:libhilog", "input:libmmi-client", "input:oh_input_manager", + "ipc:ipc_core", ] part_name = "window_manager" diff --git a/wmserver/BUILD.gn b/wmserver/BUILD.gn index 0a20a8eea7..e316351624 100644 --- a/wmserver/BUILD.gn +++ b/wmserver/BUILD.gn @@ -114,6 +114,7 @@ ohos_shared_library("sms") { "ipc:ipc_single", "safwk:system_ability_fwk", "samgr:samgr_proxy", + "graphic_2d:librender_service_base", ] public_external_deps = [ "ability_runtime:ability_manager", @@ -148,7 +149,10 @@ if (window_manager_use_sceneboard) { cfi_vcall_icall_only = true debug = false } - defines = [] + defines = [ + "SUPPORT_SCREEN", + "SUPPORT_GRAPHICS", + ] if (use_musl) { if (musl_use_jemalloc && musl_use_jemalloc_dfx_intf) { defines += [ "CONFIG_USE_JEMALLOC_DFX_INTF" ] @@ -223,10 +227,12 @@ if (window_manager_use_sceneboard) { "hisysevent:libhisysevent", "hitrace:hitrace_meter", "image_framework:image_native", + "preferences:native_preferences", "input:libmmi-client", "ipc:ipc_single", "libxml2:libxml2", "safwk:system_ability_fwk", + "graphic_2d:librender_service_base", ] if (defined(global_parts_info) &&