remove an unneeded custom cell (yay code reuse)

This commit is contained in:
Mitchell Livingston 2008-01-02 01:19:01 +00:00
parent 0a1269506a
commit 9fc5ddc99d
5 changed files with 3048 additions and 316 deletions

View File

@ -83,7 +83,6 @@
A21DFF100A292B2B007C5F76 /* Transfers.png in Resources */ = {isa = PBXBuildFile; fileRef = A21DFF0F0A292B2B007C5F76 /* Transfers.png */; };
A22180980D148A71007D09ED /* GroupsWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = A22180970D148A71007D09ED /* GroupsWindowController.m */; };
A22180B60D148F0F007D09ED /* GroupsWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = A22180B50D148F0F007D09ED /* GroupsWindow.xib */; };
A22180F60D14A32F007D09ED /* GradientCell.m in Sources */ = {isa = PBXBuildFile; fileRef = A22180F40D14A32F007D09ED /* GradientCell.m */; };
A2265F420B5EF5F40093DDA5 /* FileNameCell.m in Sources */ = {isa = PBXBuildFile; fileRef = A2265F400B5EF5F40093DDA5 /* FileNameCell.m */; };
A226FDAC0D0CDF20005A7F71 /* libnatpmp.a in Frameworks */ = {isa = PBXBuildFile; fileRef = 3C7A118D0D0B2EB800B5701F /* libnatpmp.a */; };
A22A8D560AEEAFA5007E9CB9 /* Localizable.strings in Resources */ = {isa = PBXBuildFile; fileRef = A22A8D540AEEAFA5007E9CB9 /* Localizable.strings */; };
@ -433,8 +432,6 @@
A22180960D148A71007D09ED /* GroupsWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GroupsWindowController.h; path = macosx/GroupsWindowController.h; sourceTree = "<group>"; };
A22180970D148A71007D09ED /* GroupsWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GroupsWindowController.m; path = macosx/GroupsWindowController.m; sourceTree = "<group>"; };
A22180B50D148F0F007D09ED /* GroupsWindow.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = GroupsWindow.xib; path = macosx/GroupsWindow.xib; sourceTree = "<group>"; };
A22180F40D14A32F007D09ED /* GradientCell.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; name = GradientCell.m; path = macosx/GradientCell.m; sourceTree = "<group>"; };
A22180F50D14A32F007D09ED /* GradientCell.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; name = GradientCell.h; path = macosx/GradientCell.h; sourceTree = "<group>"; };
A223AA7D0D220CEB00840069 /* nl */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = nl; path = macosx/nl.lproj/Creator.xib; sourceTree = "<group>"; };
A223AA7E0D220CEB00840069 /* nl */ = {isa = PBXFileReference; lastKnownFileType = text.plist.strings; name = nl; path = macosx/nl.lproj/InfoPlist.strings; sourceTree = "<group>"; };
A223AA7F0D220CEB00840069 /* nl */ = {isa = PBXFileReference; lastKnownFileType = file.xib; name = nl; path = macosx/nl.lproj/InfoWindow.xib; sourceTree = "<group>"; };
@ -830,8 +827,6 @@
A2E23AC40CB5E1930002BB25 /* InfoTabButtonCell.m */,
A22180960D148A71007D09ED /* GroupsWindowController.h */,
A22180970D148A71007D09ED /* GroupsWindowController.m */,
A22180F40D14A32F007D09ED /* GradientCell.m */,
A22180F50D14A32F007D09ED /* GradientCell.h */,
);
name = Sources;
sourceTree = "<group>";
@ -1742,7 +1737,6 @@
A26397550D0F714300D36DF2 /* ActionPopUpButton.m in Sources */,
A25AFDE90D1038AD0092A1BA /* MenuLabel.m in Sources */,
A22180980D148A71007D09ED /* GroupsWindowController.m in Sources */,
A22180F60D14A32F007D09ED /* GradientCell.m in Sources */,
);
runOnlyForDeploymentPostprocessing = 0;
};

View File

@ -1,33 +0,0 @@
/******************************************************************************
* $Id$
*
* Copyright (c) 2007 Transmission authors and contributors
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#import <Cocoa/Cocoa.h>
@class CTGradient;
@interface GradientCell : NSCell
{
}
@end

View File

@ -1,37 +0,0 @@
/******************************************************************************
* $Id$
*
* Copyright (c) 2007 Transmission authors and contributors
*
* Permission is hereby granted, free of charge, to any person obtaining a
* copy of this software and associated documentation files (the "Software"),
* to deal in the Software without restriction, including without limitation
* the rights to use, copy, modify, merge, publish, distribute, sublicense,
* and/or sell copies of the Software, and to permit persons to whom the
* Software is furnished to do so, subject to the following conditions:
*
* The above copyright notice and this permission notice shall be included in
* all copies or substantial portions of the Software.
*
* THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
* IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
* FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
* AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
* LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
* FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
* DEALINGS IN THE SOFTWARE.
*****************************************************************************/
#import "GradientCell.h"
#import "CTGradient.h"
#import "NSBezierPathAdditions.h"
@implementation GradientCell
#warning switch to image cell
- (void) drawWithFrame: (NSRect) cellFrame inView: (NSView *) controlView
{
[[self objectValue] fillBezierPath: [NSBezierPath bezierPathWithRoundedRect: cellFrame radius: 4.0] angle: 90];
}
@end

File diff suppressed because it is too large Load Diff

View File

@ -23,7 +23,6 @@
*****************************************************************************/
#import "GroupsWindowController.h"
#import "GradientCell.h"
#import "CTGradient.h"
#import "NSBezierPathAdditions.h"
#import "NSApplicationAdditions.h"
@ -114,10 +113,6 @@ GroupsWindowController * fGroupsWindowInstance = nil;
- (void) awakeFromNib
{
GradientCell * cell = [[GradientCell alloc] init];
[[fTableView tableColumnWithIdentifier: @"Color"] setDataCell: cell];
[cell release];
[[[fTableView tableColumnWithIdentifier: @"Button"] dataCell] setTitle: NSLocalizedString(@"Color", "Groups -> Color Button")];
[fTableView registerForDraggedTypes: [NSArray arrayWithObject: GROUP_TABLE_VIEW_DATA_TYPE]];
@ -181,7 +176,7 @@ GroupsWindowController * fGroupsWindowInstance = nil;
{
NSString * identifier = [tableColumn identifier];
if ([identifier isEqualToString: @"Color"])
return [self gradientForColor: [[fGroups objectAtIndex: row] objectForKey: @"Color"]];
return [self imageForGroup: [fGroups objectAtIndex: row] isSmall: NO];
else
return [[fGroups objectAtIndex: row] objectForKey: @"Name"];
}