mirror of
https://github.com/storytold/texturecraft.git
synced 2026-11-30 10:03:56 +01:00
Layers: shorten the enabled-check comment
This commit is contained in:
1 parent
71d1202a24
commit
ca4ea4bccf
1 file changed
+1
-3
@@ -193,9 +193,7 @@ pub fn check_enabled(spec: &CommandSpec, s: &Session) -> std::result::Result<(),
|
||||
(spec.enabled)(s)
|
||||
}
|
||||
|
||||
/// [`check_enabled`] for a run with `params`: a command that takes `layer` is checked as if the
|
||||
/// layer it names were the selected one, so a row's own controls work with no layer selected
|
||||
/// (after an undo, say).
|
||||
/// [`check_enabled`] for a run with `params`, checking a command that takes `layer` as if the named layer were selected
|
||||
fn check_enabled_for(spec: &CommandSpec, s: &mut Session, params: &Value) -> std::result::Result<(), String> {
|
||||
let refused = match check_enabled(spec, s) {
|
||||
Ok(()) => return Ok(()),
|
||||
|
||||
Reference in new issue
Block a user