@@ -6,5 +6,5 @@ Description: A very noice tweak to configure the dock a bit more... | |||
Maintainer: burrit0z | |||
Author: burrit0z | |||
Section: Tweaks | |||
Version: 1.1 | |||
Version: 1.2 | |||
Installed-Size: 348 |
@@ -1 +1 @@ | |||
./packages/com.burritoz.testing_1.1_iphoneos-arm.deb | |||
./packages/com.burritoz.testing_1.2_iphoneos-arm.deb |
@@ -6,6 +6,8 @@ | |||
/Users/carsonzielinski/Documents/theos/include/HBLog.h \ | |||
/Users/carsonzielinski/Documents/theos/include/CoreFoundation/CFLogUtilities.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h \ | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h | |||
@@ -21,6 +23,10 @@ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h: | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h: |
@@ -0,0 +1,90 @@ | |||
#line 1 "Tweak.x" | |||
#import <SpringBoard/SpringBoard.h> | |||
#import <SpringBoard/SBDockIconListView.h> | |||
#import <Cephei/HBPreferences.h> | |||
#include <UIKit/UIKit.h> | |||
static BOOL transparent; | |||
static BOOL hidden; | |||
static double setHeight; | |||
static double customOpacity; | |||
static NSInteger setIconNumber; | |||
HBPreferences *preferences; | |||
#include <substrate.h> | |||
#if defined(__clang__) | |||
#if __has_feature(objc_arc) | |||
#define _LOGOS_SELF_TYPE_NORMAL __unsafe_unretained | |||
#define _LOGOS_SELF_TYPE_INIT __attribute__((ns_consumed)) | |||
#define _LOGOS_SELF_CONST const | |||
#define _LOGOS_RETURN_RETAINED __attribute__((ns_returns_retained)) | |||
#else | |||
#define _LOGOS_SELF_TYPE_NORMAL | |||
#define _LOGOS_SELF_TYPE_INIT | |||
#define _LOGOS_SELF_CONST | |||
#define _LOGOS_RETURN_RETAINED | |||
#endif | |||
#else | |||
#define _LOGOS_SELF_TYPE_NORMAL | |||
#define _LOGOS_SELF_TYPE_INIT | |||
#define _LOGOS_SELF_CONST | |||
#define _LOGOS_RETURN_RETAINED | |||
#endif | |||
@class SBDockIconListView; @class SBDockView; | |||
static void (*_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static double (*_logos_orig$_ungrouped$SBDockView$dockHeight)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static NSInteger (*_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons)(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); | |||
#line 17 "Tweak.x" | |||
static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST __unused self, SEL __unused _cmd, double arg1) { | |||
if (transparent == NO && hidden == NO) { | |||
_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$(self, _cmd, customOpacity); | |||
}else if (transparent || hidden) { | |||
_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$(self, _cmd, 0.0); | |||
} else { | |||
NSLog(@"Dock not Transparent/hidden, no custom opacity\n"); | |||
} | |||
} | |||
static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
return (_logos_orig$_ungrouped$SBDockView$dockHeight(self, _cmd)*setHeight); | |||
} | |||
static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
if (hidden) { | |||
return (0); | |||
} else { | |||
return (setIconNumber); | |||
} | |||
} | |||
static __attribute__((constructor)) void _logosLocalCtor_44056092(int __unused argc, char __unused **argv, char __unused **envp) { | |||
preferences = [[HBPreferences alloc] initWithIdentifier:@"com.burritoz.dockifyprefs"]; | |||
[preferences registerDefaults:@{ | |||
@"setHeight": @1, | |||
@"customOpacity": @1, | |||
@"hidden": @NO, | |||
@"setIconNumber": @4, | |||
}]; | |||
[preferences registerBool:&transparent default:YES forKey:@"transparent"]; | |||
[preferences registerBool:&hidden default:NO forKey:@"hidden"]; | |||
[preferences registerDouble:(double *)&setHeight default:1 forKey:@"setHeight"]; | |||
[preferences registerDouble:(double *)&customOpacity default:1 forKey:@"customOpacity"]; | |||
[preferences registerInteger:(NSInteger *)&setIconNumber default:4 forKey:@"setIconNumber"]; | |||
} | |||
static __attribute__((constructor)) void _logosLocalInit() { | |||
{Class _logos_class$_ungrouped$SBDockView = objc_getClass("SBDockView"); MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(setBackgroundAlpha:), (IMP)&_logos_method$_ungrouped$SBDockView$setBackgroundAlpha$, (IMP*)&_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$);MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(dockHeight), (IMP)&_logos_method$_ungrouped$SBDockView$dockHeight, (IMP*)&_logos_orig$_ungrouped$SBDockView$dockHeight);Class _logos_class$_ungrouped$SBDockIconListView = objc_getClass("SBDockIconListView"); Class _logos_metaclass$_ungrouped$SBDockIconListView = object_getClass(_logos_class$_ungrouped$SBDockIconListView); MSHookMessageEx(_logos_metaclass$_ungrouped$SBDockIconListView, @selector(maxIcons), (IMP)&_logos_meta_method$_ungrouped$SBDockIconListView$maxIcons, (IMP*)&_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons);} } | |||
#line 62 "Tweak.x" |
@@ -6,6 +6,8 @@ | |||
/Users/carsonzielinski/Documents/theos/include/HBLog.h \ | |||
/Users/carsonzielinski/Documents/theos/include/CoreFoundation/CFLogUtilities.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h \ | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h | |||
@@ -21,6 +23,10 @@ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h: | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h: |
@@ -0,0 +1,90 @@ | |||
#line 1 "Tweak.x" | |||
#import <SpringBoard/SpringBoard.h> | |||
#import <SpringBoard/SBDockIconListView.h> | |||
#import <Cephei/HBPreferences.h> | |||
#include <UIKit/UIKit.h> | |||
static BOOL transparent; | |||
static BOOL hidden; | |||
static double setHeight; | |||
static double customOpacity; | |||
static NSInteger setIconNumber; | |||
HBPreferences *preferences; | |||
#include <substrate.h> | |||
#if defined(__clang__) | |||
#if __has_feature(objc_arc) | |||
#define _LOGOS_SELF_TYPE_NORMAL __unsafe_unretained | |||
#define _LOGOS_SELF_TYPE_INIT __attribute__((ns_consumed)) | |||
#define _LOGOS_SELF_CONST const | |||
#define _LOGOS_RETURN_RETAINED __attribute__((ns_returns_retained)) | |||
#else | |||
#define _LOGOS_SELF_TYPE_NORMAL | |||
#define _LOGOS_SELF_TYPE_INIT | |||
#define _LOGOS_SELF_CONST | |||
#define _LOGOS_RETURN_RETAINED | |||
#endif | |||
#else | |||
#define _LOGOS_SELF_TYPE_NORMAL | |||
#define _LOGOS_SELF_TYPE_INIT | |||
#define _LOGOS_SELF_CONST | |||
#define _LOGOS_RETURN_RETAINED | |||
#endif | |||
@class SBDockView; @class SBDockIconListView; | |||
static void (*_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static double (*_logos_orig$_ungrouped$SBDockView$dockHeight)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static NSInteger (*_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons)(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); | |||
#line 17 "Tweak.x" | |||
static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST __unused self, SEL __unused _cmd, double arg1) { | |||
if (transparent == NO && hidden == NO) { | |||
_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$(self, _cmd, customOpacity); | |||
}else if (transparent || hidden) { | |||
_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$(self, _cmd, 0.0); | |||
} else { | |||
NSLog(@"Dock not Transparent/hidden, no custom opacity\n"); | |||
} | |||
} | |||
static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
return (_logos_orig$_ungrouped$SBDockView$dockHeight(self, _cmd)*setHeight); | |||
} | |||
static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
if (hidden) { | |||
return (0); | |||
} else { | |||
return (setIconNumber); | |||
} | |||
} | |||
static __attribute__((constructor)) void _logosLocalCtor_44056092(int __unused argc, char __unused **argv, char __unused **envp) { | |||
preferences = [[HBPreferences alloc] initWithIdentifier:@"com.burritoz.dockifyprefs"]; | |||
[preferences registerDefaults:@{ | |||
@"setHeight": @1, | |||
@"customOpacity": @1, | |||
@"hidden": @NO, | |||
@"setIconNumber": @4, | |||
}]; | |||
[preferences registerBool:&transparent default:YES forKey:@"transparent"]; | |||
[preferences registerBool:&hidden default:NO forKey:@"hidden"]; | |||
[preferences registerDouble:(double *)&setHeight default:1 forKey:@"setHeight"]; | |||
[preferences registerDouble:(double *)&customOpacity default:1 forKey:@"customOpacity"]; | |||
[preferences registerInteger:(NSInteger *)&setIconNumber default:4 forKey:@"setIconNumber"]; | |||
} | |||
static __attribute__((constructor)) void _logosLocalInit() { | |||
{Class _logos_class$_ungrouped$SBDockView = objc_getClass("SBDockView"); MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(setBackgroundAlpha:), (IMP)&_logos_method$_ungrouped$SBDockView$setBackgroundAlpha$, (IMP*)&_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$);MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(dockHeight), (IMP)&_logos_method$_ungrouped$SBDockView$dockHeight, (IMP*)&_logos_orig$_ungrouped$SBDockView$dockHeight);Class _logos_class$_ungrouped$SBDockIconListView = objc_getClass("SBDockIconListView"); Class _logos_metaclass$_ungrouped$SBDockIconListView = object_getClass(_logos_class$_ungrouped$SBDockIconListView); MSHookMessageEx(_logos_metaclass$_ungrouped$SBDockIconListView, @selector(maxIcons), (IMP)&_logos_meta_method$_ungrouped$SBDockIconListView$maxIcons, (IMP*)&_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons);} } | |||
#line 62 "Tweak.x" |
@@ -6,6 +6,8 @@ | |||
/Users/carsonzielinski/Documents/theos/include/HBLog.h \ | |||
/Users/carsonzielinski/Documents/theos/include/CoreFoundation/CFLogUtilities.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h \ | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h | |||
@@ -21,6 +23,10 @@ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h: | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h: |
@@ -1,13 +1,16 @@ | |||
#line 1 "Tweak.x" | |||
#import <SpringBoard/SpringBoard.h> | |||
#import <SpringBoard/SBDockIconListView.h> | |||
#import <Cephei/HBPreferences.h> | |||
#include <UIKit/UIKit.h> | |||
static BOOL transparent; | |||
static BOOL hidden; | |||
static double setHeight; | |||
static double customOpacity; | |||
static NSInteger setIconNumber; | |||
HBPreferences *preferences; | |||
@@ -33,10 +36,10 @@ HBPreferences *preferences; | |||
#define _LOGOS_RETURN_RETAINED | |||
#endif | |||
@class SBDockView; | |||
static void (*_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static double (*_logos_orig$_ungrouped$SBDockView$dockHeight)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); | |||
@class SBDockIconListView; @class SBDockView; | |||
static void (*_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static double (*_logos_orig$_ungrouped$SBDockView$dockHeight)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static NSInteger (*_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons)(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); | |||
#line 14 "Tweak.x" | |||
#line 17 "Tweak.x" | |||
@@ -51,27 +54,37 @@ static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_ | |||
} | |||
static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
if (hidden) { | |||
return (-50); | |||
} else { | |||
return (_logos_orig$_ungrouped$SBDockView$dockHeight(self, _cmd)*setHeight); | |||
} | |||
static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
if (hidden) { | |||
return (0); | |||
} else { | |||
return (setIconNumber); | |||
} | |||
} | |||
static __attribute__((constructor)) void _logosLocalCtor_d1a00f3d(int __unused argc, char __unused **argv, char __unused **envp) { | |||
static __attribute__((constructor)) void _logosLocalCtor_44056092(int __unused argc, char __unused **argv, char __unused **envp) { | |||
preferences = [[HBPreferences alloc] initWithIdentifier:@"com.burritoz.dockifyprefs"]; | |||
[preferences registerDefaults:@{ | |||
@"setHeight": @1, | |||
@"customOpacity": @1, | |||
@"hidden": @NO | |||
@"hidden": @NO, | |||
@"setIconNumber": @4, | |||
}]; | |||
[preferences registerBool:&transparent default:YES forKey:@"transparent"]; | |||
[preferences registerBool:&hidden default:NO forKey:@"hidden"]; | |||
[preferences registerDouble:(double *)&setHeight default:1 forKey:@"setHeight"]; | |||
[preferences registerDouble:(double *)&customOpacity default:1 forKey:@"customOpacity"]; | |||
[preferences registerInteger:(NSInteger *)&setIconNumber default:4 forKey:@"setIconNumber"]; | |||
} | |||
static __attribute__((constructor)) void _logosLocalInit() { | |||
{Class _logos_class$_ungrouped$SBDockView = objc_getClass("SBDockView"); MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(setBackgroundAlpha:), (IMP)&_logos_method$_ungrouped$SBDockView$setBackgroundAlpha$, (IMP*)&_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$);MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(dockHeight), (IMP)&_logos_method$_ungrouped$SBDockView$dockHeight, (IMP*)&_logos_orig$_ungrouped$SBDockView$dockHeight);} } | |||
#line 49 "Tweak.x" | |||
{Class _logos_class$_ungrouped$SBDockView = objc_getClass("SBDockView"); MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(setBackgroundAlpha:), (IMP)&_logos_method$_ungrouped$SBDockView$setBackgroundAlpha$, (IMP*)&_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$);MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(dockHeight), (IMP)&_logos_method$_ungrouped$SBDockView$dockHeight, (IMP*)&_logos_orig$_ungrouped$SBDockView$dockHeight);Class _logos_class$_ungrouped$SBDockIconListView = objc_getClass("SBDockIconListView"); Class _logos_metaclass$_ungrouped$SBDockIconListView = object_getClass(_logos_class$_ungrouped$SBDockIconListView); MSHookMessageEx(_logos_metaclass$_ungrouped$SBDockIconListView, @selector(maxIcons), (IMP)&_logos_meta_method$_ungrouped$SBDockIconListView$maxIcons, (IMP*)&_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons);} } | |||
#line 62 "Tweak.x" |
@@ -6,6 +6,8 @@ | |||
/Users/carsonzielinski/Documents/theos/include/HBLog.h \ | |||
/Users/carsonzielinski/Documents/theos/include/CoreFoundation/CFLogUtilities.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h \ | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h \ | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h | |||
@@ -21,6 +23,10 @@ | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SpringBoard.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBDockIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/include/SpringBoard/SBIconListView.h: | |||
/Users/carsonzielinski/Documents/theos/vendor/lib/Cephei.framework/Headers/HBPreferences.h: | |||
/Users/carsonzielinski/Documents/theos/include/substrate.h: |
@@ -1,13 +1,16 @@ | |||
#line 1 "Tweak.x" | |||
#import <SpringBoard/SpringBoard.h> | |||
#import <SpringBoard/SBDockIconListView.h> | |||
#import <Cephei/HBPreferences.h> | |||
#include <UIKit/UIKit.h> | |||
static BOOL transparent; | |||
static BOOL hidden; | |||
static double setHeight; | |||
static double customOpacity; | |||
static NSInteger setIconNumber; | |||
HBPreferences *preferences; | |||
@@ -33,10 +36,10 @@ HBPreferences *preferences; | |||
#define _LOGOS_RETURN_RETAINED | |||
#endif | |||
@class SBDockView; | |||
static void (*_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static double (*_logos_orig$_ungrouped$SBDockView$dockHeight)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); | |||
@class SBDockIconListView; @class SBDockView; | |||
static void (*_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL, double); static double (*_logos_orig$_ungrouped$SBDockView$dockHeight)(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST, SEL); static NSInteger (*_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons)(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST, SEL); | |||
#line 14 "Tweak.x" | |||
#line 17 "Tweak.x" | |||
@@ -51,27 +54,37 @@ static void _logos_method$_ungrouped$SBDockView$setBackgroundAlpha$(_LOGOS_SELF_ | |||
} | |||
static double _logos_method$_ungrouped$SBDockView$dockHeight(_LOGOS_SELF_TYPE_NORMAL SBDockView* _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
if (hidden) { | |||
return (-50); | |||
} else { | |||
return (_logos_orig$_ungrouped$SBDockView$dockHeight(self, _cmd)*setHeight); | |||
} | |||
static NSInteger _logos_meta_method$_ungrouped$SBDockIconListView$maxIcons(_LOGOS_SELF_TYPE_NORMAL Class _LOGOS_SELF_CONST __unused self, SEL __unused _cmd) { | |||
if (hidden) { | |||
return (0); | |||
} else { | |||
return (setIconNumber); | |||
} | |||
} | |||
static __attribute__((constructor)) void _logosLocalCtor_d1a00f3d(int __unused argc, char __unused **argv, char __unused **envp) { | |||
static __attribute__((constructor)) void _logosLocalCtor_44056092(int __unused argc, char __unused **argv, char __unused **envp) { | |||
preferences = [[HBPreferences alloc] initWithIdentifier:@"com.burritoz.dockifyprefs"]; | |||
[preferences registerDefaults:@{ | |||
@"setHeight": @1, | |||
@"customOpacity": @1, | |||
@"hidden": @NO | |||
@"hidden": @NO, | |||
@"setIconNumber": @4, | |||
}]; | |||
[preferences registerBool:&transparent default:YES forKey:@"transparent"]; | |||
[preferences registerBool:&hidden default:NO forKey:@"hidden"]; | |||
[preferences registerDouble:(double *)&setHeight default:1 forKey:@"setHeight"]; | |||
[preferences registerDouble:(double *)&customOpacity default:1 forKey:@"customOpacity"]; | |||
[preferences registerInteger:(NSInteger *)&setIconNumber default:4 forKey:@"setIconNumber"]; | |||
} | |||
static __attribute__((constructor)) void _logosLocalInit() { | |||
{Class _logos_class$_ungrouped$SBDockView = objc_getClass("SBDockView"); MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(setBackgroundAlpha:), (IMP)&_logos_method$_ungrouped$SBDockView$setBackgroundAlpha$, (IMP*)&_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$);MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(dockHeight), (IMP)&_logos_method$_ungrouped$SBDockView$dockHeight, (IMP*)&_logos_orig$_ungrouped$SBDockView$dockHeight);} } | |||
#line 49 "Tweak.x" | |||
{Class _logos_class$_ungrouped$SBDockView = objc_getClass("SBDockView"); MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(setBackgroundAlpha:), (IMP)&_logos_method$_ungrouped$SBDockView$setBackgroundAlpha$, (IMP*)&_logos_orig$_ungrouped$SBDockView$setBackgroundAlpha$);MSHookMessageEx(_logos_class$_ungrouped$SBDockView, @selector(dockHeight), (IMP)&_logos_method$_ungrouped$SBDockView$dockHeight, (IMP*)&_logos_orig$_ungrouped$SBDockView$dockHeight);Class _logos_class$_ungrouped$SBDockIconListView = objc_getClass("SBDockIconListView"); Class _logos_metaclass$_ungrouped$SBDockIconListView = object_getClass(_logos_class$_ungrouped$SBDockIconListView); MSHookMessageEx(_logos_metaclass$_ungrouped$SBDockIconListView, @selector(maxIcons), (IMP)&_logos_meta_method$_ungrouped$SBDockIconListView$maxIcons, (IMP*)&_logos_meta_orig$_ungrouped$SBDockIconListView$maxIcons);} } | |||
#line 62 "Tweak.x" |
@@ -15,14 +15,12 @@ | |||
<string>icon.png</string> | |||
<key>packageIdentifier</key> | |||
<string>com.burritoz.testing</string> | |||
<key>packageNameOverride</key> | |||
<string>Dockify by Burrit0z</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Transparent Toggle (overrides custom opcaity):</string> | |||
<string>Overall Dock Settings:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
@@ -36,12 +34,6 @@ | |||
<key>label</key> | |||
<string>Transparent Dock</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Hide Dock (overrides custom height):</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSSwitchCell</string> | |||
@@ -52,7 +44,7 @@ | |||
<key>key</key> | |||
<string>hidden</string> | |||
<key>label</key> | |||
<string>Hide (kinda, not really)</string> | |||
<string>Hide</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
@@ -102,6 +94,38 @@ | |||
<key>showValue</key> | |||
<true/> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Max Dock Icons (each row):</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSSliderCell</string> | |||
<key>default</key> | |||
<string>4</string> | |||
<key>defaults</key> | |||
<string>com.burritoz.dockifyprefs</string> | |||
<key>key</key> | |||
<string>setIconNumber</string> | |||
<key>min</key> | |||
<integer>0</integer> | |||
<key>max</key> | |||
<integer>20</integer> | |||
<key>isSegmented</key> | |||
<true/> | |||
<key>segmentCount</key> | |||
<integer>20</integer> | |||
<key>showValue</key> | |||
<true/> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string></string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSButtonCell</string> | |||
@@ -116,18 +140,6 @@ | |||
<key>footerText</key> | |||
<string>"Try not. Do... or do not. There is no try."</string> | |||
</dict> | |||
<dict> | |||
<key>cellClass</key> | |||
<string>HBLinkTableCell</string> | |||
<key>label</key> | |||
<string>Source Code</string> | |||
<key>subtitle</key> | |||
<string>The source code for Dockify</string> | |||
<key>icon</key> | |||
<string>icon.png</string> | |||
<key>url</key> | |||
<string>https://github.com/Burrit0z/Dockify_Source</string> | |||
</dict> | |||
</array> | |||
<key>title</key> | |||
<string>Dockify</string> |
@@ -15,14 +15,12 @@ | |||
<string>icon.png</string> | |||
<key>packageIdentifier</key> | |||
<string>com.burritoz.testing</string> | |||
<key>packageNameOverride</key> | |||
<string>Dockify by Burrit0z</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Transparent Toggle (overrides custom opcaity):</string> | |||
<string>Overall Dock Settings:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
@@ -36,12 +34,6 @@ | |||
<key>label</key> | |||
<string>Transparent Dock</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Hide Dock (overrides custom height):</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSSwitchCell</string> | |||
@@ -52,7 +44,7 @@ | |||
<key>key</key> | |||
<string>hidden</string> | |||
<key>label</key> | |||
<string>Hide (kinda, not really)</string> | |||
<string>Hide</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
@@ -102,6 +94,38 @@ | |||
<key>showValue</key> | |||
<true/> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Max Dock Icons:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSSliderCell</string> | |||
<key>default</key> | |||
<string>4</string> | |||
<key>defaults</key> | |||
<string>com.burritoz.dockifyprefs</string> | |||
<key>key</key> | |||
<string>setIconNumber</string> | |||
<key>min</key> | |||
<integer>0</integer> | |||
<key>max</key> | |||
<integer>20</integer> | |||
<key>isSegmented</key> | |||
<true/> | |||
<key>segmentCount</key> | |||
<integer>20</integer> | |||
<key>showValue</key> | |||
<true/> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string></string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSButtonCell</string> |
@@ -0,0 +1 @@ | |||
13 |
@@ -1,12 +1,15 @@ | |||
//import needed files/headers | |||
#import <SpringBoard/SpringBoard.h> | |||
#import <SpringBoard/SBDockIconListView.h> | |||
#import <Cephei/HBPreferences.h> | |||
#include <UIKit/UIKit.h> | |||
//Set up variables for use with Cephei | |||
static BOOL transparent; | |||
static BOOL hidden; | |||
static double setHeight; | |||
static double customOpacity; | |||
static NSInteger setIconNumber; | |||
HBPreferences *preferences; | |||
@@ -25,12 +28,20 @@ HBPreferences *preferences; | |||
} | |||
-(double)dockHeight { | |||
if (hidden) { | |||
return (-50); //just puts the dock barely off screen lol | |||
} else { | |||
return (%orig*setHeight); //sets custom height if dock is not set to hidden | |||
} | |||
%end | |||
%hook SBDockIconListView | |||
+(NSInteger)maxIcons { | |||
if (hidden) { | |||
return (0); | |||
} else { | |||
return (setIconNumber); | |||
} | |||
} | |||
%end | |||
@@ -39,10 +50,12 @@ HBPreferences *preferences; | |||
[preferences registerDefaults:@{ //defaults for prefernces | |||
@"setHeight": @1, | |||
@"customOpacity": @1, | |||
@"hidden": @NO | |||
@"hidden": @NO, | |||
@"setIconNumber": @4, | |||
}]; | |||
[preferences registerBool:&transparent default:YES forKey:@"transparent"]; //registering transparent as a Boolean | |||
[preferences registerBool:&hidden default:NO forKey:@"hidden"]; //registering hidden as a Boolean | |||
[preferences registerDouble:(double *)&setHeight default:1 forKey:@"setHeight"]; //registering setHeigt as a double (number) | |||
[preferences registerDouble:(double *)&customOpacity default:1 forKey:@"customOpacity"]; //registering customOpacity as a double (number) | |||
[preferences registerInteger:(NSInteger *)&setIconNumber default:4 forKey:@"setIconNumber"]; //Integer of how many icons to allow | |||
} |
@@ -1,7 +1,7 @@ | |||
Package: com.burritoz.testing | |||
Name: Dockify | |||
Depends: mobilesubstrate, preferenceloader, com.saurik.substrate.safemode, ws.hbang.common (>=1.13) | |||
Version: 1.1 | |||
Version: 1.2 | |||
Architecture: iphoneos-arm | |||
Description: A very noice tweak to configure the dock a bit more... | |||
Maintainer: burrit0z |
@@ -15,14 +15,12 @@ | |||
<string>icon.png</string> | |||
<key>packageIdentifier</key> | |||
<string>com.burritoz.testing</string> | |||
<key>packageNameOverride</key> | |||
<string>Dockify by Burrit0z</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Transparent Toggle (overrides custom opcaity):</string> | |||
<string>Overall Dock Settings:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
@@ -36,12 +34,6 @@ | |||
<key>label</key> | |||
<string>Transparent Dock</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Hide Dock (overrides custom height):</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSSwitchCell</string> | |||
@@ -52,7 +44,7 @@ | |||
<key>key</key> | |||
<string>hidden</string> | |||
<key>label</key> | |||
<string>Hide (kinda, not really)</string> | |||
<string>Hide</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
@@ -102,6 +94,38 @@ | |||
<key>showValue</key> | |||
<true/> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string>Max Dock Icons:</string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSSliderCell</string> | |||
<key>default</key> | |||
<string>4</string> | |||
<key>defaults</key> | |||
<string>com.burritoz.dockifyprefs</string> | |||
<key>key</key> | |||
<string>setIconNumber</string> | |||
<key>min</key> | |||
<integer>0</integer> | |||
<key>max</key> | |||
<integer>20</integer> | |||
<key>isSegmented</key> | |||
<true/> | |||
<key>segmentCount</key> | |||
<integer>20</integer> | |||
<key>showValue</key> | |||
<true/> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSGroupCell</string> | |||
<key>label</key> | |||
<string></string> | |||
</dict> | |||
<dict> | |||
<key>cell</key> | |||
<string>PSButtonCell</string> |