This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// | |
// Img2textVC.swift | |
// AudioText | |
// | |
// Created by dfpo on 2024/3/8. | |
// 图片转文字 | |
import UIKit | |
import TOCropViewController |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
set appName to "Terminal" | |
set appID to bundle identifier of (info for (path to application appName)) | |
set theFolder to choose folder | |
tell application "Finder" | |
set fileList to every file of theFolder --whose name extension is "ipa" | |
if (count of fileList) > 0 then | |
repeat with theFile in fileList |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "System Events" | |
tell application "企业微信" | |
activate | |
tell application "System Events" | |
tell process "企业微信" | |
get entire contents of window 1 | |
end tell | |
end tell | |
end tell | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "System Events" | |
tell application "企业微信" | |
activate | |
end tell | |
if not (exists (button "登录" of window 1 of application process "企业微信" of application "System Events")) then | |
tell application "企业微信" | |
quit | |
end tell |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
tell application "System Events" | |
get name of every process whose name is "企业微信" | |
if result is not {} then | |
tell application "企业微信" | |
quit | |
end tell | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@interface AdViewController () | |
/** 定时器 */ | |
@property (nonatomic, strong) NSTimer *timer; | |
@property (nonatomic, strong) UIButton *adButton; | |
@end | |
@implementation AdViewController | |
NSUInteger secondsCountDown = 3;//倒计时秒数 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[BaseService postJSONWithUrl:APP_URL parameters:nil success:^(id responseObject) | |
{ | |
NSDictionary *dic = [NSJSONSerialization JSONObjectWithData:responseObject options:NSJSONReadingMutableContainers error:nil removingNulls:YES ignoreArrays:NO]; | |
NSArray *infoArray = [dic objectForKey:@"results"]; | |
if ([infoArray count]) | |
{ | |
NSDictionary *releaseInfo = [infoArray objectAtIndex:0]; | |
NSDictionary *infoDic = [[NSBundle mainBundle] infoDictionary]; | |
NSString *currentVersion = [[infoDic objectForKey:@"CFBundleShortVersionString"] stringByReplacingOccurrencesOfString:@"." withString:@""]; | |
NSString *lastVersion = [[releaseInfo objectForKey:@"version"] stringByReplacingOccurrencesOfString:@"." withString:@""]; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import "RSAEncryptor.h" | |
#import <Security/Security.h> | |
@implementation RSAEncryptor | |
static NSString *base64_encode_data(NSData *data){ | |
data = [data base64EncodedDataWithOptions:0]; | |
NSString *ret = [[NSString alloc] initWithData:data encoding:NSUTF8StringEncoding]; | |
return ret; | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#import <Foundation/Foundation.h> | |
@interface RSAEncryptor : NSObject | |
/** | |
* 加密方法 | |
* | |
* @param str 需要加密的字符串 | |
* @param path '.der'格式的公钥文件路径 | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
NSMutableAttributedString * attributedString1 = [[NSMutableAttributedString alloc] initWithString:self.illLabel.text]; | |
NSMutableParagraphStyle * paragraphStyle1 = [[NSMutableParagraphStyle alloc] init]; | |
[paragraphStyle1 setLineSpacing:50.0]; | |
[attributedString1 addAttribute:NSParagraphStyleAttributeName value:paragraphStyle1 range:NSMakeRange(0, [self.illLabel.text length])]; | |
[self.illLabel setAttributedText:attributedString1]; |
NewerOlder