ui: Fast Previews sits beside the resolution control, where After Effects puts it

Co-Authored-By: DeepSeek V4.1 Flash <noreply@deepseek.com>
This commit is contained in:
zitann2020andDeepSeek V4.1 Flash committed 2026-10-31 02:09:49 +09:00
1 parent ec7ced1f05
commit 276233ea07
1 file changed
+10 -10
+10 -10
View File
@@ -779,6 +779,16 @@ fn bottom_bar_contents(app: &mut EffectcraftApp, ui: &mut egui::Ui, bar: Rect, z
*x += 24.0;
(resp.clicked(), r)
};
// Fast Previews.
let fp = app.session.state.viewer.fast_previews;
let (clicked, fr) = tog(ui, &mut app.auto, &mut x, Icon::Sparkle, fp != FastPreviews::Off || app.ui.viewer.fast_preview, "fastPreviews", "Fast Previews");
if clicked {
toggle_popup(ui, "vw-fast-pop");
}
let items: Vec<(String, bool)> = FastPreviews::ALL.iter().map(|m| (m.label().to_string(), fp == *m)).collect();
if let Some(i) = popup(app, ui, "vw-fast-pop", fr, &items, "fastPreviewsItem") {
let _ = app.session.execute("view.fastPreviewMode", json!({"mode": FastPreviews::ALL[i].id()}));
}
if tog(ui, &mut app.auto, &mut x, Icon::Checker, app.ui.viewer.transparency_grid, "transparency", "Toggle Transparency Grid").0 {
app.ui.viewer.transparency_grid = !app.ui.viewer.transparency_grid;
}
@@ -861,16 +871,6 @@ fn bottom_bar_contents(app: &mut EffectcraftApp, ui: &mut egui::Ui, bar: Rect, z
if app.session.snapshot.is_some() && held != app.session.state.viewer.show_snapshot {
let _ = app.session.execute("view.showSnapshot", json!({"value": held}));
}
// Fast Previews.
let fp = vo.fast_previews;
let (clicked, fr) = tog(ui, &mut app.auto, &mut x, Icon::Sparkle, fp != FastPreviews::Off || app.ui.viewer.fast_preview, "fastPreviews", "Fast Previews");
if clicked {
toggle_popup(ui, "vw-fast-pop");
}
let items: Vec<(String, bool)> = FastPreviews::ALL.iter().map(|m| (m.label().to_string(), fp == *m)).collect();
if let Some(i) = popup(app, ui, "vw-fast-pop", fr, &items, "fastPreviewsItem") {
let _ = app.session.execute("view.fastPreviewMode", json!({"mode": FastPreviews::ALL[i].id()}));
}
x += 4.0;
// 3D renderer + view.
if comp.has_3d() {