Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

[Linux] show/hide emission hooks are never removed; verify clean exit

Đang mở
#60 0 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức phù hợp với người mới
68/100
Loại issue
Lỗi
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Sôi nổi
Công nghệ
cpp, linux
Lĩnh vực
desktop, operating-systems

Hướng nghiên cứu

Start in src/platform/linux/window_manager_linux.cpp at InstallGlobalSwizzling(), comparing the show/hide hooks with the nearby focus-in/focus-out hooks. Trace where window_manager shuts down and verify the hook lifecycle there. Done means a nativeapi Flutter app exits cleanly on Linux under X11 and Wayland, including after closing a secondary window created through package:nativeapi/windowing.dart.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

bug

InstallGlobalSwizzling() in src/platform/linux/window_manager_linux.cpp adds show / hide emission hooks on GtkWidget with g_signal_add_emission_hook(), but doesn't keep the hook ids, so they are never removed. The focus-in/focus-out hooks next to them are removed properly.

window_manager had a similar never-removed button-press-event emission hook in its Linux plugin. Users reported crashes when the app exits, or when a secondary Flutter window closes: FlutterEngineRemoveView ... The implicit view cannot be removed, followed by an epoxy/GLX assertion. The hooks here pass no user data, so they probably can't use a freed plugin pointer, but that should be confirmed:

  • keep the hook ids and remove them when the manager shuts down
  • check that a Flutter app with nativeapi exits cleanly on Linux (X11 and Wayland), including after a secondary window created through package:nativeapi/windowing.dart is closed

Background:

  • leanflutter/window_manager#585: crash on exit on Fedora 44 KDE X11, from just having the plugin
  • leanflutter/window_manager#567: a PR that removes the emission hook on plugin dispose
Ngôn ngữ chính
C++
Star
34
Fork
7
Merge trung bình
3 ngày 1 giờ
Pull request đã merge (30 ngày)
1

Hướng dẫn đóng góp

Chưa lập chỉ mục được hướng dẫn đóng góp cho kho mã nguồn này

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của libnativeapi/nativeapi

Tất cả issue của libnativeapi/nativeapi

Issue tương tự

Thêm issue về C++

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.