mop-flutter-sdk/ios/Classes/Utils/MOPTools.h

40 lines
1.0 KiB
Dart
Raw Permalink Normal View History

2020-02-27 17:21:45 +08:00
//
// MOPTools.h
// mop
//
// Created by 杨涛 on 2020/2/27.
//
#import <Foundation/Foundation.h>
NS_ASSUME_NONNULL_BEGIN
@interface MOPTools : NSObject
+ (UIViewController *)topViewController;
+ (UIViewController *)topViewController:(UIViewController *)rootViewController;
2021-12-22 17:32:18 +08:00
+ (UIColor *)colorWithRGBHex:(UInt32)hex;
+ (UIColor *)fat_colorWithHexString:(NSString *)hexColor;
2022-11-25 10:14:14 +08:00
+ (BOOL)fat_currentLanguageIsEn;
2023-01-03 22:13:59 +08:00
/// 设置颜色( + 暗黑模式)UIDynamicProviderColor会随着暗黑模式/明亮模式切换自动变化颜色)
/// @param lightHexString (明亮模式 的颜色值)
/// @param darkHexString (暗黑模式 的颜色值)
+ (UIColor *)fat_dynamicColorWithLightHexString:(NSString *)lightHexString darkHexString:(NSString *)darkHexString;
/// 生成image对象
/// @param view 指定的view
+ (UIImage *)snapshotWithView:(UIView *)view;
/// 根据链接生成二维码图片
/// @param string 二维码的内容
+ (UIImage *)makeQRCodeForString:(NSString *)string;
2023-01-05 20:37:02 +08:00
+ (UIImage *)getCurrentPageImage;
2023-01-05 18:47:26 +08:00
2020-02-27 17:21:45 +08:00
@end
NS_ASSUME_NONNULL_END