From 7aa2e63159419dce2f4537290c1bf1ee7bcb76a8 Mon Sep 17 00:00:00 2001 From: msizanoen1 Date: Mon, 18 Jul 2022 21:52:13 +0700 Subject: [PATCH] fix: wayland window top bar buttons unclickable Use `views::SetHitTestComponent` to make sure that chromium actually knows which element got hit. --- shell/browser/ui/views/client_frame_view_linux.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/shell/browser/ui/views/client_frame_view_linux.cc b/shell/browser/ui/views/client_frame_view_linux.cc index efb5870ee193b..c31b33d07ed5c 100644 --- a/shell/browser/ui/views/client_frame_view_linux.cc +++ b/shell/browser/ui/views/client_frame_view_linux.cc @@ -72,6 +72,7 @@ ClientFrameViewLinux::ClientFrameViewLinux() button.button->SetImageVerticalAlignment(views::ImageButton::ALIGN_MIDDLE); button.button->SetAccessibleName( l10n_util::GetStringUTF16(button.accessibility_id)); + views::SetHitTestComponent(button.button, button.hit_test_id); AddChildView(button.button); }