Browse Source

changed default preferences

pull/3/head
Burrit0z 4 years ago
parent
commit
be1399f3d2
3 changed files with 7 additions and 9 deletions
  1. +5
    -7
      KAIBatteryCell.mm
  2. +1
    -1
      Kai.h
  3. +1
    -1
      kaiprefs/Resources/Root.plist

+ 5
- 7
KAIBatteryCell.mm View File

UIView *blur; UIView *blur;
UIView *blurPlatter = [[UIView alloc] init]; UIView *blurPlatter = [[UIView alloc] init];
if (bannerStyle == 1) { if (bannerStyle == 1) {
if (kCFCoreFoundationVersionNumber > 1600) {
@try {
if (kCFCoreFoundationVersionNumber > 1600 && kCFCoreFoundationVersionNumber < 1740) {
blur = [[[objc_getClass("MTMaterialView") class] alloc] _initWithRecipe:1 configuration:1 initialWeighting:1 scaleAdjustment:nil]; blur = [[[objc_getClass("MTMaterialView") class] alloc] _initWithRecipe:1 configuration:1 initialWeighting:1 scaleAdjustment:nil];
} @catch (NSException *exc) {
blur = [[UIVisualEffectView alloc] initWithEffect:[UIBlurEffect effectWithStyle:UIBlurEffectStyleRegular]];
}
} else if (kCFCoreFoundationVersionNumber < 1600) {
} else if (kCFCoreFoundationVersionNumber < 1600) { //ios 12
blur = [[UIVisualEffectView alloc] initWithEffect:[UIBlurEffect effectWithStyle:UIBlurEffectStyleLight]]; blur = [[UIVisualEffectView alloc] initWithEffect:[UIBlurEffect effectWithStyle:UIBlurEffectStyleLight]];
}
} else if(kCFCoreFoundationVersionNumber >= 1740) { //ios 14 :fr:
blur = [[UIVisualEffectView alloc] initWithEffect:[UIBlurEffect effectWithStyle:UIBlurEffectStyleRegular]];
}
} else if (bannerStyle == 2) { } else if (bannerStyle == 2) {
blur = [[UIVisualEffectView alloc] initWithEffect:[UIBlurEffect effectWithStyle:UIBlurEffectStyleDark]]; blur = [[UIVisualEffectView alloc] initWithEffect:[UIBlurEffect effectWithStyle:UIBlurEffectStyleDark]];
} else if (bannerStyle == 3) { } else if (bannerStyle == 3) {

+ 1
- 1
Kai.h View File

disableGlyphs = boolValueForKey(@"disableGlyphs", NO); disableGlyphs = boolValueForKey(@"disableGlyphs", NO);
hidePercent = boolValueForKey(@"hidePercent", NO); hidePercent = boolValueForKey(@"hidePercent", NO);
bannerStyle = numberForValue(@"bannerStyle", 1); bannerStyle = numberForValue(@"bannerStyle", 1);
showAll = boolValueForKey(@"showAll", NO);
showAll = boolValueForKey(@"showAll", YES);
bannerWidthFactor = numberForValue(@"bannerWidthFactor", 0); bannerWidthFactor = numberForValue(@"bannerWidthFactor", 0);
hideDeviceLabel = boolValueForKey(@"hideDeviceLabel", NO); hideDeviceLabel = boolValueForKey(@"hideDeviceLabel", NO);
bannerAlign = numberForValue(@"bannerAlign", 2); bannerAlign = numberForValue(@"bannerAlign", 2);

+ 1
- 1
kaiprefs/Resources/Root.plist View File

<key>cell</key> <key>cell</key>
<string>PSSwitchCell</string> <string>PSSwitchCell</string>
<key>default</key> <key>default</key>
<false/>
<true/>
<key>defaults</key> <key>defaults</key>
<string>com.burritoz.kaiprefs</string> <string>com.burritoz.kaiprefs</string>
<key>key</key> <key>key</key>

Loading…
Cancel
Save