From 7e9ba2cf6f42ef7d2e0dca07382b090a78e3c7c3 Mon Sep 17 00:00:00 2001 From: Marius Ursache Date: Mon, 29 Feb 2016 21:39:49 +1100 Subject: Fixed fabs compiler warnings --- Source/SPComboPopupButton.m | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'Source') diff --git a/Source/SPComboPopupButton.m b/Source/SPComboPopupButton.m index 8c090911..3df3d6ec 100644 --- a/Source/SPComboPopupButton.m +++ b/Source/SPComboPopupButton.m @@ -129,9 +129,9 @@ CGContextSaveGState(context); CGContextSetStrokeColor(context, lineColorParts); - CGContextAddRect(context, CGRectMake(boundingLinePosition - 0.5, boundsRect.origin.y + heightIndent, 1.f, boundsRect.size.height - abs(2 * heightIndent))); + CGContextAddRect(context, CGRectMake(boundingLinePosition - 0.5, boundsRect.origin.y + heightIndent, 1.f, boundsRect.size.height - fabs(2 * heightIndent))); CGContextClip(context); - CGContextDrawLinearGradient(context, lineGradient, CGPointMake(boundingLinePosition - 0.5, boundsRect.origin.y + heightIndent), CGPointMake(boundingLinePosition - 0.5, boundsRect.origin.y + boundsRect.size.height - abs(heightIndent)), 0); + CGContextDrawLinearGradient(context, lineGradient, CGPointMake(boundingLinePosition - 0.5, boundsRect.origin.y + heightIndent), CGPointMake(boundingLinePosition - 0.5, boundsRect.origin.y + boundsRect.size.height - fabs(heightIndent)), 0); CGContextRestoreGState(context); CGGradientRelease(lineGradient); @@ -281,7 +281,7 @@ // Custom tracking to be performed - indent the vertical button area slightly - activeRect = NSMakeRect(cellFrame.origin.x, cellFrame.origin.y + heightIndent, cellFrame.size.width - [(SPComboPopupButton *)controlView lineOffset] + 1, cellFrame.size.height - fabsf(2 * heightIndent)); + activeRect = NSMakeRect(cellFrame.origin.x, cellFrame.origin.y + heightIndent, cellFrame.size.width - [(SPComboPopupButton *)controlView lineOffset] + 1, cellFrame.size.height - fabs(2 * heightIndent)); // Continue tracking the mouse while it's down, updating the state as it enters and leaves the cell, // until it is released; if still within the cell, perform a click. -- cgit v1.2.3 From 67f1ef6e43027380cbdc976115164fbeee1c2dc2 Mon Sep 17 00:00:00 2001 From: Abhi Beckert Date: Fri, 4 Mar 2016 17:46:00 +1000 Subject: Comment out debug code for #2297 --- Source/SPObjectAdditions.m | 71 +++++++++++++++++++++++----------------------- 1 file changed, 36 insertions(+), 35 deletions(-) (limited to 'Source') diff --git a/Source/SPObjectAdditions.m b/Source/SPObjectAdditions.m index bf8210ea..9dfe8559 100644 --- a/Source/SPObjectAdditions.m +++ b/Source/SPObjectAdditions.m @@ -51,38 +51,39 @@ @end -#pragma mark - - -@interface NSAlert (ApplePrivate) - -- (IBAction)buttonPressed:(id)sender; - -@end - -@implementation NSAlert (SPAlertDebug) - -+ (void)load -{ - static dispatch_once_t onceToken; - - dispatch_once(&onceToken, ^{ - Class alertClass = [self class]; - - SEL orig = @selector(buttonPressed:); - SEL exch = @selector(sp_buttonPressed:); - - Method origM = class_getInstanceMethod(alertClass, orig); - Method exchM = class_getInstanceMethod(alertClass, exch); - - method_exchangeImplementations(origM, exchM); - }); -} - -- (IBAction)sp_buttonPressed:(id)obj -{ - NSLog(@"%s of %@ title=\n%@\ntext=\n%@",__func__,self,[self messageText],[self informativeText]); - - [self sp_buttonPressed:obj]; -} - -@end +// method swizzling to try and reproduce #2297 +//#pragma mark - +// +//@interface NSAlert (ApplePrivate) +// +//- (IBAction)buttonPressed:(id)sender; +// +//@end +// +//@implementation NSAlert (SPAlertDebug) +// +//+ (void)load +//{ +// static dispatch_once_t onceToken; +// +// dispatch_once(&onceToken, ^{ +// Class alertClass = [self class]; +// +// SEL orig = @selector(buttonPressed:); +// SEL exch = @selector(sp_buttonPressed:); +// +// Method origM = class_getInstanceMethod(alertClass, orig); +// Method exchM = class_getInstanceMethod(alertClass, exch); +// +// method_exchangeImplementations(origM, exchM); +// }); +//} +// +//- (IBAction)sp_buttonPressed:(id)obj +//{ +// NSLog(@"%s of %@ title=\n%@\ntext=\n%@",__func__,self,[self messageText],[self informativeText]); +// +// [self sp_buttonPressed:obj]; +//} +// +//@end -- cgit v1.2.3 From faafa14b29d618a5342891214101da1bf2fbff80 Mon Sep 17 00:00:00 2001 From: Abhi Beckert Date: Fri, 4 Mar 2016 18:02:44 +1000 Subject: Remove bundled zlib #1927 --- Source/SPFileHandle.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Source') diff --git a/Source/SPFileHandle.m b/Source/SPFileHandle.m index 49bcd4a4..8cc6bed4 100644 --- a/Source/SPFileHandle.m +++ b/Source/SPFileHandle.m @@ -29,8 +29,8 @@ // More info at #import "SPFileHandle.h" -#import "zlib.1.2.4.h" #import "bzlib.h" +#import "zlib.h" #import "pthread.h" // Define the maximum size of the background write buffer before the writing thread -- cgit v1.2.3 From 96619853ae80f40e34c53105f08f79e89bb9df13 Mon Sep 17 00:00:00 2001 From: Abhi Beckert Date: Sat, 5 Mar 2016 08:07:16 +1000 Subject: Restore bundled zlib (#1972) --- Source/SPFileHandle.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'Source') diff --git a/Source/SPFileHandle.m b/Source/SPFileHandle.m index 8cc6bed4..7da3d100 100644 --- a/Source/SPFileHandle.m +++ b/Source/SPFileHandle.m @@ -30,7 +30,7 @@ #import "SPFileHandle.h" #import "bzlib.h" -#import "zlib.h" +#import "zlib.1.2.4.h" #import "pthread.h" // Define the maximum size of the background write buffer before the writing thread -- cgit v1.2.3