TestsTested | ✗ |
LangLanguage | Obj-CObjective C |
License | MIT |
ReleasedLast Release | Jun 2016 |
Maintained by Herui.
HHAttachmentSheetView is inspired by this repo: Telegram Messenger for iOS.
For more details: blog.coderhr.com
UI_APPEARANCE_SELECTOR
to customize the appearance. Add HHAttachmentSheetView
folder into your project.
Open and run the HHAttachmentSheetViewDemo.xcodeproj
in Xcode to see HHAttachmentSheetView in action
NSMutableArray *items = [[NSMutableArray alloc] initWithCapacity:5];
[items addObject:[[HHAttachmentSheetButtonItemView alloc] initWithTitle:@"ChoosePhoto" pressed:^ {
NSLog(@"choose photo");
}]];
[items addObject:[[HHAttachmentSheetButtonItemView alloc] initWithTitle:@"ChooseViedo" pressed:^ {
NSLog(@"choose viedo");
}]];
[items addObject:[[HHAttachmentSheetButtonItemView alloc] initWithTitle:@"SearchPhoto" pressed:^ {
NSLog(@"search photo");
}]];
HHAttachmentSheetButtonItemView *deleteItem = [[HHAttachmentSheetButtonItemView alloc] initWithTitle:@"DeletePhoto" pressed:^{
NSLog(@"delete photo");
}];
deleteItem.destructive = YES;
[items addObject:deleteItem];
HHAttachmentSheetButtonItemView *cancelItem = [[HHAttachmentSheetButtonItemView alloc] initWithTitle:@"Cancel" pressed:^{
NSLog(@"cancel");
}];
cancelItem.bold = YES;
[items addObject:cancelItem];
HHAttachmentSheetView *sheetView = [[HHAttachmentSheetView alloc] initWithItems:items];
[sheetView showWithAnimate:YES completion:^{
NSLog(@"show complete");
}];
HHAttachmentSheetButtonItemView
reloadItems
method to update the items with animation.HHAttachmentSheet.h
file to support for Manual install.HHAttachmentSheetView
is available under the MIT license. See the LICENSE file for more info.