Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: rely on settings to draw windows capture indicator #141

Open
wants to merge 3 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions src/capturer/engine/win/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -152,11 +152,16 @@ pub fn create_capturer(options: &Options, tx: mpsc::Sender<Frame>) -> WCStream {
false => CursorCaptureSettings::WithoutCursor,
};

let show_border = match options.show_highlight {
true => DrawBorderSettings::WithBorder,
false => DrawBorderSettings::WithoutBorder,
};

let settings = match target {
Target::Display(display) => Settings::Display(WCSettings::new(
WCMonitor::from_raw_hmonitor(display.raw_handle.0),
show_cursor,
DrawBorderSettings::Default,
show_border,
color_format,
FlagStruct {
tx,
Expand All @@ -166,7 +171,7 @@ pub fn create_capturer(options: &Options, tx: mpsc::Sender<Frame>) -> WCStream {
Target::Window(window) => Settings::Window(WCSettings::new(
WCWindow::from_raw_hwnd(window.raw_handle.0),
show_cursor,
DrawBorderSettings::Default,
show_border,
color_format,
FlagStruct {
tx,
Expand Down