aboutsummaryrefslogtreecommitdiff
path: root/devel/electron13/files/patch-electron_shell_browser_ui_views_menu__bar.cc
blob: b2ea7329cc42c4fc91db755129624e756547a019 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
--- electron/shell/browser/ui/views/menu_bar.cc.orig	2021-10-11 17:12:26 UTC
+++ electron/shell/browser/ui/views/menu_bar.cc
@@ -17,7 +17,7 @@
 #include "ui/views/layout/box_layout.h"
 #include "ui/views/widget/widget.h"
 
-#if defined(OS_LINUX)
+#if defined(OS_LINUX) || defined(OS_BSD)
 #include "ui/gtk/gtk_util.h"
 #endif
 
@@ -293,7 +293,7 @@ void MenuBar::ButtonPressed(int id, const ui::Event& e
 void MenuBar::RefreshColorCache() {
   const ui::NativeTheme* theme = GetNativeTheme();
   if (theme) {
-#if defined(OS_LINUX)
+#if defined(OS_LINUX) || defined(OS_BSD)
     background_color_ = gtk::GetBgColor("GtkMenuBar#menubar");
     enabled_color_ =
         gtk::GetFgColor("GtkMenuBar#menubar GtkMenuItem#menuitem GtkLabel");
@@ -331,7 +331,7 @@ void MenuBar::UpdateViewColors() {
   // set child colors
   if (menu_model_ == nullptr)
     return;
-#if defined(OS_LINUX)
+#if defined(OS_LINUX) || defined(OS_BSD)
   const auto& textColor = has_focus_ ? enabled_color_ : disabled_color_;
   for (auto* child : GetChildrenInZOrder()) {
     auto* button = static_cast<SubmenuButton*>(child);