Merge pull request #1109 from eliasx45/upstream/azerty-graph-zoom

# Conflicts:
#	crates/engine/src/commands/time.rs
#	crates/ui-egui/src/panels/timeline.rs
This commit is contained in:
Brandon Thomas
2026-10-13 04:29:47 -04:00
11 changed files with 530 additions and 37 deletions
+3 -1
View File
@@ -151,6 +151,7 @@ pub fn normalize(s: &str) -> Option<String> {
}
let (mut ctrl, mut cmd, mut alt, mut shift) = (false, false, false, false);
let mut key: Option<String> = None;
let mut physical = false;
// `Cmd++` / `+` name the plus key.
let (head, plus) = match s.strip_suffix("++") {
Some(h) => (h, true),
@@ -177,6 +178,7 @@ pub fn normalize(s: &str) -> Option<String> {
}
for p in parts {
match p.to_ascii_lowercase().as_str() {
"physical" => physical = true,
"cmd" | "command" | "meta" | "super" | "win" => cmd = true,
"ctrl" | "control" => ctrl = true,
"alt" | "opt" | "option" => alt = true,
@@ -188,7 +190,7 @@ pub fn normalize(s: &str) -> Option<String> {
key = Some("+".into());
}
let key = key?;
let mut out = String::new();
let mut out = if physical { "Physical+".to_string() } else { String::new() };
for (on, m) in [(ctrl, "Ctrl+"), (cmd, "Cmd+"), (alt, "Alt+"), (shift, "Shift+")] {
if on {
out.push_str(m);
+10
View File
@@ -436,3 +436,13 @@ fn numeric_string_resolves_as_id() {
let r = s.execute("layer.tree", json!({"layer": l.to_string(), "comp": cid.0.to_string()})).unwrap();
assert_eq!(r["id"].as_u64(), Some(l), "{r}");
}
/// Go to Work Area Start / End have After Effects' default keys (Shift+Home / Shift+End).
#[test]
fn work_area_navigation_has_after_effects_default_keys() {
let s = Session::default();
for (id, key) in [("time.workAreaStart", "Shift+Home"), ("time.workAreaEnd", "Shift+End")] {
let b = s.shortcuts().find(id).unwrap_or_else(|| panic!("{id} is bindable"));
assert_eq!(b.defaults, [key.to_string()], "{id}");
}
}