1
0
mirror of https://github.com/danog/Telegram.git synced 2024-12-04 10:27:46 +01:00
Telegram/Watch/Extension/TGInterfaceMenu.h

26 lines
1005 B
C
Raw Normal View History

2015-10-01 18:19:52 +02:00
#import <WatchKit/WatchKit.h>
@class TGInterfaceMenuItem;
@class TGInterfaceController;
typedef void (^TGInterfaceMenuItemActionBlock)(TGInterfaceController *controller, TGInterfaceMenuItem *sender);
@interface TGInterfaceMenuItem : NSObject
- (instancetype)initWithImage:(UIImage *)image title:(NSString *)title actionBlock:(TGInterfaceMenuItemActionBlock)actionBlock;
- (instancetype)initWithImageNamed:(NSString *)imageName title:(NSString *)title actionBlock:(TGInterfaceMenuItemActionBlock)actionBlock;
- (instancetype)initWithItemIcon:(WKMenuItemIcon)itemIcon title:(NSString *)title actionBlock:(TGInterfaceMenuItemActionBlock)actionBlock;
@end
@interface TGInterfaceMenu : NSObject
- (instancetype)initForInterfaceController:(TGInterfaceController *)interfaceController;
- (instancetype)initForInterfaceController:(TGInterfaceController *)interfaceController items:(NSArray *)items;
- (void)addItem:(TGInterfaceMenuItem *)item;
- (void)addItems:(NSArray *)items;
- (void)clearItems;
@end