Skip to content

Commit

Permalink
Application: hard code gtk styles (#723)
Browse files Browse the repository at this point in the history
  • Loading branch information
danirabbit committed Aug 10, 2022
1 parent bee278d commit 4e22268
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 5 deletions.
3 changes: 3 additions & 0 deletions src/Application.vala
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,9 @@ public class Music.Application : Gtk.Application {
var granite_settings = Granite.Settings.get_default ();
var gtk_settings = Gtk.Settings.get_default ();

gtk_settings.gtk_icon_theme_name = "elementary";
gtk_settings.gtk_theme_name = "io.elementary.stylesheet.orange";

gtk_settings.gtk_application_prefer_dark_theme = (
granite_settings.prefers_color_scheme == Granite.Settings.ColorScheme.DARK
);
Expand Down
5 changes: 0 additions & 5 deletions src/MainWindow.vala
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@ public class Music.MainWindow : Gtk.ApplicationWindow {
construct {
var playback_manager = PlaybackManager.get_default ();

var css_provider = new Gtk.CssProvider ();
css_provider.load_from_data ("@define-color accent_color @ORANGE_500;".data);

Gtk.StyleContext.add_provider_for_display (Gdk.Display.get_default (), css_provider, Gtk.STYLE_PROVIDER_PRIORITY_APPLICATION);

var start_window_controls = new Gtk.WindowControls (Gtk.PackType.START) {
hexpand = true
};
Expand Down

0 comments on commit 4e22268

Please sign in to comment.