Skip to content

Commit 29ae44e

Browse files
committed
Merge branch 'master' of https://github.com/ChisomUma/rustcast
2 parents c98d92f + 3847af4 commit 29ae44e

10 files changed

Lines changed: 482 additions & 51 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,13 @@
11
[package]
22
name = "rustcast"
3-
version = "0.6.7"
3+
version = "0.7.2"
44
edition = "2024"
55
license = "MIT"
66
description = "RustCast - Productivity app for macOS"
77
homepage = "https://rustcast.app"
88
repository = "https://github.com/RustCastLabs/rustcast"
99

1010
[dependencies]
11-
anyhow = "1.0.100"
1211
arboard = "3.6.1"
1312
block2 = "0.6.2"
1413
emojis = "0.8.0"

src/app.rs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ use std::collections::HashMap;
33

44
use crate::app::apps::{App, AppCommand, ICNS_ICON};
55
use crate::commands::Function;
6-
use crate::config::Config;
6+
use crate::config::{Config, MainPage, Shelly};
77
use crate::debounce::DebouncePolicy;
88
use crate::utils::icns_data_to_handle;
99
use crate::{app::tile::ExtSender, clipboard::ClipBoardContentType};
@@ -82,6 +82,7 @@ pub enum Message {
8282
WriteConfig(bool),
8383
SaveRanking,
8484
LoadRanking,
85+
ToggleFavouriteApp(String),
8586
UpdateAvailable,
8687
ResizeWindow(Id, f32),
8788
OpenWindow,
@@ -125,10 +126,11 @@ pub enum SetConfigFields {
125126
SearchUrl(String),
126127
HapticFeedback(bool),
127128
ShowMenubarIcon(bool),
128-
AutoSuggest(bool),
129+
SetPage(MainPage),
129130
Modes(Editable<(String, String)>),
130131
Aliases(Editable<(String, String)>),
131-
SearchDirs(Editable<Vec<String>>),
132+
SearchDirs(Editable<String>),
133+
ShellCommands(Editable<Shelly>),
132134
DebounceDelay(u64),
133135
SetThemeFields(SetConfigThemeFields),
134136
SetBufferFields(SetConfigBufferFields),

src/app/apps.rs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -211,6 +211,14 @@ impl App {
211211
}
212212
row = row.push(container(text_block).width(Fill));
213213

214+
let name = self.search_name.clone();
215+
let theme_clone = theme.clone();
216+
row = row.push(
217+
Button::new("♥️")
218+
.on_press_with(move || Message::ToggleFavouriteApp(name.clone()))
219+
.style(move |_, _| result_button_style(&theme_clone)),
220+
);
221+
214222
let msg = on_press.or(match self.open_command.clone() {
215223
AppCommand::Function(func) => Some(Message::RunFunction(func)),
216224
AppCommand::Message(msg) => Some(msg),

0 commit comments

Comments
 (0)