• 大小: 30.52MB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2023-06-22
  • 语言: 其他
  • 标签:

资源简介

Swift 4.1实现 视频播放器 支持旋转、锁屏、各种手势 ><

资源截图

代码片段和文件信息

//
// MBProgressHUD.m
// Version 0.9.2
// Created by Matej Bukovinski on 2.4.09.
//

#import “MBProgressHUD.h“
#import 


#if __has_feature(objc_arc)
#define MB_AUTORELEASE(exp) exp
#define MB_RELEASE(exp) exp
#define MB_RETAIN(exp) exp
#else
#define MB_AUTORELEASE(exp) [exp autorelease]
#define MB_RELEASE(exp) [exp release]
#define MB_RETAIN(exp) [exp retain]
#endif

#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 60000
    #define MBLabelAlignmentCenter NSTextAlignmentCenter
#else
    #define MBLabelAlignmentCenter UITextAlignmentCenter
#endif

#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 70000
#define MB_TEXTSIZE(text font) [text length] > 0 ? [text \
sizeWithAttributes:@{NSFontAttributeName:font}] : CGSizeZero;
#else
#define MB_TEXTSIZE(text font) [text length] > 0 ? [text sizeWithFont:font] : CGSizeZero;
#endif

#if __IPHONE_OS_VERSION_MIN_REQUIRED >= 70000
#define MB_MULTILINE_TEXTSIZE(text font maxSize mode) [text length] > 0 ? [text \
boundingRectWithSize:maxSize options:(NSStringDrawingUsesLineFragmentOrigin) \
attributes:@{NSFontAttributeName:font} context:nil].size : CGSizeZero;
#else
#define MB_MULTILINE_TEXTSIZE(text font maxSize mode) [text length] > 0 ? [text \
sizeWithFont:font constrainedToSize:maxSize lineBreakMode:mode] : CGSizeZero;
#endif

#ifndef kCFCoreFoundationVersionNumber_iOS_7_0
#define kCFCoreFoundationVersionNumber_iOS_7_0 847.20
#endif

#ifndef kCFCoreFoundationVersionNumber_iOS_8_0
#define kCFCoreFoundationVersionNumber_iOS_8_0 1129.15
#endif


static const CGFloat kPadding = 4.f;
static const CGFloat kLabelFontSize = 16.f;
static const CGFloat kDetailsLabelFontSize = 12.f;


@interface MBProgressHUD () {
BOOL useAnimation;
SEL methodForExecution;
id targetForExecution;
id objectForExecution;
UILabel *label;
UILabel *detailsLabel;
BOOL isFinished;
CGAffineTransform rotationTransform;
}

@property (atomic MB_STRONG) UIView *indicator;
@property (atomic MB_STRONG) NSTimer *graceTimer;
@property (atomic MB_STRONG) NSTimer *minShowTimer;
@property (atomic MB_STRONG) NSDate *showStarted;

@end


@implementation MBProgressHUD

#pragma mark - Properties

@synthesize animationType;
@synthesize delegate;
@synthesize opacity;
@synthesize color;
@synthesize labelFont;
@synthesize labelColor;
@synthesize detailsLabelFont;
@synthesize detailsLabelColor;
@synthesize indicator;
@synthesize xOffset;
@synthesize yOffset;
@synthesize minSize;
@synthesize square;
@synthesize margin;
@synthesize dimBackground;
@synthesize graceTime;
@synthesize minShowTime;
@synthesize graceTimer;
@synthesize minShowTimer;
@synthesize taskInProgress;
@synthesize removeFromSuperViewOnHide;
@synthesize customView;
@synthesize showStarted;
@synthesize mode;
@synthesize labelText;
@synthesize detailsLabelText;
@synthesize progress;
@synthesize size;
@synthesize activityIndicatorColor;
#if NS_BLOCKS_AVAILABLE
@synthesize completionBlock;
#endif

#pragma mark - Class methods

+ (MB_INSTANCETYPE)showHUDAddedTo:(UIView *)v

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2018-10-31 02:48  NicooPlayer-master\
     文件        1967  2018-10-31 02:48  NicooPlayer-master\.gitignore
     文件           4  2018-10-31 02:48  NicooPlayer-master\.swift-version
     文件         553  2018-10-31 02:48  NicooPlayer-master\.travis.yml
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcodeproj\
     文件       29799  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcodeproj\project.pbxproj
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcodeproj\project.xcworkspace\
     文件         156  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcodeproj\project.xcworkspace\contents.xcworkspacedata
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcodeproj\xcshareddata\
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcodeproj\xcshareddata\xcschemes\
     文件        4498  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcodeproj\xcshareddata\xcschemes\NicooPlayer-Example.xcscheme
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcworkspace\
     文件         229  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer.xcworkspace\contents.xcworkspacedata
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\
     文件        2797  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\AppDelegate.swift
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\base.lproj\
     文件        3923  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\base.lproj\LaunchScreen.xib
     文件        9444  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\base.lproj\Main.storyboard
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\AppIcon.appiconset\
     文件         928  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\AppIcon.appiconset\Contents.json
     文件        4225  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\AppIcon.appiconset\app-iPhone@2x.png
     文件        9622  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\AppIcon.appiconset\app-iPhone@3x.png
     文件          62  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\Contents.json
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\bgvideo.imageset\
     文件         304  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\bgvideo.imageset\Contents.json
     文件      157279  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\bgvideo.imageset\bgvideo.png
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\image\
     文件          62  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\image\Contents.json
     目录           0  2018-10-31 02:48  NicooPlayer-master\Example\NicooPlayer\Images.xcassets\image\collection.imageset\
............此处省略211个文件信息

评论

共有 条评论