2023-06-18 14:02:21 +02:00
|
|
|
mod application;
|
|
|
|
|
mod config;
|
2023-09-20 13:49:02 +02:00
|
|
|
mod home_page;
|
2023-09-30 18:26:11 +02:00
|
|
|
mod library;
|
2023-09-29 21:18:28 +02:00
|
|
|
mod player;
|
2023-10-25 17:45:32 +02:00
|
|
|
mod playlist_item;
|
2023-09-24 11:57:16 +02:00
|
|
|
mod playlist_page;
|
2023-10-25 17:45:32 +02:00
|
|
|
mod playlist_tile;
|
2023-10-08 16:40:59 +02:00
|
|
|
mod recording_tile;
|
2023-09-30 00:22:33 +02:00
|
|
|
mod search_entry;
|
|
|
|
|
mod search_tag;
|
2023-10-08 16:40:59 +02:00
|
|
|
mod tag_tile;
|
2023-09-13 14:58:31 +02:00
|
|
|
mod welcome_page;
|
2023-06-18 14:02:21 +02:00
|
|
|
mod window;
|
|
|
|
|
|
2023-09-13 14:58:31 +02:00
|
|
|
use self::{application::MusicusApplication, window::MusicusWindow};
|
2023-06-18 14:02:21 +02:00
|
|
|
|
|
|
|
|
use config::{GETTEXT_PACKAGE, LOCALEDIR, PKGDATADIR};
|
|
|
|
|
use gettextrs::{bind_textdomain_codeset, bindtextdomain, textdomain};
|
2023-09-13 14:58:31 +02:00
|
|
|
use gtk::{gio, glib, prelude::*};
|
2023-06-18 14:02:21 +02:00
|
|
|
|
|
|
|
|
fn main() -> glib::ExitCode {
|
2023-09-15 10:12:36 +02:00
|
|
|
tracing_subscriber::fmt::init();
|
|
|
|
|
|
2023-06-18 14:02:21 +02:00
|
|
|
bindtextdomain(GETTEXT_PACKAGE, LOCALEDIR).expect("Unable to bind the text domain");
|
|
|
|
|
bind_textdomain_codeset(GETTEXT_PACKAGE, "UTF-8")
|
|
|
|
|
.expect("Unable to set the text domain encoding");
|
|
|
|
|
textdomain(GETTEXT_PACKAGE).expect("Unable to switch to the text domain");
|
|
|
|
|
|
|
|
|
|
let resources = gio::Resource::load(PKGDATADIR.to_owned() + "/musicus.gresource")
|
|
|
|
|
.expect("Could not load resources");
|
|
|
|
|
gio::resources_register(&resources);
|
|
|
|
|
|
2023-09-13 14:58:31 +02:00
|
|
|
MusicusApplication::new("de.johrpan.musicus", &gio::ApplicationFlags::empty()).run()
|
2023-06-18 14:02:21 +02:00
|
|
|
}
|