Skip to content

Commit

Permalink
Bug 1698969 - Add some colors to HeadlessLookAndFeelGTK so that some …
Browse files Browse the repository at this point in the history
…widgets render properly in headless mode. r=mstange

Colors match Adwaita (the default GTK theme).

Differential Revision: https://phabricator.services.mozilla.com/D108697
  • Loading branch information
emilio committed Mar 16, 2021
1 parent c6956c2 commit bf088d6
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions widget/headless/HeadlessLookAndFeelGTK.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,14 @@ nsresult HeadlessLookAndFeel::NativeGetColor(ColorID aID, nscolor& aColor) {
case ColorID::WindowForeground:
aColor = NS_RGB(0x00, 0x00, 0x00);
break;
case ColorID::Highlight:
case ColorID::MozAccentColor:
aColor = NS_RGB(53, 132, 228);
break;
case ColorID::Highlighttext:
case ColorID::MozAccentColorForeground:
aColor = NS_RGB(0xff, 0xff, 0xff);
break;
default:
aColor = GetStandinForNativeColor(aID);
break;
Expand Down

0 comments on commit bf088d6

Please sign in to comment.