mirror of
https://github.com/blender/blender
synced 2026-10-25 03:07:01 +03:00
Initial implementation of client side decorations (CSD) as a replacement for LibDecor integration. The main focus is for basic functionality, drawing is fairly simple. The implementation supports: - Wayland (only). - Hi-DPI & fractional scaling. - Mouse, tablet & touch input. - Blender windows and the animation player. Event handling: - Right click on the title-bar to show the menu. - Double-click on the title-bar to maximize. Details: - Events on the decorations still generate GHOST events, in practice they don't map to a area/region and are only handled as decorations. - Events are ignored by the decorations when the cursor is grabbed. - Existing icons are used for buttons were a close match from the existing icons, we may want to add icons for better control over the buttons look. - The animation player uses CSD as an overlay, showing the decorations on hover over the upper part of the window. Resolves: #144919, #108308, #107797. See design task #113795. Ref !148350
44 lines
793 B
CMake
44 lines
793 B
CMake
# SPDX-FileCopyrightText: 2022 Blender Authors
|
|
#
|
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
set(INC
|
|
extern
|
|
|
|
# For internal includes.
|
|
intern
|
|
)
|
|
|
|
set(INC_SYS
|
|
${wayland-client_INCLUDE_DIRS}
|
|
${wayland-cursor_INCLUDE_DIRS}
|
|
)
|
|
|
|
set(SRC
|
|
intern/wayland_dynload_client.c
|
|
intern/wayland_dynload_cursor.c
|
|
intern/wayland_dynload_utils.c
|
|
|
|
extern/wayland_dynload_API.h
|
|
extern/wayland_dynload_client.h
|
|
extern/wayland_dynload_cursor.h
|
|
intern/wayland_dynload_utils.h
|
|
)
|
|
|
|
if(WITH_OPENGL_BACKEND)
|
|
list(APPEND INC_SYS
|
|
${wayland-egl_INCLUDE_DIRS}
|
|
)
|
|
list(APPEND SRC
|
|
intern/wayland_dynload_egl.c
|
|
|
|
extern/wayland_dynload_egl.h
|
|
)
|
|
add_definitions(-DWITH_OPENGL_BACKEND)
|
|
endif()
|
|
|
|
set(LIB
|
|
)
|
|
|
|
|
|
blender_add_lib(bf_intern_wayland_dynload "${SRC}" "${INC}" "${INC_SYS}" "${LIB}")
|