Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Moved files to proper folder.

  • Loading branch information...
commit 0e114399ca3590fb9d8e88793e877c28626692c2 1 parent 22e2b4e
@binarygod authored
View
10 BGHUDAppKit.xcodeproj/project.pbxproj
@@ -221,10 +221,10 @@
E706FE790E12DE180017E470 /* BGHUDOutlineView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BGHUDOutlineView.h; path = Framework/BGHUDOutlineView.h; sourceTree = "<group>"; };
E706FE7A0E12DE180017E470 /* BGHUDOutlineView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = BGHUDOutlineView.m; path = Framework/BGHUDOutlineView.m; sourceTree = "<group>"; };
E706FE820E12DEFA0017E470 /* BGHUDOutlineView.classdescription */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = BGHUDOutlineView.classdescription; sourceTree = "<group>"; };
- E70CA2BB0FB6F89D0073E3DF /* BGHUDTabViewItem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BGHUDTabViewItem.h; sourceTree = "<group>"; };
- E70CA2BC0FB6F89D0073E3DF /* BGHUDTabViewItem.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BGHUDTabViewItem.m; sourceTree = "<group>"; };
- E70CA2C00FB6FFBB0073E3DF /* BGHUDTabView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BGHUDTabView.h; sourceTree = "<group>"; };
- E70CA2C10FB6FFBB0073E3DF /* BGHUDTabView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BGHUDTabView.m; sourceTree = "<group>"; };
+ E70CA2BB0FB6F89D0073E3DF /* BGHUDTabViewItem.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BGHUDTabViewItem.h; path = Framework/BGHUDTabViewItem.h; sourceTree = "<group>"; };
+ E70CA2BC0FB6F89D0073E3DF /* BGHUDTabViewItem.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = BGHUDTabViewItem.m; path = Framework/BGHUDTabViewItem.m; sourceTree = "<group>"; };
+ E70CA2C00FB6FFBB0073E3DF /* BGHUDTabView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BGHUDTabView.h; path = Framework/BGHUDTabView.h; sourceTree = "<group>"; };
+ E70CA2C10FB6FFBB0073E3DF /* BGHUDTabView.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = BGHUDTabView.m; path = Framework/BGHUDTabView.m; sourceTree = "<group>"; };
E70CA2C40FB704950073E3DF /* BGHUDTabView.classdescription */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = BGHUDTabView.classdescription; sourceTree = "<group>"; };
E70CA2C60FB705040073E3DF /* BGHUDTabViewIntegration.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BGHUDTabViewIntegration.m; sourceTree = "<group>"; };
E70CE4FF0E188A61000139C1 /* BGHUDTableCornerView.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BGHUDTableCornerView.h; path = Framework/BGHUDTableCornerView.h; sourceTree = "<group>"; };
@@ -302,7 +302,7 @@
E79C25D80E109C1800742AF4 /* BGHUDTextFieldCellIntegration.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = BGHUDTextFieldCellIntegration.m; sourceTree = "<group>"; };
E7B7F64B0E9EAFB70032873A /* scrollview.png */ = {isa = PBXFileReference; lastKnownFileType = image.png; name = scrollview.png; path = "Inspector Images/scrollview.png"; sourceTree = "<group>"; };
E7B8A3480E172733006AC84C /* Theming.rtf */ = {isa = PBXFileReference; lastKnownFileType = text.rtf; path = Theming.rtf; sourceTree = "<group>"; };
- E7C104940E8C476D00A96E1A /* BGHUDGeometry.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = BGHUDGeometry.h; sourceTree = "<group>"; };
+ E7C104940E8C476D00A96E1A /* BGHUDGeometry.h */ = {isa = PBXFileReference; explicitFileType = sourcecode.c.h; fileEncoding = 4; name = BGHUDGeometry.h; path = Framework/BGHUDGeometry.h; sourceTree = "<group>"; };
E7CEE1CA0F49D8FB00F5DABB /* BGHUDBox.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = BGHUDBox.h; path = Framework/BGHUDBox.h; sourceTree = "<group>"; };
E7CEE1CB0F49D8FB00F5DABB /* BGHUDBox.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = BGHUDBox.m; path = Framework/BGHUDBox.m; sourceTree = "<group>"; };
E7CEE1D10F49D99900F5DABB /* BGHUDBox.classdescription */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = text; path = BGHUDBox.classdescription; sourceTree = "<group>"; };
View
42 Framework/BGHUDGeometry.h
@@ -0,0 +1,42 @@
+//
+// BGHUDGeometry.h
+// BGHUDAppKit
+//
+// Created by BinaryGod on 9/25/08.
+// Copyright 2008 none. All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without modification,
+// are permitted provided that the following conditions are met:
+//
+// Redistributions of source code must retain the above copyright notice, this
+// list of conditions and the following disclaimer.
+//
+// Redistributions in binary form must reproduce the above copyright notice,
+// this list of conditions and the following disclaimer in the documentation and/or
+// other materials provided with the distribution.
+//
+// Neither the name of the BinaryMethod.com nor the names of its contributors
+// may be used to endorse or promote products derived from this software without
+// specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS AS IS AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
+// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+// OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+// POSSIBILITY OF SUCH DAMAGE.
+
+#import <Foundation/NSGeometry.h>
+
+
+NS_INLINE CGFloat BGCenterX(NSRect aRect) {
+ return (aRect.size.width / 2);
+}
+
+NS_INLINE CGFloat BGCenterY(NSRect aRect) {
+ return (aRect.size.height / 2);
+}
View
44 Framework/BGHUDTabView.h
@@ -0,0 +1,44 @@
+//
+// BGHUDTabView.h
+// BGHUDAppKit
+//
+// Created by BinaryGod on 5/10/09.
+// Copyright 2009 none. All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without modification,
+// are permitted provided that the following conditions are met:
+//
+// Redistributions of source code must retain the above copyright notice, this
+// list of conditions and the following disclaimer.
+//
+// Redistributions in binary form must reproduce the above copyright notice,
+// this list of conditions and the following disclaimer in the documentation and/or
+// other materials provided with the distribution.
+//
+// Neither the name of the BinaryMethod.com nor the names of its contributors
+// may be used to endorse or promote products derived from this software without
+// specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS AS IS AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
+// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+// OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+// POSSIBILITY OF SUCH DAMAGE.
+
+#import <Cocoa/Cocoa.h>
+#import "BGThemeManager.h"
+#import "BGHUDTabViewItem.h"
+
+@interface BGHUDTabView : NSTabView {
+
+ NSString *themeKey;
+}
+
+@property (retain) NSString *themeKey;
+
+@end
View
297 Framework/BGHUDTabView.m
@@ -0,0 +1,297 @@
+//
+// BGHUDTabView.m
+// BGHUDAppKit
+//
+// Created by BinaryGod on 5/10/09.
+// Copyright 2009 none. All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without modification,
+// are permitted provided that the following conditions are met:
+//
+// Redistributions of source code must retain the above copyright notice, this
+// list of conditions and the following disclaimer.
+//
+// Redistributions in binary form must reproduce the above copyright notice,
+// this list of conditions and the following disclaimer in the documentation and/or
+// other materials provided with the distribution.
+//
+// Neither the name of the BinaryMethod.com nor the names of its contributors
+// may be used to endorse or promote products derived from this software without
+// specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS AS IS AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
+// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+// OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+// POSSIBILITY OF SUCH DAMAGE.
+
+#import "BGHUDTabView.h"
+
+@implementation BGHUDTabView
+
+@synthesize themeKey;
+
+/*-(id)initWithCoder:(NSCoder *)aDecoder {
+
+ self = [super initWithCoder: aDecoder];
+
+ if(self) {
+
+ if([aDecoder containsValueForKey: @"themeKey"]) {
+
+ self.themeKey = [aDecoder decodeObjectForKey: @"themeKey"];
+ } else {
+
+ self.themeKey = @"gradientTheme";
+ }
+ }
+
+ return self;
+}*/
+
+-(id)initWithCoder:(NSCoder *) aDecoder {
+
+ BOOL isSubclass = YES;
+
+ isSubclass = isSubclass && [aDecoder isKindOfClass: [NSKeyedUnarchiver class]]; // no support for 10.1 nibs
+ isSubclass = isSubclass && ![self isMemberOfClass: [NSControl class]]; // no raw NSControls
+ isSubclass = isSubclass && [self class] != nil; // need to have something to substitute
+ isSubclass = isSubclass && [self class] != [self class]; // pointless if same
+
+ if( !isSubclass )
+ {
+ self = [super initWithCoder: aDecoder];
+ }
+ else
+ {
+ NSKeyedUnarchiver *modDecoder = (id)aDecoder;
+
+ [modDecoder setClass: [BGHUDTabViewItem class] forClassName: @"NSTabViewItem"];
+
+ self = [super initWithCoder: modDecoder];
+
+ [modDecoder setClass: [NSTabViewItem class] forClassName: @"BGHUDTabViewItem"];
+
+ if(self) {
+
+ if([modDecoder containsValueForKey: @"themeKey"]) {
+
+ self.themeKey = [modDecoder decodeObjectForKey: @"themeKey"];
+ } else {
+
+ self.themeKey = @"gradientTheme";
+ }
+ }
+ }
+
+ return self;
+}
+
+
+/*-(id)initWithCoder:(NSCoder *) aDecoder {
+
+ [NSKeyedUnarchiver setClass: [BGHUDTabViewItem class]
+ forClassName: @"NSTabViewItem"];
+
+ self = [super initWithCoder: aDecoder];
+
+ if(self) {
+
+ if([aDecoder containsValueForKey: @"themeKey"]) {
+
+ self.themeKey = [aDecoder decodeObjectForKey: @"themeKey"];
+ } else {
+
+ self.themeKey = @"gradientTheme";
+ }
+ }
+
+ return self;
+}*/
+
+-(void)encodeWithCoder: (NSCoder *)coder {
+
+ [super encodeWithCoder: coder];
+
+ [coder encodeObject: self.themeKey forKey: @"themeKey"];
+}
+
+-(void)_drawThemeTab:(id) tabItem withState:(unsigned int) state inRect:(NSRect) aRect {
+
+ int index = [self indexOfTabViewItem: tabItem];
+ int gradientAngle = 90;
+ NSBezierPath *path;
+
+ aRect = NSInsetRect(aRect, 0.5, 0.5);
+
+ if([self tabViewType] == NSLeftTabsBezelBorder) {
+
+ gradientAngle = 0;
+ } else if([self tabViewType] == NSRightTabsBezelBorder) {
+
+ gradientAngle = 180;
+ }
+
+ if(index == 0) {
+
+ path = [[NSBezierPath alloc] init];
+
+ if([self tabViewType] == NSRightTabsBezelBorder ||
+ [self tabViewType] == NSLeftTabsBezelBorder) {
+
+ [path moveToPoint: NSMakePoint(NSMaxX(aRect), NSMaxY(aRect))];
+ [path lineToPoint: NSMakePoint(NSMinX(aRect), NSMaxY(aRect))];
+ [path lineToPoint: NSMakePoint(NSMinX(aRect), NSMinY(aRect) +5)];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMinX(aRect) +5, NSMinY(aRect) +5)
+ radius: 5
+ startAngle: 180
+ endAngle: 270];
+ [path lineToPoint: NSMakePoint(NSMaxX(aRect) -5, NSMinY(aRect))];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMaxX(aRect) -5, NSMinY(aRect) +5)
+ radius: 5
+ startAngle: 270
+ endAngle: 0];
+ } else {
+
+ [path moveToPoint: NSMakePoint(NSMaxX(aRect), NSMinY(aRect))];
+
+ [path lineToPoint: NSMakePoint(NSMaxX(aRect), NSMaxY(aRect))];
+ [path lineToPoint: NSMakePoint(NSMinX(aRect) + 5, NSMaxY(aRect))];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMinX(aRect) +5, NSMaxY(aRect) -5)
+ radius: 5
+ startAngle: 90
+ endAngle: 180];
+ [path lineToPoint: NSMakePoint(NSMinX(aRect), NSMinY(aRect) +5)];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMinX(aRect) +5, NSMinY(aRect) +5)
+ radius: 5
+ startAngle: 180
+ endAngle: 270];
+ }
+
+ [path closePath];
+
+ if(state == 1) {
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] normalGradient] drawInBezierPath: path angle: gradientAngle];
+ } else {
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] highlightGradient] drawInBezierPath: path angle: gradientAngle];
+ }
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] strokeColor] set];
+ [path stroke];
+
+ [path release];
+ } else if(index > 0 && index < ([self numberOfTabViewItems] -1)) {
+
+ if([self tabViewType] == NSRightTabsBezelBorder ||
+ [self tabViewType] == NSLeftTabsBezelBorder) {
+
+ aRect.origin.y -= 0.5;
+ aRect.size.height += 0.5;
+
+ } else {
+
+ aRect.origin.x -= 0.5;
+ aRect.size.width += 0.5;
+ }
+
+ if(state == 1) {
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] normalGradient] drawInRect: aRect angle: gradientAngle];
+ } else {
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] highlightGradient] drawInRect: aRect angle: gradientAngle];
+ }
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] strokeColor] set];
+
+ if([self tabViewType] == NSRightTabsBezelBorder ||
+ [self tabViewType] == NSLeftTabsBezelBorder) {
+
+ [NSBezierPath strokeLineFromPoint: NSMakePoint(NSMinX(aRect), NSMinY(aRect))
+ toPoint: NSMakePoint(NSMinX(aRect), NSMaxY(aRect))];
+ [NSBezierPath strokeLineFromPoint: NSMakePoint(NSMinX(aRect), NSMaxY(aRect))
+ toPoint: NSMakePoint(NSMaxX(aRect), NSMaxY(aRect))];
+ [NSBezierPath strokeLineFromPoint: NSMakePoint(NSMaxX(aRect), NSMaxY(aRect))
+ toPoint: NSMakePoint(NSMaxX(aRect), NSMinY(aRect))];
+
+ } else {
+
+ [NSBezierPath strokeLineFromPoint: NSMakePoint(NSMinX(aRect), NSMinY(aRect))
+ toPoint: NSMakePoint(NSMaxX(aRect), NSMinY(aRect))];
+ [NSBezierPath strokeLineFromPoint: NSMakePoint(NSMaxX(aRect), NSMinY(aRect))
+ toPoint: NSMakePoint(NSMaxX(aRect), NSMaxY(aRect))];
+ [NSBezierPath strokeLineFromPoint: NSMakePoint(NSMinX(aRect), NSMaxY(aRect))
+ toPoint: NSMakePoint(NSMaxX(aRect), NSMaxY(aRect))];
+ }
+
+ } else if(index == ([self numberOfTabViewItems] -1)) {
+
+ path = [[NSBezierPath alloc] init];
+
+ if([self tabViewType] == NSRightTabsBezelBorder ||
+ [self tabViewType] == NSLeftTabsBezelBorder) {
+
+ aRect.origin.y -= 1;
+ //[path appendBezierPathWithRect: aRect];
+
+ [path moveToPoint: NSMakePoint(NSMaxX(aRect), NSMinY(aRect))];
+ [path lineToPoint: NSMakePoint(NSMinX(aRect), NSMinY(aRect))];
+ [path lineToPoint: NSMakePoint(NSMinX(aRect), NSMaxY(aRect) -5)];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMinX(aRect) +5, NSMaxY(aRect) -5)
+ radius: 5
+ startAngle: 180
+ endAngle: 90
+ clockwise: YES];
+ [path lineToPoint: NSMakePoint(NSMaxX(aRect) -5, NSMaxY(aRect))];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMaxX(aRect) -5, NSMaxY(aRect) -5)
+ radius: 5
+ startAngle: 90
+ endAngle: 0
+ clockwise: YES];
+
+ } else {
+ aRect.origin.x -= 1;
+ aRect.size.width += 1;
+ [path moveToPoint: NSMakePoint(NSMinX(aRect), NSMinY(aRect))];
+ [path lineToPoint: NSMakePoint(NSMinX(aRect), NSMaxY(aRect))];
+ [path lineToPoint: NSMakePoint(NSMaxX(aRect) - 5, NSMaxY(aRect))];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMaxX(aRect) -5, NSMaxY(aRect) -5)
+ radius: 5
+ startAngle: 90
+ endAngle: 0
+ clockwise: YES];
+ [path lineToPoint: NSMakePoint(NSMaxX(aRect), NSMinY(aRect) +5)];
+ [path appendBezierPathWithArcWithCenter: NSMakePoint(NSMaxX(aRect) -5, NSMinY(aRect) +5)
+ radius: 5
+ startAngle: 0
+ endAngle: 270
+ clockwise: YES];
+ }
+
+ [path closePath];
+
+ if(state == 1) {
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] normalGradient] drawInBezierPath: path angle: gradientAngle];
+ } else {
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] highlightGradient] drawInBezierPath: path angle: gradientAngle];
+ }
+
+ [[[[BGThemeManager keyedManager] themeForKey: self.themeKey] strokeColor] set];
+ [path stroke];
+
+ [path release];
+ }
+
+
+}
+
+@end
View
43 Framework/BGHUDTabViewItem.h
@@ -0,0 +1,43 @@
+//
+// BGHUDTabViewItem.h
+// BGHUDAppKit
+//
+// Created by BinaryGod on 5/10/09.
+// Copyright 2009 none. All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without modification,
+// are permitted provided that the following conditions are met:
+//
+// Redistributions of source code must retain the above copyright notice, this
+// list of conditions and the following disclaimer.
+//
+// Redistributions in binary form must reproduce the above copyright notice,
+// this list of conditions and the following disclaimer in the documentation and/or
+// other materials provided with the distribution.
+//
+// Neither the name of the BinaryMethod.com nor the names of its contributors
+// may be used to endorse or promote products derived from this software without
+// specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS AS IS AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
+// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+// OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+// POSSIBILITY OF SUCH DAMAGE.
+
+#import <Cocoa/Cocoa.h>
+#import "BGThemeManager.h"
+
+@interface BGHUDTabViewItem : NSTabViewItem {
+
+ NSString *themeKey;
+}
+
+@property (retain) NSString *themeKey;
+
+@end
View
45 Framework/BGHUDTabViewItem.m
@@ -0,0 +1,45 @@
+//
+// BGHUDTabViewItem.m
+// BGHUDAppKit
+//
+// Created by BinaryGod on 5/10/09.
+// Copyright 2009 none. All rights reserved.
+//
+// Redistribution and use in source and binary forms, with or without modification,
+// are permitted provided that the following conditions are met:
+//
+// Redistributions of source code must retain the above copyright notice, this
+// list of conditions and the following disclaimer.
+//
+// Redistributions in binary form must reproduce the above copyright notice,
+// this list of conditions and the following disclaimer in the documentation and/or
+// other materials provided with the distribution.
+//
+// Neither the name of the BinaryMethod.com nor the names of its contributors
+// may be used to endorse or promote products derived from this software without
+// specific prior written permission.
+//
+// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS AS IS AND
+// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+// IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
+// INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
+// BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
+// OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+// WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
+// ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
+// POSSIBILITY OF SUCH DAMAGE.
+
+#import "BGHUDTabViewItem.h"
+
+
+@implementation BGHUDTabViewItem
+
+@synthesize themeKey;
+
+-(id)_labelColor {
+
+ return [[[BGThemeManager keyedManager] themeForKey: self.themeKey] textColor];
+}
+
+@end
Please sign in to comment.
Something went wrong with that request. Please try again.