/Classes/ImageButton.h
C Header | 32 lines | 7 code | 5 blank | 20 comment | 0 complexity | c548dd9a848f9150b01a3f557e505f43 MD5 | raw file
Possible License(s): Apache-2.0
1// 2// ImageButton.h 3// 4// Created by Karl Stenerud on 10-05-29. 5// 6 7#import "Button.h" 8 9/** 10 * A button with a convenience method to use a sprite as the touchable portion. 11 */ 12@interface ImageButton : Button 13{ 14} 15 16/** Create a new image button. 17 * @param filename the filename of the image to use as a touchable portion. 18 * @param target the target to notify when the button is pressed. 19 * @param selector the selector to call when the button is pressed. 20 * @return a new button. 21 */ 22+ (id) buttonWithImageFile:(NSString*) filename target:(id) target selector:(SEL) selector; 23 24/** Initialize an image button. 25 * @param filename the filename of the image to use as a touchable portion. 26 * @param target the target to notify when the button is pressed. 27 * @param selector the selector to call when the button is pressed. 28 * @return the initialized button. 29 */ 30- (id) initWithImageFile:(NSString*) filename target:(id) target selector:(SEL) selector; 31 32@end