can now remove icon labels

This commit is contained in:
lillian rose winter 2019-11-25 13:33:56 -06:00
rodič 378f7dcd0d
revize 2b00a4f6a2
3 změnil soubory, kde provedl 69 přidání a 0 odebrání

Zobrazit soubor

@ -2,6 +2,7 @@
#import <os/log.h>
#import <substrate.h>
// dock bg
@interface _UIBackdropView : UIView {}
@end
@ -9,8 +10,14 @@
@property (nonatomic, retain) _UIBackdropView * backgroundView;
@end
// corner radius
@interface _UIRootWindow : UIView
@property (setter=_setContinuousCornerRadius:, nonatomic) double _continuousCornerRadius;
- (double)_continuousCornerRadius;
- (void)_setContinuousCornerRadius:(double)arg1;
@end
// icon labels
@interface SBIconView : UIView
@property (assign,nonatomic) double iconLabelAlpha;
@end

50
Tweak.x
Zobrazit soubor

@ -82,3 +82,53 @@
return;
}
%end
//ICON LABELS
%hook SBIconView
- (void)_applyIconLabelAlpha:(double)arg1 {
NSObject *object = [[NSObject alloc] init];
BOOL isSettingOn = [object isSettingOn:@"iconlabels"];
if(isSettingOn) {
arg1 = 0;
}
else {
arg1 = 1;
}
%orig(arg1);
}
- (void)layoutSubviews {
%orig;
NSObject *object = [[NSObject alloc] init];
BOOL isSettingOn = [object isSettingOn:@"iconlabels"];
if (isSettingOn) {
self.iconLabelAlpha = 0;
}
else {
self.iconLabelAlpha = 1;
}
}
%end
%hook SBIconZoomAnimator
- (void)_applyLabelAlphaFraction:(double)arg1 {
NSObject *object = [[NSObject alloc] init];
BOOL isSettingOn = [object isSettingOn:@"iconlabels"];
if(isSettingOn) {
arg1 = 0;
}
else {
arg1 = 1;
}
%orig(arg1);
}
%end

Zobrazit soubor

@ -54,6 +54,18 @@
<key>label</key>
<string>remove dock background</string>
</dict>
<dict>
<key>cell</key>
<string>PSSwitchCell</string>
<key>default</key>
<true/>
<key>defaults</key>
<string>toys.lily.hanahakiprefs</string>
<key>key</key>
<string>iconlabels</string>
<key>label</key>
<string>remove app labels</string>
</dict>
</array>
<key>title</key>
<string>hanahaki</string>