mirror of
https://github.com/danog/Telegram.git
synced 2024-12-11 17:09:46 +01:00
22 lines
582 B
Mathematica
22 lines
582 B
Mathematica
|
#import "TGSharedMediaAvailabilityState.h"
|
||
|
|
||
|
@implementation TGSharedMediaAvailabilityState
|
||
|
|
||
|
- (instancetype)initWithType:(TGSharedMediaAvailabilityStateType)type progress:(CGFloat)progress
|
||
|
{
|
||
|
self = [super init];
|
||
|
if (self != nil)
|
||
|
{
|
||
|
_type = type;
|
||
|
_progress = progress;
|
||
|
}
|
||
|
return self;
|
||
|
}
|
||
|
|
||
|
- (BOOL)isEqual:(id)object
|
||
|
{
|
||
|
return [object isKindOfClass:[TGSharedMediaAvailabilityState class]] && _type == ((TGSharedMediaAvailabilityState *)object)->_type && ABS(_progress - ((TGSharedMediaAvailabilityState *)object)->_progress) < FLT_EPSILON;
|
||
|
}
|
||
|
|
||
|
@end
|