aboutsummaryrefslogtreecommitdiff
path: root/helix-term/src/commands
diff options
context:
space:
mode:
authorSkyler Hawthorne2022-06-24 12:39:07 +0000
committerSkyler Hawthorne2022-10-19 02:31:38 +0000
commitb8a07f7d15a10186fa2b481a3423c23f32d7d561 (patch)
treed64eee91a5f88c7e835b4ac9aafb3e1de1e0bdc6 /helix-term/src/commands
parent69c9e44ef205a81c112dfb14d5f2e67e5ce9c300 (diff)
add conditional noop render back
It makes it much slower without stubbing this out
Diffstat (limited to 'helix-term/src/commands')
-rw-r--r--helix-term/src/commands/typed.rs17
1 files changed, 3 insertions, 14 deletions
diff --git a/helix-term/src/commands/typed.rs b/helix-term/src/commands/typed.rs
index bc254146..14b23f2a 100644
--- a/helix-term/src/commands/typed.rs
+++ b/helix-term/src/commands/typed.rs
@@ -273,12 +273,7 @@ fn write_impl(
let fmt = if auto_format {
doc.auto_format().map(|fmt| {
let shared = fmt.shared();
- let callback = make_format_callback(
- doc.id(),
- doc.version(),
- Modified::SetUnmodified,
- shared.clone(),
- );
+ let callback = make_format_callback(doc.id(), doc.version(), shared.clone());
jobs.callback(callback);
shared
})
@@ -346,8 +341,7 @@ fn format(
let doc = doc!(cx.editor);
if let Some(format) = doc.format() {
- let callback =
- make_format_callback(doc.id(), doc.version(), Modified::LeaveModified, format);
+ let callback = make_format_callback(doc.id(), doc.version(), format);
cx.jobs.callback(callback);
}
@@ -593,12 +587,7 @@ fn write_all_impl(
let fmt = if auto_format {
doc.auto_format().map(|fmt| {
let shared = fmt.shared();
- let callback = make_format_callback(
- doc.id(),
- doc.version(),
- Modified::SetUnmodified,
- shared.clone(),
- );
+ let callback = make_format_callback(doc.id(), doc.version(), shared.clone());
jobs.callback(callback);
shared
})