diff --git a/src/core/lisp.rs b/src/core/lisp.rs index af3c937..2c1a666 100644 --- a/src/core/lisp.rs +++ b/src/core/lisp.rs @@ -133,12 +133,6 @@ pub(crate) fn get_lists(exp: &Value) -> Vec { #[cfg(test)] mod test { - - - - - - // #[test] // fn test_list() { diff --git a/src/core/model.rs b/src/core/model.rs index 09d8663..a0afcd0 100644 --- a/src/core/model.rs +++ b/src/core/model.rs @@ -4,7 +4,6 @@ use cosmic::iced::Executor; use miette::{miette, Result}; use sqlx::{Connection, SqliteConnection}; - #[derive(Debug, Clone)] pub struct Model { pub items: Vec, diff --git a/src/core/service_items.rs b/src/core/service_items.rs index f8d6655..c9483cd 100644 --- a/src/core/service_items.rs +++ b/src/core/service_items.rs @@ -175,11 +175,9 @@ impl From<&Value> for ServiceItem { Value::Symbol(Symbol(s)) if s == "presentation" => { - Self::from( - &Presentation::from( - background, - ), - ) + Self::from(&Presentation::from( + background, + )) } _ => todo!(), }, diff --git a/src/core/songs.rs b/src/core/songs.rs index 9b0d40a..20dbebb 100644 --- a/src/core/songs.rs +++ b/src/core/songs.rs @@ -535,7 +535,6 @@ impl Song { lyric_list.push(lyric.to_string()); } else { // error!("NOT WORKING!"); - }; } // for lyric in lyric_list.iter() { diff --git a/src/lisp.rs b/src/lisp.rs index 2406ea4..2f803e4 100644 --- a/src/lisp.rs +++ b/src/lisp.rs @@ -37,10 +37,7 @@ pub fn parse_lisp(value: Value) -> Vec { #[cfg(test)] mod test { - use std::{ - fs::read_to_string, - path::PathBuf, - }; + use std::{fs::read_to_string, path::PathBuf}; use crate::{ core::{ diff --git a/src/main.rs b/src/main.rs index 495b27e..91ae9ee 100644 --- a/src/main.rs +++ b/src/main.rs @@ -13,13 +13,12 @@ use cosmic::iced_widget::{column, row}; use cosmic::widget::dnd_destination::DragId; use cosmic::widget::nav_bar::nav_bar_style; use cosmic::widget::segmented_button::Entity; +use cosmic::widget::text; use cosmic::widget::tooltip::Position as TPosition; use cosmic::widget::{ - button, horizontal_space, nav_bar, search_input, - tooltip, Space, + button, horizontal_space, nav_bar, search_input, tooltip, Space, }; use cosmic::widget::{icon, slider}; -use cosmic::widget::text; use cosmic::{executor, Application, ApplicationExt, Element}; use cosmic::{prelude::*, theme}; use cosmic::{widget::Container, Theme}; @@ -879,8 +878,6 @@ where #[cfg(test)] mod test { - - fn test_slide() -> String { let slide = r#"(slide (image :source "./somehting.jpg" :fill cover diff --git a/src/ui/library.rs b/src/ui/library.rs index a239209..80570e4 100644 --- a/src/ui/library.rs +++ b/src/ui/library.rs @@ -13,9 +13,7 @@ use cosmic::{ Element, Task, }; use miette::{IntoDiagnostic, Result}; -use sqlx::{ - pool::PoolConnection, Sqlite, SqlitePool, -}; +use sqlx::{pool::PoolConnection, Sqlite, SqlitePool}; use tracing::{debug, error, warn}; use crate::core::{ diff --git a/src/ui/presenter.rs b/src/ui/presenter.rs index ea33ea4..d103617 100644 --- a/src/ui/presenter.rs +++ b/src/ui/presenter.rs @@ -32,7 +32,6 @@ use crate::{ BackgroundKind, }; - const REFERENCE_WIDTH: f32 = 1920.0; const REFERENCE_HEIGHT: f32 = 1080.0; @@ -525,7 +524,7 @@ async fn start_audio(sink: Arc, audio: PathBuf) { fn scale_font(font_size: f32, width: f32) -> f32 { let scale_factor = (REFERENCE_WIDTH / width).sqrt(); // debug!(scale_factor); - + if font_size > 0.0 { font_size / scale_factor } else {