Skip to content

Commit 9e25b1d

Browse files
committed
fix build issue
1 parent ebd916b commit 9e25b1d

File tree

3 files changed

+8
-7
lines changed

3 files changed

+8
-7
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@ jobs:
3333
cmake --version
3434
if [ "${{ matrix.platform }}" = "linux" ]; then
3535
sudo apt-get update
36-
sudo apt-get install -y ninja-build libgtk-3-dev libx11-dev libxi-dev
36+
sudo apt-get install -y ninja-build libgtk-3-dev libx11-dev libxi-dev libayatana-appindicator3-dev
3737
fi
3838
3939
- name: Configure CMake

src/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,17 +23,17 @@ file(GLOB CAPI_SOURCES "capi/*.cpp" "capi/*.c")
2323

2424
# Platform-specific source files
2525
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
26-
file(GLOB PLATFORM_SOURCES "platform/linux/*_linux.cpp" "platform/linux/display_linux.cpp")
26+
file(GLOB PLATFORM_SOURCES "platform/linux/*_linux.cpp")
2727
# Find packages for Linux
2828
find_package(PkgConfig REQUIRED)
2929
pkg_check_modules(GTK REQUIRED IMPORTED_TARGET gtk+-3.0)
3030
pkg_check_modules(X11 REQUIRED IMPORTED_TARGET x11)
3131
pkg_check_modules(XI REQUIRED IMPORTED_TARGET xi)
3232
pkg_check_modules(AYATANA_APPINDICATOR REQUIRED IMPORTED_TARGET ayatana-appindicator3-0.1)
3333
elseif(APPLE)
34-
file(GLOB PLATFORM_SOURCES "platform/macos/*_macos.mm" "platform/macos/display_macos.mm")
34+
file(GLOB PLATFORM_SOURCES "platform/macos/*_macos.mm")
3535
elseif(WIN32)
36-
file(GLOB PLATFORM_SOURCES "platform/windows/*_windows.cpp" "platform/windows/display_windows.cpp")
36+
file(GLOB PLATFORM_SOURCES "platform/windows/*_windows.cpp")
3737
else()
3838
set(PLATFORM_SOURCES "")
3939
endif()

src/platform/linux/window_linux.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -16,16 +16,17 @@ class Window::Impl {
1616
};
1717

1818
Window::Window() : pimpl_(std::make_unique<Impl>(nullptr)) {
19-
id = -1;
2019
}
2120

2221
Window::Window(void* window) : pimpl_(std::make_unique<Impl>((GdkWindow*)window)) {
23-
// Use pointer address as ID since GDK doesn't provide direct window IDs
24-
id = pimpl_->gdk_window_ ? (WindowID)pimpl_->gdk_window_ : 0;
2522
}
2623

2724
Window::~Window() {
25+
}
2826

27+
WindowID Window::GetId() const{
28+
// Use pointer address as ID since GDK doesn't provide direct window IDs
29+
return pimpl_->gdk_window_ ? (WindowID)pimpl_->gdk_window_ : 0;
2930
}
3031

3132
void Window::Focus() {

0 commit comments

Comments
 (0)