mirror of
https://github.com/itsjunetime/tdf.git
synced 2026-08-25 20:54:30 -04:00
Compare commits
11 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c98eed18b8 | |||
| 69c5a2baf4 | |||
| dd98022eca | |||
| 8abebc99e5 | |||
| d6aee778e0 | |||
| 04d4efaf12 | |||
| 5c380a8713 | |||
| eaeed4730b | |||
| 032fad1f9b | |||
| 91b923f593 | |||
| d5abc4bae5 |
@@ -58,7 +58,7 @@ jobs:
|
|||||||
- name: Clippy
|
- name: Clippy
|
||||||
run: cargo clippy --locked -- -D warnings
|
run: cargo clippy --locked -- -D warnings
|
||||||
- name: Tests
|
- name: Tests
|
||||||
run: cargo test --locked
|
run: cargo test --verbose --locked
|
||||||
- name: Check fmt
|
- name: Check fmt
|
||||||
run: cargo fmt -- --check
|
run: cargo fmt -- --check
|
||||||
- name: Run benchmarks as tests
|
- name: Run benchmarks as tests
|
||||||
|
|||||||
Generated
+280
-367
File diff suppressed because it is too large
Load Diff
+1
-1
@@ -31,7 +31,7 @@ tokio = { version = "1.37.0", features = ["rt-multi-thread", "macros"] }
|
|||||||
futures-util = { version = "0.3.30", default-features = false }
|
futures-util = { version = "0.3.30", default-features = false }
|
||||||
flume = { version = "0.12.0", default-features = false, features = ["async"] }
|
flume = { version = "0.12.0", default-features = false, features = ["async"] }
|
||||||
xflags = "0.4.0-pre.2"
|
xflags = "0.4.0-pre.2"
|
||||||
mimalloc = { git = "https://github.com/itsjunetime/mimalloc_rust.git", rev = "1094dbf3afdc0a57215e925a05f2e3160e59575b", features = [ "debug_in_debug" ] }
|
mimalloc = { version = "0.1", features = [ "debug_in_debug" ] }
|
||||||
nix = { version = "0.31.0", features = ["signal"] }
|
nix = { version = "0.31.0", features = ["signal"] }
|
||||||
mupdf = { git = "https://github.com/messense/mupdf-rs.git", rev = "d7441b9998c92135e329559c0aa71d9dc92cf4de", default-features = false, features = ["svg", "system-fonts", "img"] }
|
mupdf = { git = "https://github.com/messense/mupdf-rs.git", rev = "d7441b9998c92135e329559c0aa71d9dc92cf4de", default-features = false, features = ["svg", "system-fonts", "img"] }
|
||||||
rayon = { version = "1", default-features = false }
|
rayon = { version = "1", default-features = false }
|
||||||
|
|||||||
@@ -0,0 +1,17 @@
|
|||||||
|
// Working around https://github.com/purpleprotocol/mimalloc_rust/pull/167 while all the cc, rust,
|
||||||
|
// msvc, etc stuff is still being worked on. Kinda unfortunate that we need a build.rs for all
|
||||||
|
// targets, but at least it should be quick.
|
||||||
|
|
||||||
|
fn main() {
|
||||||
|
if std::env::var("TARGET").is_ok_and(|s| s.contains("windows-msvc"))
|
||||||
|
&& std::env::var("PROFILE").is_ok_and(|p| p == "debug")
|
||||||
|
{
|
||||||
|
println!("cargo::rustc-env=CFLAGS=/MDd");
|
||||||
|
println!("cargo::rustc-env=CXXFLAGS=/MDd");
|
||||||
|
|
||||||
|
// Don't link the default CRT
|
||||||
|
// println!("cargo::rustc-link-arg=/nodefaultlib:msvcrt");
|
||||||
|
// Link the debug CRT instead
|
||||||
|
// println!("cargo::rustc-link-arg=/defaultlib:msvcrtd");
|
||||||
|
}
|
||||||
|
}
|
||||||
+8
-8
@@ -738,20 +738,20 @@ impl Tui {
|
|||||||
term.push(c);
|
term.push(c);
|
||||||
InputAction::Redraw.into()
|
InputAction::Redraw.into()
|
||||||
}
|
}
|
||||||
KeyCode::Char(c)
|
|
||||||
if let BottomMessage::Input(InputCommand::GoToPage(_)) =
|
|
||||||
self.bottom_msg && matches!(c, 'g' if self.is_kitty) =>
|
|
||||||
{
|
|
||||||
self.set_msg(MessageSetting::Pop);
|
|
||||||
self.update_zoom(Zoom::pan_bottom)
|
|
||||||
}
|
|
||||||
KeyCode::Char(c)
|
KeyCode::Char(c)
|
||||||
if let BottomMessage::Input(InputCommand::GoToPage(ref mut page)) =
|
if let BottomMessage::Input(InputCommand::GoToPage(ref mut page)) =
|
||||||
self.bottom_msg =>
|
self.bottom_msg && matches!(c, 'g' if self.is_kitty) =>
|
||||||
c.to_digit(10).map(|input_num| {
|
c.to_digit(10).map(|input_num| {
|
||||||
*page = (*page * 10) + input_num as usize;
|
*page = (*page * 10) + input_num as usize;
|
||||||
InputAction::Redraw
|
InputAction::Redraw
|
||||||
}),
|
}),
|
||||||
|
KeyCode::Char(_)
|
||||||
|
if let BottomMessage::Input(InputCommand::GoToPage(_)) =
|
||||||
|
self.bottom_msg =>
|
||||||
|
{
|
||||||
|
self.set_msg(MessageSetting::Pop);
|
||||||
|
self.update_zoom(Zoom::pan_bottom)
|
||||||
|
}
|
||||||
KeyCode::Char(c) => match c {
|
KeyCode::Char(c) => match c {
|
||||||
'l' => self.change_page(PageChange::Next, ChangeAmount::Single),
|
'l' => self.change_page(PageChange::Next, ChangeAmount::Single),
|
||||||
'j' => self.change_page(PageChange::Next, ChangeAmount::WholeScreen),
|
'j' => self.change_page(PageChange::Next, ChangeAmount::WholeScreen),
|
||||||
|
|||||||
Reference in New Issue
Block a user