xplan ios start

This commit is contained in:
zu
2021-09-06 18:47:38 +08:00
commit cbc85a02d2
103 changed files with 5818 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
//
// GCDHelper.h
// YYMobileFramework
//
// Created by wuwei on 14/7/18.
// Copyright (c) 2014年 YY Inc. All rights reserved.
//
#import <Foundation/Foundation.h>
void dispatch_main_sync_safe(dispatch_block_t block);

View File

@@ -0,0 +1,16 @@
//
// GCDHelper.m
// YYMobileFramework
//
// Created by wuwei on 14/7/18.
// Copyright (c) 2014 YY Inc. All rights reserved.
//
#import "GCDHelper.h"
void dispatch_main_sync_safe(dispatch_block_t block) {
if ([NSThread isMainThread]) {
block();
}else {
dispatch_sync(dispatch_get_main_queue(), block);
}
}