From 5b05f3f15aa0676f91bc1d127d31f4fd95ef9f40 Mon Sep 17 00:00:00 2001 From: avenjamin Date: Wed, 24 Jun 2009 15:46:27 +0000 Subject: - Changed the way the BWToolkit framework was included to allow modifications to be made easily. - Fixed show/hide info pane toggle button image states to now show correctly --- .../BWAnchoredButton.m | 43 ++++++++++++++++++++++ 1 file changed, 43 insertions(+) create mode 100644 Frameworks/BWToolkitFramework.framework/BWAnchoredButton.m (limited to 'Frameworks/BWToolkitFramework.framework/BWAnchoredButton.m') diff --git a/Frameworks/BWToolkitFramework.framework/BWAnchoredButton.m b/Frameworks/BWToolkitFramework.framework/BWAnchoredButton.m new file mode 100644 index 00000000..4fca331a --- /dev/null +++ b/Frameworks/BWToolkitFramework.framework/BWAnchoredButton.m @@ -0,0 +1,43 @@ +// +// BWAnchoredButton.m +// BWToolkit +// +// Created by Brandon Walkin (www.brandonwalkin.com) +// All code is provided under the New BSD license. +// + +#import "BWAnchoredButton.h" +#import "BWAnchoredButtonBar.h" +#import "NSView+BWAdditions.h" + +@implementation BWAnchoredButton + +@synthesize isAtLeftEdgeOfBar; +@synthesize isAtRightEdgeOfBar; + +- (id)initWithCoder:(NSCoder *)decoder; +{ + if ((self = [super initWithCoder:decoder]) != nil) + { + if ([BWAnchoredButtonBar wasBorderedBar]) + topAndLeftInset = NSMakePoint(0, 0); + else + topAndLeftInset = NSMakePoint(1, 1); + } + return self; +} + +- (void)mouseDown:(NSEvent *)theEvent +{ + [self bringToFront]; + [super mouseDown:theEvent]; +} + +- (NSRect)frame +{ + NSRect frame = [super frame]; + frame.size.height = 24; + return frame; +} + +@end -- cgit v1.2.3