projects
/
enjoyable.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Change NJInputAnalog so magnitudes of subactions are always positive (e.g. -1 magnitu...
[enjoyable.git]
/
NJOutputKeyPress.m
diff --git
a/NJOutputKeyPress.m
b/NJOutputKeyPress.m
index
c2000d8
..
622cf41
100644
(file)
--- a/
NJOutputKeyPress.m
+++ b/
NJOutputKeyPress.m
@@
-12,11
+12,13
@@
@implementation NJOutputKeyPress
+ (NSString *)serializationCode {
@implementation NJOutputKeyPress
+ (NSString *)serializationCode {
- return @"key";
+ return @"key
press
";
}
- (NSDictionary *)serialize {
}
- (NSDictionary *)serialize {
- return @{ @"type": @"key press", @"key": @(_vk) };
+ return _vk != NJKeyInputFieldEmpty
+ ? @{ @"type": self.class.serializationCode, @"key": @(_vk) }
+ : nil;
}
+ (NJOutput *)outputDeserialize:(NSDictionary *)serialization
}
+ (NJOutput *)outputDeserialize:(NSDictionary *)serialization