X-Git-Url: https://git.yukkurigames.com/?p=enjoyable.git;a=blobdiff_plain;f=NJKeyInputField.h;fp=NJKeyInputField.h;h=0000000000000000000000000000000000000000;hp=ad026d3f4f0cb163f936f44d20bf727911fb8e99;hb=0064c1fbff36795885a9724081af2a17d83c20a3;hpb=56d825ba259066d847a9fc3f9c8c0c0a362a1507 diff --git a/NJKeyInputField.h b/NJKeyInputField.h deleted file mode 100644 index ad026d3..0000000 --- a/NJKeyInputField.h +++ /dev/null @@ -1,45 +0,0 @@ -// -// NJKeyInputField.h -// Enjoyable -// -// Copyright 2013 Joe Wreschnig. -// - -#import - -extern CGKeyCode NJKeyInputFieldEmpty; - -@protocol NJKeyInputFieldDelegate; - -@interface NJKeyInputField : NSTextField - // An NJKeyInputField is a NSTextField-like widget that receives - // exactly one key press, and displays the name of that key, then - // resigns its first responder status. It can also inform a - // special delegate when its content changes. - -+ (NSString *)stringForKeyCode:(CGKeyCode)keyCode; - // Give the string name for a virtual key code. - -@property (nonatomic, weak) IBOutlet id keyDelegate; - -@property (nonatomic, assign) CGKeyCode keyCode; - // The currently displayed key code, or NJKeyInputFieldEmpty if no - // key is active. Changing this will update the display but not - // inform the delegate. - -@property (nonatomic, readonly) BOOL hasKeyCode; - // True if any key is active, false otherwise. - -- (void)clear; - // Clear the currently active key and call the delegate. - -@end - -@protocol NJKeyInputFieldDelegate - -- (void)keyInputField:(NJKeyInputField *)keyInput - didChangeKey:(CGKeyCode)keyCode; -- (void)keyInputFieldDidClear:(NJKeyInputField *)keyInput; - -@end -