From: Jeremy Bicha <jbicha@debian.org>
Date: Mon, 14 Feb 2022 15:01:30 -0500
Subject: Support GNOME 42 dark theme preference

---
 meson.build               | 2 +-
 src/gnome-calculator.vala | 1 +
 src/meson.build           | 1 +
 3 files changed, 3 insertions(+), 1 deletion(-)

diff --git a/meson.build b/meson.build
index 178a25b..42eb8d5 100644
--- a/meson.build
+++ b/meson.build
@@ -64,7 +64,7 @@ subdir('vapi')
 subdir('gcalc')
 if not get_option ('disable-ui')
 gtk = dependency('gtk+-3.0', version: '>= 3.24.1')
-libhandy = dependency('libhandy-1', version: '>= 1.0.0')
+libhandy = dependency('libhandy-1', version: '>= 1.5.90')
 subdir('gci')
 gtksourceview = dependency('gtksourceview-4', version: '>= 4.0.2')
 subdir('data')
diff --git a/src/gnome-calculator.vala b/src/gnome-calculator.vala
index 49b0b92..0579643 100644
--- a/src/gnome-calculator.vala
+++ b/src/gnome-calculator.vala
@@ -117,6 +117,7 @@ public class Calculator : Gtk.Application
         base.startup ();
 
         Hdy.init ();
+        Hdy.StyleManager.get_default().set_color_scheme(Hdy.ColorScheme.PREFER_LIGHT);
 
         settings = new Settings ("org.gnome.calculator");
         settings.delay ();
diff --git a/src/meson.build b/src/meson.build
index d4ee5ff..a6e7f5c 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -36,6 +36,7 @@ gnome_calculator_vala_flags = [
   '--vapidir=' + meson.current_source_dir(),
   '--pkg', 'config',
   '--gresources', gnome_calculator_resource_files,
+  '--disable-since-check',
   '--vapidir='+gcalc_vapi_dir
 ]
 
