pub enum AssetRefusal {
Parse(String),
BadBinding {
action: String,
error: BindingParseError,
},
WrongList {
action: String,
binding: String,
list: Device,
},
DuplicatePattern {
action: String,
pattern: Pattern,
},
BadTime {
action: String,
pattern: Pattern,
},
UnknownEmit {
action: String,
pattern: Pattern,
emits: String,
},
EmitNotAButton {
action: String,
pattern: Pattern,
emits: String,
},
EmitsItself {
action: String,
pattern: Pattern,
},
Declare(ActionMapError),
}Expand description
What was wrong with a binding asset.
Variants§
Parse(String)
Not RON, or RON that is not the schema — an unknown field, an unknown
kind, a missing action — in ron’s own words, which name it.
BadBinding
A binding’s text is not a Binding.
Fields
error: BindingParseErrorWhy the text did not parse, with the text.
WrongList
A binding written in a device list that is not its device’s — a key
under gamepad.
Fields
list: DeviceThe list it was written in; Binding::device names the right one.
DuplicatePattern
Two taps, two holds or two double taps on one action.
BadTime
A pattern time of zero milliseconds, which would fire on every press.
UnknownEmit
A pattern that emits an action the file does not declare.
Fields
EmitNotAButton
A pattern that emits an action that is not a Button.
Fields
EmitsItself
A pattern that emits the action it is on.
Declare(ActionMapError)
The map refused the record: ActionMapError::DuplicateName for a
name declared twice, ActionMapError::InvalidDeadzone for a pad dead
zone or threshold outside 0.0..1.0.