mirror of
https://github.com/cappuccino/cappuccino.git
synced 2026-11-14 10:43:50 +00:00
Removed comments
This commit is contained in:
1 parent
91479543fa
commit
a3f5c461c3
1 file changed
+1
-61
@@ -23,13 +23,6 @@
|
||||
@import "CPTextField.j"
|
||||
@import "_CPTitleableWindowView.j"
|
||||
|
||||
// var _CPHUDWindowViewBackgroundColor = nil,
|
||||
// _CPHUDWindowViewThemeValues = nil,
|
||||
//
|
||||
// CPHUDCloseButtonImage = nil;
|
||||
|
||||
var HUD_TITLEBAR_HEIGHT = 26.0;
|
||||
|
||||
@implementation _CPHUDWindowView : _CPTitleableWindowView
|
||||
{
|
||||
CPView _toolbarView;
|
||||
@@ -41,49 +34,6 @@ var HUD_TITLEBAR_HEIGHT = 26.0;
|
||||
return @"hud-window-view";
|
||||
}
|
||||
|
||||
// + (void)initialize
|
||||
// {
|
||||
// if (self !== [_CPHUDWindowView class])
|
||||
// return;
|
||||
//
|
||||
// var bundle = [CPBundle bundleForClass:self];
|
||||
//
|
||||
// _CPHUDWindowViewBackgroundColor = [CPColor colorWithPatternImage:[[CPNinePartImage alloc] initWithImageSlices:
|
||||
// [
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground0.png"] size:CPSizeMake(7.0, 37.0)],
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground1.png"] size:CPSizeMake(1.0, 37.0)],
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground2.png"] size:CPSizeMake(7.0, 37.0)],
|
||||
//
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground3.png"] size:CPSizeMake(7.0, 1.0)],
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground4.png"] size:CPSizeMake(2.0, 2.0)],
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground5.png"] size:CPSizeMake(7.0, 1.0)],
|
||||
//
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground6.png"] size:CPSizeMake(7.0, 3.0)],
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground7.png"] size:CPSizeMake(1.0, 3.0)],
|
||||
// [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"CPWindow/HUD/CPWindowHUDBackground8.png"] size:CPSizeMake(7.0, 3.0)]
|
||||
// ]]];
|
||||
//
|
||||
// _CPHUDWindowViewCloseImage = [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"HUDTheme/WindowClose.png"] size:CPSizeMake(18.0, 18.0)];
|
||||
// _CPHUDWindowViewCloseActiveImage = [[CPImage alloc] initWithContentsOfFile:[bundle pathForResource:@"HUDTheme/WindowCloseActive.png"] size:CPSizeMake(18.0, 18.0)];
|
||||
//
|
||||
// _CPHUDWindowViewThemeValues = [
|
||||
// [@"title-font", [CPFont systemFontOfSize:[CPFont systemFontSize] - 1]],
|
||||
// [@"title-text-color", [CPColor colorWithWhite:255.0 / 255.0 alpha:0.75]],
|
||||
// [@"title-text-color", [CPColor colorWithWhite:255.0 / 255.0 alpha:1], CPThemeStateKeyWindow],
|
||||
// [@"title-text-shadow-color", [CPColor blackColor]],
|
||||
// [@"title-text-shadow-offset", CGSizeMake(0.0, 1.0)],
|
||||
// [@"title-alignment", CPCenterTextAlignment],
|
||||
// // FIXME: Make this to CPLineBreakByTruncatingMiddle once it's implemented.
|
||||
// [@"title-line-break-mode", CPLineBreakByTruncatingTail],
|
||||
// [@"title-vertical-alignment", CPCenterVerticalTextAlignment]
|
||||
// ];
|
||||
// }
|
||||
|
||||
+ (int)titleBarHeight
|
||||
{
|
||||
return HUD_TITLEBAR_HEIGHT;
|
||||
}
|
||||
|
||||
- (CGRect)contentRectForFrameRect:(CGRect)aFrameRect
|
||||
{
|
||||
var contentRect = [[self class] contentRectForFrameRect:aFrameRect];
|
||||
@@ -120,21 +70,11 @@ var HUD_TITLEBAR_HEIGHT = 26.0;
|
||||
|
||||
if (self)
|
||||
{
|
||||
// Until windows become properly themable, just set these values here in the subclass.
|
||||
//[self registerThemeValues:_CPHUDWindowViewThemeValues];
|
||||
|
||||
var bounds = [self bounds];
|
||||
|
||||
// [self setBackgroundColor:[self valueForThemeAttribute:@"bezel-color"]];
|
||||
|
||||
if (_styleMask & CPClosableWindowMask)
|
||||
{
|
||||
_closeButton = [[CPButton alloc] initWithFrame:CGRectMakeZero()];
|
||||
[_closeButton setBordered:NO];
|
||||
|
||||
// [_closeButton setImage:[self valueForThemeAttribute:@"close-image"]];
|
||||
// [_closeButton setAlternateImage:[self valueForThemeAttribute:@"close-active-image"]];
|
||||
|
||||
[_closeButton setButtonType:CPMomentaryChangeButton];
|
||||
[self addSubview:_closeButton];
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user