R7.6: Windows and Linux print (#3)
Windows prints through the system dialog at the document's paper; Linux through the desktop portal, the dialog's choices laid out by Ely. Round 3 findings fixed without a further review, as the rules say. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
1 parent
de4a38e814
commit
13546ea899
26 files changed
+2544
-114
No files matched your search
@@ -131,9 +131,6 @@ fn label(command: &Command, cx: &App) -> SharedString {
|
||||
|
||||
/// Why `id` cannot run; a document lifts the no-document block.
|
||||
pub fn blocked(id: &str, document: bool, cx: &App) -> Option<SharedString> {
|
||||
if id == PRINT.id && !ely_platform::print::BUILT {
|
||||
return Some(i18n::text(cx, "command.blocked.unbuilt", &[]));
|
||||
}
|
||||
let command = RENAMING.iter().find(|command| command.id == id)?;
|
||||
let key = command.blocked.filter(|_| !document)?;
|
||||
Some(i18n::text(cx, key, &[]))
|
||||
@@ -190,11 +187,8 @@ pub fn menus(
|
||||
}
|
||||
|
||||
pub fn bind_keys(cx: &mut App) {
|
||||
// Without a print panel, Print stays off the keyboard.
|
||||
if ely_platform::print::BUILT {
|
||||
cx.bind_keys([KeyBinding::new(PRINT.keys, Print, Some(CONTEXT))]);
|
||||
}
|
||||
cx.bind_keys([
|
||||
KeyBinding::new(PRINT.keys, Print, Some(CONTEXT)),
|
||||
KeyBinding::new(NEW.keys, New, Some(CONTEXT)),
|
||||
KeyBinding::new(OPEN.keys, Open, Some(CONTEXT)),
|
||||
KeyBinding::new(SAVE.keys, Save, Some(CONTEXT)),
|
||||
|
||||
Reference in new issue
Block a user