mirror of
https://github.com/danog/Telegram.git
synced 2024-12-02 09:27:55 +01:00
42 lines
855 B
Objective-C
42 lines
855 B
Objective-C
#import "TGWebSearchInternalGifItem.h"
|
|
|
|
#import "TGWebSearchInternalGifItemView.h"
|
|
|
|
#import "TGWebSearchInternalGifResult+TGMediaItem.h"
|
|
|
|
@implementation TGWebSearchInternalGifItem
|
|
|
|
@synthesize selectionContext;
|
|
|
|
- (instancetype)initWithSearchResult:(TGWebSearchInternalGifResult *)searchResult
|
|
{
|
|
self = [super init];
|
|
if (self != nil)
|
|
{
|
|
_webSearchResult = searchResult;
|
|
}
|
|
return self;
|
|
}
|
|
|
|
- (instancetype)copyWithZone:(NSZone *)__unused zone
|
|
{
|
|
return self;
|
|
}
|
|
|
|
- (id<TGMediaSelectableItem>)selectableMediaItem
|
|
{
|
|
return self.webSearchResult;
|
|
}
|
|
|
|
- (Class)viewClass
|
|
{
|
|
return [TGWebSearchInternalGifItemView class];
|
|
}
|
|
|
|
- (BOOL)isEqual:(id)object
|
|
{
|
|
return [object isKindOfClass:[TGWebSearchInternalGifItem class]] && TGObjectCompare(_webSearchResult, ((TGWebSearchInternalGifItem *)object)->_webSearchResult);
|
|
}
|
|
|
|
@end
|