This commit is contained in:
2025-12-11 20:40:49 +08:00
parent 577b749198
commit 35597f89ca
7 changed files with 198 additions and 26 deletions

View File

@@ -126,8 +126,7 @@
- (void)configWithTitle:(NSString *)title imageURL:(NSString *)imageURL {
self.titleLabel.text = title.length ? title : @"Dopamine";
self.coverView.backgroundColor = [UIColor colorWithWhite:0.92 alpha:1.0];
UIImage *placeholder = [UIImage imageNamed:@"my_skin_placeholder"];
[self.coverView kb_setImageURL:imageURL placeholder:placeholder];
[self.coverView kb_setImageURL:imageURL placeholder:nil];
}
- (void)setEditing:(BOOL)editing {

View File

@@ -12,6 +12,7 @@
#import "KBAPI.h"
//#import <MJExtension/MJExtension.h>
#import "KBMyMainModel.h"
#import "KBSkinService.h"
#import "KBSkinInstallBridge.h"
NSString * const KBUserCharacterDeletedNotification = @"KBUserCharacterDeletedNotification";
@@ -117,22 +118,12 @@ NSString * const KBUserCharacterDeletedNotification = @"KBUserCharacterDeletedNo
return;
}
dispatch_async(dispatch_get_global_queue(QOS_CLASS_USER_INITIATED, 0), ^{
NSError *lastError = nil;
for (NSString *skinId in themeIds) {
if (skinId.length == 0) { continue; }
BOOL ok = [KBSkinInstallBridge removeInstalledSkinWithId:skinId error:&lastError];
if (!ok) {
break;
}
[[KBSkinService shared] deleteSkinsWithIds:themeIds
completion:^(BOOL success, NSError * _Nullable error) {
if (completion) {
completion(success, error);
}
BOOL success = (lastError == nil);
dispatch_async(dispatch_get_main_queue(), ^{
if (completion) {
completion(success, lastError);
}
});
});
}];
}
///