Skip to content

Commit

Permalink
Merge pull request #8 from MoAlyousef/main
Browse files Browse the repository at this point in the history
0.1.9
  • Loading branch information
MoAlyousef committed May 14, 2022
2 parents 9c7cf62 + f5e9f1b commit cf3ba06
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "sysinfo-gui"
version = "0.1.8"
version = "0.1.9"
edition = "2021"
repository = "https://github.com/MoAlyousef/sysinfo-gui"
keywords = ["cross-platform", "monitoring", "gui"]
Expand All @@ -15,7 +15,7 @@ sysinfo = { version = "0.23.10", default-features = false }
fltk = "1.3"
fltk-grid = "0.1"
parking_lot = "0.12"
dark-light = "0.2.2"
dark-light = { version = "0.2.2", optional = true }

[profile.release]
opt-level = 3
Expand Down
4 changes: 4 additions & 0 deletions src/view/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,11 @@ pub struct MyView {

impl Default for MyView {
fn default() -> Self {
#[cfg(feature = "dark-light")]
let mode = dark_light::detect() == dark_light::Mode::Light;
#[cfg(not(feature = "dark-light"))]
let mode = false;

if mode {
app::foreground(50, 50, 50);
app::background(255, 255, 255);
Expand Down

0 comments on commit cf3ba06

Please sign in to comment.