VLCTrackSelectorHeaderView.m 1.03 KB
Newer Older
1 2 3 4
/*****************************************************************************
 * VLCTrackSelectorHeaderView.m
 * VLC for iOS
 *****************************************************************************
Felix Paul Kühne's avatar
Felix Paul Kühne committed
5
 * Copyright (c) 2014-2015 VideoLAN. All rights reserved.
6 7 8 9 10 11 12 13
 * $Id$
 *
 * Authors: Felix Paul Kühne <fkuehne # videolan.org>
 *
 * Refer to the COPYING file of the official project for license.
 *****************************************************************************/

#import "VLCTrackSelectorHeaderView.h"
Felix Paul Kühne's avatar
Felix Paul Kühne committed
14
#import "UIDevice+VLC.h"
15 16 17 18 19 20 21 22 23 24 25 26 27

@implementation VLCTrackSelectorHeaderView

- (instancetype)initWithReuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithReuseIdentifier:reuseIdentifier];

    if (!self)
        return self;

    self.contentView.backgroundColor = [UIColor VLCDarkBackgroundColor];
    self.textLabel.textColor = [UIColor whiteColor];

28
    if ([[UIDevice currentDevice] vlcSpeedCategory] >= VLCSpeedCategoryThreeDevices) {
29 30 31 32 33 34 35 36
        self.opaque = NO;
        self.alpha = .8;
    }

    return self;
}

@end