Commits

Anonymous committed 7e348c1

64-bit support (courtesy of Rob Rix)

Comments (0)

Files changed (7)

BWTokenAttachmentCell.m

 	}
 
 	// Darken on mouse over
-	float red, blue, green, alpha;
+	CGFloat red, blue, green, alpha;
 	[[self tokenBackgroundColor] getRed:&red green:&green blue:&blue alpha:&alpha];
 	
 	if (red > 0.427 && red < 0.428)

BWToolkit.xcodeproj/project.pbxproj

 		CA630CB90DC83EB700AD7F9E /* BWTransparentSliderIntegration.m in Sources */ = {isa = PBXBuildFile; fileRef = CA630CB80DC83EB700AD7F9E /* BWTransparentSliderIntegration.m */; };
 		CA630CFA0DC843DD00AD7F9E /* BWAddSmallBottomBar.h in Headers */ = {isa = PBXBuildFile; fileRef = CA630CF80DC843DD00AD7F9E /* BWAddSmallBottomBar.h */; };
 		CA630CFB0DC843DD00AD7F9E /* BWAddSmallBottomBar.m in Sources */ = {isa = PBXBuildFile; fileRef = CA630CF90DC843DD00AD7F9E /* BWAddSmallBottomBar.m */; };
+		CA66C0F60EF79AC0005EE9A5 /* NSString+BWAdditions.m in Sources */ = {isa = PBXBuildFile; fileRef = CA66C0F40EF79AC0005EE9A5 /* NSString+BWAdditions.m */; };
+		CA66C0F70EF79AC0005EE9A5 /* NSString+BWAdditions.h in Headers */ = {isa = PBXBuildFile; fileRef = CA66C0F50EF79AC0005EE9A5 /* NSString+BWAdditions.h */; };
 		CA685D7D0E6639680003D937 /* BWSplitViewInspector.xib in Resources */ = {isa = PBXBuildFile; fileRef = CA685D7C0E6639680003D937 /* BWSplitViewInspector.xib */; };
 		CA685D840E663E4D0003D937 /* BWSplitViewInspector.m in Sources */ = {isa = PBXBuildFile; fileRef = CA685D830E663E4D0003D937 /* BWSplitViewInspector.m */; };
 		CA685D8C0E6646000003D937 /* BWSplitViewIntegration.m in Sources */ = {isa = PBXBuildFile; fileRef = CA685D8B0E6646000003D937 /* BWSplitViewIntegration.m */; };
 		CA630CB80DC83EB700AD7F9E /* BWTransparentSliderIntegration.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BWTransparentSliderIntegration.m; sourceTree = "<group>"; };
 		CA630CF80DC843DD00AD7F9E /* BWAddSmallBottomBar.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BWAddSmallBottomBar.h; sourceTree = "<group>"; };
 		CA630CF90DC843DD00AD7F9E /* BWAddSmallBottomBar.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BWAddSmallBottomBar.m; sourceTree = "<group>"; };
+		CA66C0F40EF79AC0005EE9A5 /* NSString+BWAdditions.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = "NSString+BWAdditions.m"; sourceTree = "<group>"; };
+		CA66C0F50EF79AC0005EE9A5 /* NSString+BWAdditions.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = "NSString+BWAdditions.h"; sourceTree = "<group>"; };
 		CA685D7C0E6639680003D937 /* BWSplitViewInspector.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = BWSplitViewInspector.xib; sourceTree = "<group>"; };
 		CA685D820E663E4D0003D937 /* BWSplitViewInspector.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BWSplitViewInspector.h; sourceTree = "<group>"; };
 		CA685D830E663E4D0003D937 /* BWSplitViewInspector.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BWSplitViewInspector.m; sourceTree = "<group>"; };
 				CA944DD90DDF800D00F103BC /* NSWindow+BWAdditions.m */,
 				CA944F060DE00CC000F103BC /* NSView+BWAdditions.h */,
 				CA944F070DE00CC000F103BC /* NSView+BWAdditions.m */,
+				CA66C0F50EF79AC0005EE9A5 /* NSString+BWAdditions.h */,
+				CA66C0F40EF79AC0005EE9A5 /* NSString+BWAdditions.m */,
 			);
 			name = Categories;
 			sourceTree = "<group>";
 				CA405A700EBF2E400010580A /* BWTransparentScroller.h in Headers */,
 				CA3A18890ECA9E86000C3A43 /* BWTransparentTextFieldCell.h in Headers */,
 				CAEA804D0ED0A73E0062B378 /* BWToolbarItem.h in Headers */,
+				CA66C0F70EF79AC0005EE9A5 /* NSString+BWAdditions.h in Headers */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
 				CA405A6F0EBF2E400010580A /* BWTransparentScroller.m in Sources */,
 				CA3A188A0ECA9E86000C3A43 /* BWTransparentTextFieldCell.m in Sources */,
 				CAEA804E0ED0A73E0062B378 /* BWToolbarItem.m in Sources */,
+				CA66C0F60EF79AC0005EE9A5 /* NSString+BWAdditions.m in Sources */,
 			);
 			runOnlyForDeploymentPostprocessing = 0;
 		};
 		C056398408A954F8003078D8 /* Debug */ = {
 			isa = XCBuildConfiguration;
 			buildSettings = {
+				ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)";
+				ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386";
 				COPY_PHASE_STRIP = NO;
 				FRAMEWORK_SEARCH_PATHS = "\"/Developer/Library/Frameworks\"";
 				GCC_DYNAMIC_NO_PIC = NO;
 		C056398508A954F8003078D8 /* Release */ = {
 			isa = XCBuildConfiguration;
 			buildSettings = {
+				ARCHS = "$(ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1)";
+				ARCHS_STANDARD_32_BIT_PRE_XCODE_3_1 = "ppc i386";
 				COPY_PHASE_STRIP = NO;
 				DEBUG_INFORMATION_FORMAT = "dwarf-with-dsym";
 				FRAMEWORK_SEARCH_PATHS = "\"/Developer/Library/Frameworks\"";
 		C056398C08A954F8003078D8 /* Debug */ = {
 			isa = XCBuildConfiguration;
 			buildSettings = {
+				ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)";
+				ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "ppc i386 ppc64 x86_64";
 				GCC_MODEL_TUNING = "";
 				GCC_WARN_ABOUT_RETURN_TYPE = YES;
 				GCC_WARN_UNUSED_VARIABLE = YES;
 		C056398D08A954F8003078D8 /* Release */ = {
 			isa = XCBuildConfiguration;
 			buildSettings = {
-				ARCHS = (
-					ppc,
-					i386,
-				);
+				ARCHS = "$(ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1)";
+				ARCHS_STANDARD_32_64_BIT_PRE_XCODE_3_1 = "ppc i386 ppc64 x86_64";
 				GCC_MODEL_TUNING = "";
 				GCC_WARN_ABOUT_RETURN_TYPE = YES;
 				GCC_WARN_UNUSED_VARIABLE = YES;

BWTransparentCheckboxCell.m

 	if ([[self controlView] isMemberOfClass:[BWTransparentTableView class]])
 		frame.origin.x += 4;
 	
-	float y = NSMaxY(frame) - (frame.size.height - checkboxOffN.size.height) / 2.0 - 15;
-	float x = frame.origin.x + 1;
+	CGFloat y = NSMaxY(frame) - (frame.size.height - checkboxOffN.size.height) / 2.0 - 15;
+	CGFloat x = frame.origin.x + 1;
 	NSPoint point = NSMakePoint(x, roundf(y));
 	
-	float alpha = 1.0;
+	CGFloat alpha = 1.0;
 	
 	if (![self isEnabled])
 		alpha = 0.6;

BWTransparentSliderCell.m

 		slideRect.size.width++;
 	}
 	
-	float alpha = 1.0;
+	CGFloat alpha = 1.0;
 	
 	if (![self isEnabled])
 		alpha = 0.6;
 }
 
 + (void)initialize;
-- (id)initWithFrame:(struct _NSRect)fp8;
+- (id)initWithFrame:(NSRect)fp8;
 - (void)dealloc;
 - (void)finalize;
 - (id)nibInstantiate;

NSTokenAttachmentCell.h

 - (void)setTextColor:(id)fp8;
 - (id)pullDownImage;
 - (id)menu;
-- (struct _NSSize)cellSizeForBounds:(struct _NSRect)fp8;
-- (struct _NSSize)cellSize;
-- (struct _NSRect)drawingRectForBounds:(struct _NSRect)fp8;
-- (struct _NSRect)titleRectForBounds:(struct _NSRect)fp8;
-- (struct _NSRect)cellFrameForTextContainer:(id)fp8 proposedLineFragment:(struct _NSRect)fp12 glyphPosition:(struct _NSPoint)fp28 characterIndex:(unsigned int)fp36;
-- (struct _NSPoint)cellBaselineOffset;
-- (struct _NSRect)pullDownRectForBounds:(struct _NSRect)fp8;
-- (void)drawTokenWithFrame:(struct _NSRect)fp8 inView:(id)fp24;
-- (void)drawInteriorWithFrame:(struct _NSRect)fp8 inView:(id)fp24;
-- (void)drawWithFrame:(struct _NSRect)fp8 inView:(id)fp24;
-- (void)drawWithFrame:(struct _NSRect)fp8 inView:(id)fp24 characterIndex:(unsigned int)fp28 layoutManager:(id)fp32;
+- (NSSize)cellSizeForBounds:(NSRect)fp8;
+- (NSSize)cellSize;
+- (NSRect)drawingRectForBounds:(NSRect)fp8;
+- (NSRect)titleRectForBounds:(NSRect)fp8;
+- (NSRect)cellFrameForTextContainer:(id)fp8 proposedLineFragment:(NSRect)fp12 glyphPosition:(NSPoint)fp28 characterIndex:(unsigned int)fp36;
+- (NSPoint)cellBaselineOffset;
+- (NSRect)pullDownRectForBounds:(NSRect)fp8;
+- (void)drawTokenWithFrame:(NSRect)fp8 inView:(id)fp24;
+- (void)drawInteriorWithFrame:(NSRect)fp8 inView:(id)fp24;
+- (void)drawWithFrame:(NSRect)fp8 inView:(id)fp24;
+- (void)drawWithFrame:(NSRect)fp8 inView:(id)fp24 characterIndex:(unsigned int)fp28 layoutManager:(id)fp32;
 - (void)encodeWithCoder:(id)fp8;
 - (id)initWithCoder:(id)fp8;
-- (BOOL)wantsToTrackMouseForEvent:(id)fp8 inRect:(struct _NSRect)fp12 ofView:(id)fp28 atCharacterIndex:(unsigned int)fp32;
-- (BOOL)trackMouse:(id)fp8 inRect:(struct _NSRect)fp12 ofView:(id)fp28 atCharacterIndex:(unsigned int)fp32 untilMouseUp:(BOOL)fp36;
+- (BOOL)wantsToTrackMouseForEvent:(id)fp8 inRect:(NSRect)fp12 ofView:(id)fp28 atCharacterIndex:(unsigned int)fp32;
+- (BOOL)trackMouse:(id)fp8 inRect:(NSRect)fp12 ofView:(id)fp28 atCharacterIndex:(unsigned int)fp32 untilMouseUp:(BOOL)fp36;
 
 @end
 

NSView+BWAdditions.m

 
 #import "NSView+BWAdditions.h"
 
-int compareViews(id firstView, id secondView, id context);
-int compareViews(id firstView, id secondView, id context)
+NSComparisonResult compareViews(id firstView, id secondView, id context);
+NSComparisonResult compareViews(id firstView, id secondView, id context)
 {
 	if (firstView != context && secondView != context) {return NSOrderedSame;}
 	else
 
 - (void)bringToFront
 {
-	[[self superview] sortSubviewsUsingFunction:(int (*)(id, id, void *))compareViews context:self];
+	[[self superview] sortSubviewsUsingFunction:(NSComparisonResult (*)(id, id, void *))compareViews context:self];
 }
 
 @end